Ardour Crashes While Recording with X32

Hey guys. Been using Ardour to record with the Behringer X32 but for the last month now it’s been crashing and I can’t really figure out why as there is no warning or log that I could find that explains the crash. The setup is 32in/32out and buffer is set to 512.

I’ve been recording now for months with the XR18 and the X32 and have been delighted with its stability and performance. Most of the issues I’ve encountered have to do with controlling Ardour with midi, and that’s been relatively stable as well. Since the X32’s interface is with JACK and not Ardour itself, I would suggest looking through Ardours error logs for a clue.

What versions of everything are you using?

I’m running whatever Arch has available to me so Ardour 4.4.2, JACK 0.124.1-6, and on the console X32 2.14 firmware. I’ll test it tomorrow with a different USB cable and see if that helps. I’ve checked Ardour logs and I see nothing pertaining to the crash at all.

Definitely make sure it’s a USB 2.0 cable. Lot’s of dropouts occur with a USB 1.1 cable, though I haven’t witnessed it crashing ardour. I guess another thing to check is whether there are lots of xruns happening. If you aren’t using QJackCtl I’d recommend it. You can see xruns easily that way.

Yet another thing you might check for is if midi connections are automatically being hooked up to control Ardour as that will definitely give you issues if the X32’s setup for MIDI is on and incorrectly configured (you could just make sure that’s off on the X32). That can be found in the MIDI tab in QJackCtl’s connections window. And, just to be sure it isn’t something like that, go into Ardour’s Preferences->Control Surfaces and uncheck everything except OSC control. Uncheck that one too, if you aren’t doing any remote control of Ardour, at least for now.

Another thing to try might be to run in a terminal (I think this is available in Arch):
$ journalctl -f
And observe it when you plug in the X32.

Yet another thing to check out might be QJactCtl’s messages window just after Ardour crashes. Something’s sure to turn up. There are other things to look at as well, but maybe this will be a good start.

And good luck, the Behringer and Midas units have simply been the best experience I’ve had working with any soundcard and jackd and Ardour and I happily use the combination in a professional recording environment all the time now.

It occurred to me that you may be turning on Jack from within Ardour. I’d recommend starting jackd (w/QJackCtl) and let ardour connect to the running server once it’s started. Lots of other things can be connected as well. Withing the setup window be sure to select X-USB as the interface (though other sound cards can be used in concert here). You’ll need to have the X32 plugged in and recognized first. As far as buffer, check this out:

http://www.penguinproducer.com/Blog/2011/10/balancing-performance-and-reliability-in-jack/

@chadwellAK: Thanks for the in depth suggestions. I will definitely try all this when I get back to our church to record a session and report back with what I find.

Update: So I’m using a usb2.0 cable and I started JACK1 with Qjackctl and it’s still crashing on me. It was definite xruns but I can’t remember what’s causing the xruns as I’m not in front of the machine at the moment. I’ll check tomorrow if I have a chance and see what’s causing the xruns in the Messages window of Qjackctl.

That’s a good idea. There is another suggestion that springs to mind, and it may be a good idea to do it even before you start diagnosing your problem. Should’ve probably mentioned it sooner.

The X-USB card on the X32 frequently needs to be reset. When it needs it it turns out to be crucial for the card to work right for any given session. Thankfully, it’s also a simple process. Just go to the setup screen on the X32, to the CARD tab, scroll to and select a different configuration. For instance, if you were set for 32ch/32ch, go to 8ch/8ch and press the knob. Start JACK and click on “Expand All” at the bottom of the Connections window. You should see the 8 inputs and/or outputs, depending on your JACK settings. Do at least all that before starting Ardour.

I’ve had to reset the card many times, but never during a session and only across power cycles. Also make sure everything is USB2.0 from mixer to comupter. No USB1.1 hubs or ports.

@chadwellAK: I will tomorrow and I’ll update with what I find hopefully with a solution. I did change the usb port on the PC for the X32. Maybe it is usb1.1. I’ll check that tomorrow when I get in.

