View Issue Details

IDProjectCategoryView StatusLast Update
0006070ardourbugspublic2014-12-12 23:01
Reporterandreas_kagedal Assigned To 
PrioritynormalSeveritymajorReproducibilityalways
Status newResolutionopen 
Summary0006070: Export hangs, and disables firewire interface
DescriptionWhen exporting a session (Session -> Export -> Export To Audio File(s)...), two things happen:
(1) the LED on my Focusrite Saffire PRO 26 i/o goes out, (and as it turns out, no audio can go in or out through it, when I try a little bit later)
(2) The export hangs with the progress bar not moving at all.

But if I retry it, with the Focusrite still disabled, it works.

Details:

KX Studio
Ardour
Session: 48kHz, one mono track, no plugins.
Jack runs at 48 kHz and the firewire backend (ffado) to a Focusrite Saffire PRO 26 i/o

I start Ardour from the command line as
ardour3 |& tee ardour.log

Ardour starts up and shows a dialogue where I can choose one of my previous sessions.

The output in the terminal window looks like this:
---------------
a1=
a2=
a3=
a4=
aend=
bnd txt domain [gtk2_ardour3] to /opt/ardour3/share/locale
Ardour3.5.403 (built using 3.5-403-gec2cb31 and GCC version 4.4.6)
ardour: [INFO]: Your system is configured to limit Ardour to only 4096 open files
ardour: [INFO]: Loading system configuration file /opt/ardour3/etc/ardour_system.rc
Loading user configuration file /home/andka/.config/ardour3/ardour.rc
Using SSE optimized routines
ardour: [INFO]: Loading default ui configuration file /opt/ardour3/etc/ardour3_ui_default.conf
Loading user ui configuration file /opt/ardour3/etc/ardour3_ui.conf

(ardour-3.5.403:3309): GLib-GObject-WARNING **: Attempt to add property gtkmm__CustomObject_N9Gtkmm2ext25CellRendererColorSelectorE::color after class was initialised
ardour: [INFO]: Loading ui configuration file /opt/ardour3/etc/ardour3_ui_dark.rc
Found 0 along /home/andka/.config/ardour3/templates:/opt/ardour3/share/templates
run dialog
Announcement is:
---------------

I select one of my sessions, which opens in Ardour.

THe following appears in the Jack log:
----------
Wed Dec 10 22:31:39 2014: ERROR: Unknown port 'ardour:LTC-in'.
Wed Dec 10 22:31:39 2014: ERROR: Unknown port 'ardour:LTC-in'.
Wed Dec 10 22:31:39 2014: ERROR: unknown destination port in attempted connection [ardour:Midiaudition]
-----------

But otherwise everything seems to work fine.

I select Session -> Export -> Export To Audio File(s)...
The export dialog window appears
I select a format (I have tried different formats, but not all, with the same result, mostly I have selected Ogg Vorbis 48kHz)
I check the "Session Name" checkbox.
I click on the Export button.

Result:
(1) the LED on my Focusrite Saffire PRO 26 i/o goes out, (and as it turns out, no audio can go in or out through it, when I try a little bit later). Nothing more happened in Jack log, and Jack still has status "started" (with a green check mark) in Cadence.

(2) The export hangs with the progress bar not moving at all. A .ogg file is created in the export directory, but it is empty. Pressing "stop export" does not have any effect.
Pressing ctrl-C in the terminal window where Ardour was started, terminates Ardour.

The rest of the output from Ardour in the terminal window looks like this:
---------------
Scanning folders for bundled LV2s: /opt/ardour3/lib/LV2
error: failed to expand CURIE `pprops:hasStrictBounds'
error: attempt to add quad with NULL field
error: failed to expand CURIE `pprops:hasStrictBounds'
error: attempt to add quad with NULL field
error: failed to expand CURIE `pprops:hasStrictBounds'
error: attempt to add quad with NULL field
error: failed to expand CURIE `pprops:hasStrictBounds'
error: attempt to add quad with NULL field
error: /usr/lib/lv2/mod-crossover3.lv2/CrossOver3.ttl:139:23: expected `.', not `'

(ardour-3.5.403:3309): GLib-GObject-WARNING **: Attempt to add property gtkmm__CustomObject_N9Gtkmm2ext23CellRendererPixbufMultiE::active after class was initialised
------------------

