Ardour + Pipewire + Debian Testing = memory allocation error?

So, I was running Debian Testing and ran into this issue, so I did a completely fresh re-install and ran into the exact same thing.

I’m trying to use pw-jack, but as soon as I choose it in Ardour and click the button to proceed, I get this error:

Memory allocation error: posix_memalign (64 * 34359738368) failed (Cannot allocate memory)

I have searched and could not find anything related to this. I even compiled Ardour myself (on my install prior to starting completely fresh) and still ran into this same problem.

I tried with and without the limits.conf tweaks, doesn’t seem to make a difference to this error.

Does anyone know what could fix it? I don’t want to go back to Debian Stable (I tried that in between the Testing installs, but had to use Pipewire from backports to get something usable, but had other issues).

Which version of pipewire is that, and which version of Ardour?

64 * 34359738368 = 64 * 2^35 = 2 TB. No wonder your machine cannot allocate that :slight_smile:

It’d be useful to find out where this call originates. Pipewire allocating port-data or Ardour. Getting a backtrace might help: – in your self-compiled version you can directly debug it from the source-tree: ./gtk2_ardour/ardbg

Hi Robin,

The Debian package versions are:
Ardour 8.4.0+ds1-2
Pipewire 1.0.3-1

I’m gonna guess I can’t debug with the Debian packaged version. I will have to reinstall all the build tools and recompile Ardour, I guess. It will take me some time.

You should get the latest release of Ardour, it’s working here on Debian Testing with latest Pipewire

About 4 seconds after I posted my last comment, I had a power outage. When the power came back, I tried Ardour again and it is working, all of a sudden?? I… don’t understand how that could be even possible. Both the self-compiled and the Debian package version are working now.

I do not trust it to stay this way, however, because the first time I saw this issue, it was kinda intermittent, but for the last few days it hasn’t been.

Just as I suspected, I’m back to getting that error.

I followed the instructions, and here’s the full output:

dana@celyn:/music/Ardour$ gtk2_ardour/ardbg
GNU gdb (Debian 13.2-1) 13.2
Copyright (C) 2023 Free Software Foundation, Inc.