Update: So it crashed again and it’s getting really frustrating. Here’s a log from Qjackctl’s Messages window:
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details
could not open driver .so ‘/usr/lib/jack/jack_firewire.so’: libffado.so.2: cannot open shared object file: No such file or directory
JACK compiled with System V SHM support.
loading driver …
apparent rate = 44100
creating alsa driver … hw:XUSB|hw:XUSB|512|3|44100|0|0|nomon|swmeter|-|32bit
configuring for 44100Hz, period = 512 frames (11.6 ms), buffer = 3 periods
ALSA: final selected sample format for capture: 32bit integer little-endian
ALSA: use 3 periods for capture
ALSA: final selected sample format for playback: 32bit integer little-endian
ALSA: use 3 periods for playback
18:38:35.715 JACK was started with PID=18480.
18:38:37.783 JACK connection change.
18:38:37.785 Server configuration saved to “/home/studio/.jackdrc”.
18:38:37.786 Statistics reset.
18:38:37.795 Client activated.
18:38:37.796 Patchbay deactivated.
18:38:37.843 Buffer size change (512).
18:39:29.581 JACK connection graph change.
18:39:29.742 JACK connection change.
18:39:29.761 JACK connection graph change.
18:39:29.954 JACK connection change.
18:39:29.972 JACK connection graph change.
18:39:30.165 JACK connection change.
18:39:30.187 JACK connection graph change.
18:39:30.376 JACK connection change.
18:39:30.379 JACK connection graph change.
18:39:30.588 JACK connection change.
18:39:30.591 JACK connection graph change.
18:39:30.801 JACK connection change.
18:39:30.820 JACK connection graph change.
18:39:31.010 JACK connection change.
subgraph starting at ardour timed out (subgraph_wait_fd=9, status = 0, state = Triggered, pollret = 0 revents = 0x0)
pp: cannot clean up byte from graph wait fd () - no data present
19:34:56.167 XRUN callback (1).
**** alsa_pcm: xrun of at least -542769020.928 msecs
19:34:56.941 JACK connection graph change.
subgraph starting at ardour lost client
timeout waiting for client ardour to handle a xrun event
**** alsa_pcm: xrun of at least -542770036.736 msecs
19:34:56.960 JACK connection change.
19:34:57.166 XRUN callback (1 skipped).

So it xruns and then Ardour crashes it seems. Also this happens when I try record from the X32 after some time. Once it crashes I can’t recover recorded audio.

@dsreyes1014: From the verbosity of JACK’s output it looks like JACK2. Is that necessary? I’ve always found JACK1 (if that’s what the ‘original’ JACK is called - or perhaps more specifically, “not JACK2” to be more reliable)

@mike@overtonedsp: It is JACK1. Maybe I could reinstall and see if that helps. With Ardour 4.0 it would record just fine. After the 4.2 and 4.4 updates it started to crash with 4.4 being really bad. It might not be Ardour at all but with each update it seemed to get worse for me.

It is JACK1. Maybe I could reinstall and see if that helps...
Maybe - though from the logs it looks like JACK timed out waiting for ardour for some reason, and / or ardour is then kicked off JACK, which causes ardour to crash. My experience has been that if ardour becomes disconnected from JACK it will almost certainly crash, and even if it doesn't, it's then completely unrecoverable.

Hmmm I wander if the capture buffer makes it timeout/crash. It is set to record 32 channels for about 2-3 hours. Something for me to look into. I’ll update with what I find.

Hmmm I wander if the capture buffer makes it timeout/crash. It is set to record 32 channels for about 2-3 hours. Something for me to look into. I’ll update with what I find.

It would be nice to see your JACK settings. A screenshot of QJackCtl’s settings dialog would be fine.

Only because this works so out-of-the-box using Ardour 4.4 and JACK 1.9.1 (X32, XR18, M32) I would be hesitant to suggest you delve too deeply beyond looking for an obvious issue, like a mis-setting. I’d propose, in fact, using QJackCtl’s default buffer settings (with the correct interface and driver selected). After that, mess with the buffer if needed (which you really only need worry about for multiplexing–tracking and overdubbing). And be sure the X32 is set to the same samplerate as jackd.

There shouldn’t be any reason you couldn’t record all 32 channels until you run out of space (which will crash Ardour, by the way). I’ve been using a Raspberry Pi as a live capture device using just this setup–all defaults.

Also, if you were in fact recording anything at all from the mixer then the files are there, in the Ardour project folder, probably in the interchange folder, even after a crash. Ardour is writing all the while that it’s recording (unless there really isn’t any audio or something else is whack–which is what it sounds like–no pun intended).

But crashing beyond rarely is just not an acceptable situation.

@chadwellAK and @mike@overtonedsp: I appreciate your sticking with me and helping me along. Merry Christmas to all and enjoy these holidays. I definitely try all this out when I get back to my church and update you guys.

Hey guys. Sorry it’s been awhile. We’ve been doing renovations in our church and couldn’t record anything until last night at our practice session and it’s still crashing. I will post some screenshots of QJackctl’s settings for JACK1 a little later.