If I now start over again, that is restart ardour without restarting Jack or otherwise try to get the Focusrite to work again, the export will work. The progress bar will move, and I will get a nice .ogg-file with my exported file.

If I then (after the succuessful export, and while the Focusrite is still disabled) try to exit Ardour (Menu Session->Exit) Ardour hangs with a "splash screen" saying "please wait while Ardour cleans up..."
Stopping Jack does not resolve this.
If I do a "Force Restart" of Jack in Cadence, two things happen:
 - the Focusrite restarts (the led flashes and then lights up)
 - Ardour shows a dialog saying "The audio backend was shutdown because: JACK died". If I press OK. Ardour finaly exits.


The above behaviour is quite consistent, but not 100%. I could repeat it at least five times when I was writing this, but once, after restarting the Jack server, it suddenly worked to export the ogg-file in the first try (but the Focusrite was still disabled). The next time I tried, it was back to be behaviour described above again.
Additional InformationThe Jack log up
Wed Dec 10 22:30:33 2014: Stopping jack server...
Wed Dec 10 22:30:33 2014: Controller deactivated.
Wed Dec 10 22:30:33 2014: ------------------
Wed Dec 10 22:30:33 2014: Controller activated. Version 0.124.2
Wed Dec 10 22:30:33 2014: Loading settings from "/home/andka/.config/jack/conf-jack1.xml" using expat_2.1.0 ...
Wed Dec 10 22:30:33 2014: setting engine option "driver" to value "firewire"
Wed Dec 10 22:30:33 2014: driver "firewire" selected
Wed Dec 10 22:30:33 2014: setting engine option "realtime" to value "false"
Wed Dec 10 22:30:33 2014: setting for driver "alsa" found
Wed Dec 10 22:30:33 2014: setting for driver "dummy" found
Wed Dec 10 22:30:33 2014: setting for driver "firewire" found
Wed Dec 10 22:30:33 2014: setting driver option "period" to value "2048"
Wed Dec 10 22:30:33 2014: setting for driver "net" found
Wed Dec 10 22:30:33 2014: setting for driver "alsa_midi" found
Wed Dec 10 22:30:33 2014: setting for driver "oss" found
Wed Dec 10 22:30:33 2014: Listening for D-Bus messages
Wed Dec 10 22:30:35 2014: ------------------
Wed Dec 10 22:30:35 2014: Controller activated. Version 0.124.2
Wed Dec 10 22:30:35 2014: Loading settings from "/home/andka/.config/jack/conf-jack1.xml" using expat_2.1.0 ...
Wed Dec 10 22:30:35 2014: setting engine option "driver" to value "firewire"
Wed Dec 10 22:30:35 2014: driver "firewire" selected
Wed Dec 10 22:30:35 2014: setting engine option "realtime" to value "false"
Wed Dec 10 22:30:35 2014: setting for driver "alsa" found
Wed Dec 10 22:30:35 2014: setting for driver "dummy" found
Wed Dec 10 22:30:35 2014: setting for driver "firewire" found
Wed Dec 10 22:30:35 2014: setting driver option "period" to value "2048"
Wed Dec 10 22:30:35 2014: setting for driver "net" found
Wed Dec 10 22:30:35 2014: setting for driver "alsa_midi" found
Wed Dec 10 22:30:35 2014: setting for driver "oss" found
Wed Dec 10 22:30:35 2014: Listening for D-Bus messages
Wed Dec 10 22:30:35 2014: Starting jack server...
Wed Dec 10 22:30:35 2014: Using System timer as clock source.
Wed Dec 10 22:30:35 2014: JACK compiled with System V SHM support.
Wed Dec 10 22:30:35 2014: loading driver "firewire" ...
Wed Dec 10 22:30:36 2014: New client 'firewire_pcm' with PID 0
Wed Dec 10 22:30:36 2014: New client 'system' with PID 0
Wed Dec 10 22:30:41 2014: New client 'jack2alsa' with PID 3857
Wed Dec 10 22:30:42 2014: New client 'alsa2jack' with PID 3856
Wed Dec 10 22:30:42 2014: New client 'a2j' with PID 3791
Wed Dec 10 22:31:38 2014: New client 'ardour' with PID 3872
Wed Dec 10 22:31:39 2014: ERROR: Unknown port 'ardour:LTC-in'.
Wed Dec 10 22:31:39 2014: ERROR: Unknown port 'ardour:LTC-in'.
Wed Dec 10 22:31:39 2014: ERROR: unknown destination port in attempted connection [ardour:Midiaudition]