For help, type “help”.
Type “apropos word” to search for commands related to “word”…
Reading symbols from /music/Ardour/build/gtk2_ardour/ardour-8.6.0…
(No debugging symbols found in /music/Ardour/build/gtk2_ardour/ardour-8.6.0)
(gdb) r
Starting program: /music/Ardour/build/gtk2_ardour/ardour-8.6.0
[Thread debugging using libthread_db enabled]
Using host libthread_db library “/lib/x86_64-linux-gnu/”.
Ardour8.6.0 (built using 8.6 and GCC version 12.2.0)
[New Thread 0x7ffff03a76c0 (LWP 164812)]
Ardour: [INFO]: Your system is configured to limit Ardour to 1048576 open files
Ardour: [INFO]: Loading system configuration file /music/Ardour/system_config
Ardour: [INFO]: Loading user configuration file /home/dana/.config/ardour8/config
[New Thread 0x7fffebfff6c0 (LWP 164813)]
Ardour: [INFO]: CPU vendor: GenuineIntel
Ardour: [INFO]: AVX capable processor
Ardour: [INFO]: AVX with FMA capable processor
Ardour: [INFO]: CPU brand: Intel(R) Core™ i5-4690 CPU @ 3.50GHz
Ardour: [INFO]: Using AVX and FMA optimized routines
[New Thread 0x7fffeb7fe6c0 (LWP 164814)]
[New Thread 0x7fffeaffd6c0 (LWP 164815)]
[New Thread 0x7fffea7fc6c0 (LWP 164816)]
Ardour: [INFO]: Loading plugin meta data file /music/Ardour/share/plugin_metadata/plugin_tags
Ardour: [INFO]: Loading plugin statistics file /home/dana/.config/ardour8/plugin_metadata/plugin_stats
Ardour: [INFO]: add_lrdf_data ‘/home/dana/.config/ardour8/rdf:/music/Ardour/share/rdf:/music/Ardour/build/rdf:/music/Ardour/gtk2_ardour/rdf:/music/Ardour/build/gtk2_ardour/rdf:/usr/local/share/ladspa/rdf:/usr/share/ladspa/rdf’
Ardour: [INFO]: read rdf_file ‘file:///usr/share/ladspa/rdf/ladspa.rdfs’
[New Thread 0x7fffe9a786c0 (LWP 164817)]
[Thread 0x7fffe9a786c0 (LWP 164817) exited]
[New Thread 0x7fffe9a786c0 (LWP 164818)]
[Thread 0x7fffe9a786c0 (LWP 164818) exited]
Ardour: [ERROR]: ControlProtocolManager: cannot load module “/music/Ardour/build/libs/surfaces/websockets/” ( cannot open shared object file: No such file or directory)
[New Thread 0x7fffe9a786c0 (LWP 164819)]
[New Thread 0x7fffe8fa96c0 (LWP 164820)]
[New Thread 0x7fffd3fff6c0 (LWP 164821)]
Ardour: [INFO]: Loading 459 MIDI patches from /music/Ardour/share/patchfiles
Ardour: [INFO]: Loading default ui configuration file /music/Ardour/build/gtk2_ardour/default_ui_config
Ardour: [INFO]: Loading user ui configuration file /home/dana/.config/ardour8/ui_config
[New Thread 0x7fffd37fe6c0 (LWP 164822)]
Ardour: [INFO]: Loading color file /music/Ardour/gtk2_ardour/themes/dark-ardour.colors
Ardour: [INFO]: Loading ui configuration file /music/Ardour/build/gtk2_ardour/clearlooks.rc
start clocking
[New Thread 0x7fffd2fd16c0 (LWP 164823)]
[New Thread 0x7fffd27d06c0 (LWP 164824)]
[Thread 0x7fffd2fd16c0 (LWP 164823) exited]
[New Thread 0x7fffd2fd16c0 (LWP 164825)]
[Thread 0x7fffd37fe6c0 (LWP 164822) exited]
Ardour: [INFO]: Loading bindings from /music/Ardour/build/gtk2_ardour/ardour.keys
Loading ui configuration file /music/Ardour/build/gtk2_ardour/clearlooks.rc
[New Thread 0x7fffd37fe6c0 (LWP 164826)]
[New Thread 0x7fffd1dde6c0 (LWP 164827)]
[Thread 0x7fffd1dde6c0 (LWP 164827) exited]
[New Thread 0x7fffd1dde6c0 (LWP 164830)]
[New Thread 0x7fffd15dd6c0 (LWP 164831)]
[Thread 0x7fffd1dde6c0 (LWP 164830) exited]
[Thread 0x7fffd15dd6c0 (LWP 164831) exited]
[Thread 0x7fffd37fe6c0 (LWP 164826) exited]
[New Thread 0x7fffd37fe6c0 (LWP 164834)]
[New Thread 0x7fffd15dd6c0 (LWP 164835)]
[New Thread 0x7fffd15dd6c0 (LWP 164836)]
[Thread 0x7fffd15dd6c0 (LWP 164835) exited]
[New Thread 0x7fffd1dde6c0 (LWP 164838)]
[Thread 0x7fffd1dde6c0 (LWP 164838) exited]
[Thread 0x7fffd15dd6c0 (LWP 164836) exited]
[Thread 0x7fffd37fe6c0 (LWP 164834) exited]
[New Thread 0x7fffd37fe6c0 (LWP 164839)]
[New Thread 0x7fffd1dde6c0 (LWP 164840)]
[New Thread 0x7fffd15dd6c0 (LWP 164841)]
[New Thread 0x7fffd0bff6c0 (LWP 164842)]
[New Thread 0x7fffaffff6c0 (LWP 164843)]
[New Thread 0x7fffaf7fe6c0 (LWP 164844)]
Found nothing along /home/dana/.config/ardour8/templates:/music/Ardour/share/templates:/music/Ardour/build/templates:/music/Ardour/gtk2_ardour/templates:/music/Ardour/build/gtk2_ardour/templates
[Thread 0x7fffaffff6c0 (LWP 164843) exited]
[Thread 0x7fffd0bff6c0 (LWP 164842) exited]
[Thread 0x7fffd3fff6c0 (LWP 164821) exited]
[New Thread 0x7fffd0bff6c0 (LWP 164845)]
[New Thread 0x7fffaffff6c0 (LWP 164846)]
[Thread 0x7fffaffff6c0 (LWP 164846) exited]
[New Thread 0x7fffaffff6c0 (LWP 164847)]
[New Thread 0x7fffaeffd6c0 (LWP 164849)]
[Thread 0x7fffaffff6c0 (LWP 164847) exited]
[Thread 0x7fffd0bff6c0 (LWP 164845) exited]
[Thread 0x7fffaf7fe6c0 (LWP 164844) exited]
[Thread 0x7fffd15dd6c0 (LWP 164841) exited]
[Thread 0x7fffd1dde6c0 (LWP 164840) exited]
[Thread 0x7fffd37fe6c0 (LWP 164839) exited]
[Thread 0x7fffd2fd16c0 (LWP 164825) exited]
[Thread 0x7fffd27d06c0 (LWP 164824) exited]
[Thread 0x7fffe8fa96c0 (LWP 164820) exited]
[Thread 0x7fffe9a786c0 (LWP 164819) exited]
[Thread 0x7fffea7fc6c0 (LWP 164816) exited]
[Thread 0x7fffeaffd6c0 (LWP 164815) exited]
[Thread 0x7fffeb7fe6c0 (LWP 164814) exited]
[Thread 0x7fffebfff6c0 (LWP 164813) exited]
[Thread 0x7ffff03a76c0 (LWP 164812) exited]
[Thread 0x7ffff07eac40 (LWP 164809) exited]
[Thread 0x7fffaeffd6c0 (LWP 164849) exited]
[New process 164809]
[Inferior 1 (process 164809) exited with code 01]
(gdb) thread apply all bt

Edit: also noticed this in dmesg output:

[172247.403219] __vm_enough_memory: pid: 165282, comm: ArdourGUI, not enough memory for the allocation
[172247.403224] __vm_enough_memory: pid: 165282, comm: ArdourGUI, not enough memory for the allocation
[172247.403225] __vm_enough_memory: pid: 165282, comm: ArdourGUI, not enough memory for the allocation
[172247.403230] __vm_enough_memory: pid: 165282, comm: ArdourGUI, not enough memory for the allocation