<Here I restarted terminated Ardour with ctrl-C and restarted it.>

Wed Dec 10 22:39:55 2014: ERROR: Unknown port 'LTC-out' of client 'ardour'
Wed Dec 10 22:39:55 2014: ERROR: Unknown port 'ardour:LTC-in'.
Wed Dec 10 22:39:55 2014: ERROR: Unknown port 'LTC-in' of client 'ardour'
Wed Dec 10 22:39:55 2014: ERROR: firewire ERR: Could not start streaming threads: -1
Wed Dec 10 22:39:55 2014: ERROR: DRIVER NT: could not start driver
Wed Dec 10 22:39:55 2014: ERROR: could not restart driver after freewheeling
Wed Dec 10 22:40:21 2014: ERROR: Unknown port 'ardour:LTC-in'.
Wed Dec 10 22:40:21 2014: ERROR: Unknown port 'ardour:LTC-in'.
Wed Dec 10 22:40:21 2014: ERROR: unknown destination port in attempted connection [ardour:Midiaudition]

<Here I pressed the Export button and the export worked.>

Wed Dec 10 22:43:23 2014: ERROR: firewire ERR: Could not start streaming threads: -1
Wed Dec 10 22:43:23 2014: ERROR: DRIVER NT: could not start driver
Wed Dec 10 22:43:23 2014: ERROR: could not restart driver after freewheeling
TagsNo tags attached.

Activities

andreas_kagedal

2014-12-10 21:52

reporter   ~0016023

Forgot to add info on Ardour version:
Ardour 3.5.403
(built from revision 3.5-403-gec2cb31)

Fully updated KX Studio
Linux 3.13.0-40-lowlatency
KDE SC Version 4.13.3

andreas_kagedal

2014-12-12 23:01

reporter   ~0016032

Last edited: 2015-01-20 11:46

I have done some more research and come to the conclusion that these are two separate issues.

(1) the LED on my Focusrite Saffire PRO 26 i/o goes out.
This is a FFADO/Focusrite-device issue. There is a bug report on the FFADO bug tracker which describes this well: http://subversion.ffado.org/ticket/359

Basically, the Focusrite Saffire PRO 26 i/o "drops off the [firewire] bus as if [the firewire cable] was unplugged." when jack goes into "freewheeling mode".

Citing from the bug report: "Freewheeling mode is where jackd runs as fast as it possibly can: it doesn't simply process audio at the audio sampling rate. Freewheeling is used when doing an export from Ardour for example: since there's no need to play the final audio (it's being written to a file instead) there is no reason why the audio can't be processed faster than real time."

There seems to be no resolution for this one, though. The workaround is to restart jack after the export (for instance by doing a "Force Restart" using Cadence in KXStudio).

The option of adding support for non-freewheeling export in Ardour is proposed in this feature request (http://tracker.ardour.org/view.php?id=4420), but seems to be more complex than one would assume.

(2) The export hangs with the progress bar not moving at all.
I found this bug report ( http://tracker.ardour.org/view.php?id=5701 ) in Mantis which suggested that the cadence snd-aloop deamon in KXStudio is the problem, and turning it off would solve the problem. And indeed it did!

Perhaps the problem is that snd-aloop also does not handle jack freewheeling very well. I was trying to find a Cadence/snd-aloop bug report for this, but failed (I was looking here: https://github.com/falkTX/Cadence ). The 5701 bug report in Mantis claims to have solved it, but it was not solved for me, and it seems to me it should be solved also by Cadence/snd-aloop or possibly by jack.

The conclusion is that this is not really an Ardour bug, except possibly that Ardour should handle the jack lockups more gracefully.

Issue History

Date Modified Username Field Change
2014-12-10 21:45 andreas_kagedal New Issue
2014-12-10 21:52 andreas_kagedal Note Added: 0016023
2014-12-12 23:01 andreas_kagedal Note Added: 0016032
2014-12-12 23:04 andreas_kagedal Note Edited: 0016032
2015-01-20 11:46 andreas_kagedal Note Edited: 0016032