Hang at "Setup signal flow and plugins" upon loading previous session

I’m having problems trying to load previously saved sessions and was wondering if anyone could help. The issue is that upon launching from either the GUI or the terminal and attempting to load a previous project, Ardour hangs at “Setup signal flow and plugins”. It also brings down Jack and it then becomes (seemingly) impossible to kill the Jack process.

Here are my observations so far:

  1. I can launch a new project. It's just when re-loading a previously saved project that problems occur. I've tried a variety of projects, including those saved with the version of Ardour I'm running and those saved with other versions - the problem doesn't appear to be related to one rogue project
  2. The problem occurs almost every time, though occasionally (1 in 10 or less), I'll have success. This is straight from boot-up, so I can't think of any particular variables which might influence this
  3. I've tried removing the config file before loading the project, as suggested by some forums posters, but the problem still occurs
  4. I've tried removing/reinstalling LADSPA/LV2 plug-ins, even removing all plug-ins, but the problem still occurs
  5. I've tried switching desktop theme, as per the below thread, but with no luck: http://ardour.org/node/4451 (On a side note though, doing the above did fix a similar problem in Rosegarden)

Here is what I’m running:

  • Open SuSE 12.2 64 bit, with kernel-desktop 3.4.11-2.16.1 from the SuSE repos
  • XFCE 4 (also tried KDE 4 with the same effect)
  • Jack 1.9.8-56.1 from the SuSE repos
  • Tried Ardour 2.8.13-2.16-x86_64 from the SuSE repos, plus 2.8.16_13591 downloaded from this site. I also tried a beta version of Ardour 3 from the SuSE repos (ardour3-3.0b5-13159.2.x86_64) and encountered the same problem

I read the information on this site about debugging and attempted to get a backtrace via gdb, but am not sure I’ve done this correctly. When Ardour hangs, the gdb prompt doesn’t appear; I have to kill the Ardour process and only then can I run “thread apply all bt”, so I’m not sure if this is correct. Nevertheless, I’ll paste the output below. Please note that I had to build with SYSLIBS=1, as per the information here: http://ardour.org/node/5263

If anyone has any ideas, I’d be very grateful to hear them.

(gdb) thread apply all bt

Thread 21 (Thread 0x7fffd6ba3800 (LWP 3887)):
#0  0x00007fffef18814f in poll () from /lib64/libc.so.6
#1  0x00007ffff7a8f2f3 in ARDOUR::Session::midi_thread_work (this=0x1fc4b10)
    at libs/ardour/session_midi.cc:1222
#2  0x00007ffff7a8ee80 in ARDOUR::Session::_midi_thread_work (arg=0x1fc4b10)
    at libs/ardour/session_midi.cc:1138
#3  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#4  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 20 (Thread 0x7fffd6c1e800 (LWP 3886)):
#0  0x00007fffef18814f in poll () from /lib64/libc.so.6
#1  0x00007ffff7a3479c in ARDOUR::Session::butler_thread_work (this=0x1fc4b10)
    at libs/ardour/session_butler.cc:179
#2  0x00007ffff7a346f1 in ARDOUR::Session::_butler_thread_work (arg=0x1fc4b10)
    at libs/ardour/session_butler.cc:159
#3  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#4  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 19 (Thread 0x7fffd6e6f800 (LWP 3885)):
#0  0x00007fffef45f00c in __lll_lock_wait () from /lib64/libpthread.so.0
#1  0x00007fffef45af02 in _L_lock_1125 () from /lib64/libpthread.so.0
#2  0x00007fffef45ae80 in pthread_mutex_lock () from /lib64/libpthread.so.0
---Type  to continue, or q  to quit---
#3  0x00007ffff6662471 in g_mutex_lock () from /usr/lib64/libglib-2.0.so.0
#4  0x00000000009c4be6 in Glib::Mutex::Lock::Lock (this=0x7fffd6e6eb10, mutex=
    ...) at /usr/include/glibmm-2.4/glibmm/thread.h:833
#5  0x00007ffff79cc4a5 in ARDOUR::IO::meter (this=0x23ef110)
    at libs/ardour/io.cc:2536
#6  0x00007ffff79d3746 in sigc::bound_mem_functor0::operator() (this=0x23eff18) at /usr/include/sigc++-2.0/sigc++/functors/mem_fun.h:1787
#7  0x00007ffff79d2de8 in sigc::adaptor_functor<sigc::bound_mem_functor0 >::operator() (this=0x23eff10)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:251
#8  0x00007ffff79d2021 in sigc::internal::slot_call0<sigc::bound_mem_functor0, void>::call_it (rep=0x23efee0)
    at /usr/include/sigc++-2.0/sigc++/functors/slot.h:103
#9  0x0000000000928daa in sigc::internal::signal_emit0::emit (
    impl=0x23aaf70) at /usr/include/sigc++-2.0/sigc++/signal.h:772
#10 0x000000000092dd04 in sigc::signal0::emit (this=
    0x7ffff7dd9d00 )
    at /usr/include/sigc++-2.0/sigc++/signal.h:2669
#11 0x000000000092b414 in sigc::signal0::operator() (this=
    0x7ffff7dd9d00 )
    at /usr/include/sigc++-2.0/sigc++/signal.h:2677
#12 0x00007ffff79cc44d in ARDOUR::IO::update_meters ()
    at libs/ardour/io.cc:2530
---Type  to continue, or q  to quit---
#13 0x00007ffff7922594 in ARDOUR::AudioEngine::meter_thread (this=0x1c294d0)
    at libs/ardour/audioengine.cc:502
#14 0x00007ffff792aa78 in sigc::bound_mem_functor0::operator() (this=0x1fb9098)
    at /usr/include/sigc++-2.0/sigc++/functors/mem_fun.h:1787
#15 0x00007ffff792a800 in sigc::adaptor_functor<sigc::bound_mem_functor0 >::operator() (this=0x1fb9090)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:251
#16 0x00007ffff792a199 in sigc::internal::slot_call0<sigc::bound_mem_functor0, void>::call_it (rep=0x1fb9060)
    at /usr/include/sigc++-2.0/sigc++/functors/slot.h:103
#17 0x00007ffff6d6e1cd in ?? () from /usr/lib64/libglibmm-2.4.so.1
#18 0x00007ffff66490e5 in ?? () from /usr/lib64/libglib-2.0.so.0
#19 0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#20 0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 18 (Thread 0x7fffd6ef1700 (LWP 3884)):
#0  0x00007fffef45e940 in sem_timedwait () from /lib64/libpthread.so.0
#1  0x00007ffff2331922 in ?? () from /usr/lib64/libjack.so.0
#2  0x00007ffff23201a9 in ?? () from /usr/lib64/libjack.so.0
#3  0x00007ffff231f42f in ?? () from /usr/lib64/libjack.so.0
#4  0x00007ffff231e7c8 in ?? () from /usr/lib64/libjack.so.0
#5  0x00007ffff2330f00 in ?? () from /usr/lib64/libjack.so.0
---Type  to continue, or q  to quit---
#6  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#7  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 17 (Thread 0x7fffd721f700 (LWP 3883)):
#0  0x00007fffef45f2ed in read () from /lib64/libpthread.so.0
#1  0x00007ffff2332ce2 in ?? () from /usr/lib64/libjack.so.0
#2  0x00007ffff2335596 in ?? () from /usr/lib64/libjack.so.0
#3  0x00007ffff2330f00 in ?? () from /usr/lib64/libjack.so.0
#4  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#5  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 16 (Thread 0x7fffe40b1700 (LWP 3882)):
#0  0x00007fffef45c8f4 in pthread_cond_wait@@GLIBC_2.3.2 ()
   from /lib64/libpthread.so.0
#1  0x00007ffff2332554 in ?? () from /usr/lib64/libjack.so.0
#2  0x00007ffff232d821 in ?? () from /usr/lib64/libjack.so.0
#3  0x00007ffff2330f00 in ?? () from /usr/lib64/libjack.so.0
#4  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#5  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 15 (Thread 0x7fffbe2c4700 (LWP 3878)):
#0  0x00007fffef45c8f4 in pthread_cond_wait@@GLIBC_2.3.2 ()
   from /lib64/libpthread.so.0
---Type  to continue, or q  to quit---
#1  0x00007ffff66626ef in g_cond_wait () from /usr/lib64/libglib-2.0.so.0
#2  0x00007fffd40c92a6 in gst_bus_timed_pop_filtered ()
   from /usr/lib64/libgstreamer-0.10.so.0
#3  0x00007fffd43af5fb in ?? ()
   from /usr/lib64/libcanberra-0.29/libcanberra-gstreamer.so
#4  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#5  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 14 (Thread 0x7fffd51bb700 (LWP 3876)):
#0  0x00007fffef18814f in poll () from /lib64/libc.so.6
#1  0x00007fffaf9ad08f in ?? () from /usr/lib64/libpulse.so.0
#2  0x00007fffaf99e5fc in pa_mainloop_poll () from /usr/lib64/libpulse.so.0
#3  0x00007fffaf99ec59 in pa_mainloop_iterate () from /usr/lib64/libpulse.so.0
#4  0x00007fffaf99ed10 in pa_mainloop_run () from /usr/lib64/libpulse.so.0
#5  0x00007fffaf9ad03f in ?? () from /usr/lib64/libpulse.so.0
#6  0x00007fffaf5532e3 in ?? () from /usr/lib64/libpulsecommon-1.1.so
#7  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#8  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 5 (Thread 0x7fffe4b79700 (LWP 3867)):
#0  0x00007fffef45c8f4 in pthread_cond_wait@@GLIBC_2.3.2 ()
   from /lib64/libpthread.so.0
#1  0x00007ffff66626ef in g_cond_wait () from /usr/lib64/libglib-2.0.so.0
---Type  to continue, or q  to quit---
#2  0x00007ffff79036f2 in ARDOUR::Analyser::work ()
    at libs/ardour/analyser.cc:85
#3  0x00007ffff790342d in analyser_work () at libs/ardour/analyser.cc:49
#4  0x0000000000c8532f in sigc::pointer_functor0::operator() (this=
    0x14bd2e8) at /usr/include/sigc++-2.0/sigc++/functors/ptr_fun.h:77
#5  0x0000000000c846a4 in sigc::adaptor_functor<sigc::pointer_functor0 >::operator() (this=0x14bd2e0)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:251
#6  0x0000000000c82ff9 in sigc::internal::slot_call0<sigc::pointer_functor0, void>::call_it (rep=0x14bd2b0)
    at /usr/include/sigc++-2.0/sigc++/functors/slot.h:103
#7  0x00007ffff6d6e1cd in ?? () from /usr/lib64/libglibmm-2.4.so.1
#8  0x00007ffff66490e5 in ?? () from /usr/lib64/libglib-2.0.so.0
#9  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#10 0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 4 (Thread 0x7fffe537a700 (LWP 3866)):
#0  0x00007fffef45c8f4 in pthread_cond_wait@@GLIBC_2.3.2 ()
   from /lib64/libpthread.so.0
#1  0x00007ffff66626ef in g_cond_wait () from /usr/lib64/libglib-2.0.so.0
#2  0x00007ffff7ac8539 in peak_thread_work ()
    at libs/ardour/source_factory.cc:65
#3  0x0000000000c8532f in sigc::pointer_functor0::operator() (this=
---Type  to continue, or q  to quit---
    0x14bd088) at /usr/include/sigc++-2.0/sigc++/functors/ptr_fun.h:77
#4  0x0000000000c846a4 in sigc::adaptor_functor<sigc::pointer_functor0 >::operator() (this=0x14bd080)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:251
#5  0x0000000000c82ff9 in sigc::internal::slot_call0<sigc::pointer_functor0, void>::call_it (rep=0x14bd050)
    at /usr/include/sigc++-2.0/sigc++/functors/slot.h:103
#6  0x00007ffff6d6e1cd in ?? () from /usr/lib64/libglibmm-2.4.so.1
#7  0x00007ffff66490e5 in ?? () from /usr/lib64/libglib-2.0.so.0
#8  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#9  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 3 (Thread 0x7fffe5b7b700 (LWP 3865)):
#0  0x00007fffef45c8f4 in pthread_cond_wait@@GLIBC_2.3.2 ()
   from /lib64/libpthread.so.0
#1  0x00007ffff66626ef in g_cond_wait () from /usr/lib64/libglib-2.0.so.0
#2  0x00007ffff7ac8539 in peak_thread_work ()
    at libs/ardour/source_factory.cc:65
#3  0x0000000000c8532f in sigc::pointer_functor0::operator() (this=
    0x14bce88) at /usr/include/sigc++-2.0/sigc++/functors/ptr_fun.h:77
#4  0x0000000000c846a4 in sigc::adaptor_functor<sigc::pointer_functor0 >::operator() (this=0x14bce80)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:251
---Type  to continue, or q  to quit---
#5  0x0000000000c82ff9 in sigc::internal::slot_call0<sigc::pointer_functor0, void>::call_it (rep=0x14bce50)
    at /usr/include/sigc++-2.0/sigc++/functors/slot.h:103
#6  0x00007ffff6d6e1cd in ?? () from /usr/lib64/libglibmm-2.4.so.1
#7  0x00007ffff66490e5 in ?? () from /usr/lib64/libglib-2.0.so.0
#8  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#9  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 2 (Thread 0x7fffe72aa700 (LWP 3864)):
#0  0x00007fffef18814f in poll () from /lib64/libc.so.6
#1  0x00007ffff6626684 in ?? () from /usr/lib64/libglib-2.0.so.0
#2  0x00007ffff6626ae2 in g_main_loop_run () from /usr/lib64/libglib-2.0.so.0
#3  0x00007ffff439ea26 in ?? () from /usr/lib64/libgio-2.0.so.0
#4  0x00007ffff66490e5 in ?? () from /usr/lib64/libglib-2.0.so.0
#5  0x00007fffef458e0e in start_thread () from /lib64/libpthread.so.0
#6  0x00007fffef1902cd in clone () from /lib64/libc.so.6

Thread 1 (Thread 0x7ffff7fd4980 (LWP 3860)):
#0  0x00007fffef45f2ed in read () from /lib64/libpthread.so.0
#1  0x00007ffff2332ce2 in ?? () from /usr/lib64/libjack.so.0
#2  0x00007ffff23389f5 in ?? () from /usr/lib64/libjack.so.0
#3  0x00007ffff23357d1 in ?? () from /usr/lib64/libjack.so.0
#4  0x00007ffff2336464 in ?? () from /usr/lib64/libjack.so.0
---Type  to continue, or q  to quit---
#5  0x00007ffff231f13e in ?? () from /usr/lib64/libjack.so.0
#6  0x00007ffff231a50c in jack_port_register () from /usr/lib64/libjack.so.0
#7  0x00007ffff7922e28 in ARDOUR::AudioEngine::register_output_port (this=
    0x1c294d0, type=..., portname="Flute_L/out 2")
    at libs/ardour/audioengine.cc:626
#8  0x00007ffff79c5c53 in ARDOUR::IO::ensure_io (this=0x23ef110, nin=1, nout=
    2, clear=true, src=0x23ef110) at libs/ardour/io.cc:1217
#9  0x00007ffff79c991e in ARDOUR::IO::create_ports (this=0x23ef110, node=...)
    at libs/ardour/io.cc:1948
#10 0x00007ffff79c8c9e in ARDOUR::IO::ports_became_legal (this=0x23ef110)
    at libs/ardour/io.cc:1809
#11 0x00007ffff79d3ce6 in sigc::bound_mem_functor0::operator()
    (this=0x23efbc8) at /usr/include/sigc++-2.0/sigc++/functors/mem_fun.h:1787
#12 0x00007ffff79d34cc in sigc::adaptor_functor<sigc::bound_mem_functor0 >::operator() (this=0x23efbc0)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:251
#13 0x00007ffff79d2a51 in sigc::internal::slot_call0<sigc::bound_mem_functor0, int>::call_it (rep=0x23efb90)
    at /usr/include/sigc++-2.0/sigc++/functors/slot.h:103
#14 0x00007ffff79d1a4a in sigc::internal::signal_emit0::emit (
    impl=0x23ac100) at /usr/include/sigc++-2.0/sigc++/signal.h:692
#15 0x00007ffff79d0460 in sigc::signal0::emit (this=
    0x7ffff7dd9d20 )
---Type  to continue, or q  to quit---
    at /usr/include/sigc++-2.0/sigc++/signal.h:2669
#16 0x00007ffff79cf00e in sigc::signal0::operator() (this=
    0x7ffff7dd9d20 )
    at /usr/include/sigc++-2.0/sigc++/signal.h:2677
#17 0x00007ffff79cc099 in ARDOUR::IO::enable_ports () at libs/ardour/io.cc:2433
#18 0x00007ffff7a3ddaa in ARDOUR::Session::hookup_io (this=0x1fc4b10)
    at libs/ardour/session.cc:922
#19 0x00007ffff7a3d3e2 in ARDOUR::Session::when_engine_running (this=0x1fc4b10)
    at libs/ardour/session.cc:841
#20 0x00007ffff7a9990a in ARDOUR::Session::second_stage_init (this=0x1fc4b10, 
    new_session=false) at libs/ardour/session_state.cc:331
#21 0x00007ffff7a37d2b in ARDOUR::Session::Session (this=0x1fc4b10, eng=..., 
    fullpath="/home/danson/composition/DissonantDance/Ardour2_DissonantDance", 
    snapshot_name="Ardour2_DissonantDance", mix_template="")
    at libs/ardour/session.cc:316
#22 0x0000000000922b6b in ARDOUR_UI::load_session (this=0x11d5600, path=
    "/home/danson/composition/DissonantDance/Ardour2_DissonantDance", 
    snap_name="Ardour2_DissonantDance", mix_template="")
    at gtk2_ardour/ardour_ui.cc:2668
#23 0x00000000009226db in ARDOUR_UI::get_session_parameters (this=0x11d5600, 
    backend_audio_is_running=true, should_be_new=false)
    at gtk2_ardour/ardour_ui.cc:2607
#24 0x000000000091a4d7 in ARDOUR_UI::startup (this=0x11d5600)
---Type  to continue, or q  to quit---
    at gtk2_ardour/ardour_ui.cc:669
#25 0x00000000009382a8 in sigc::bound_mem_functor0::operator()
    (this=0x1287d48) at /usr/include/sigc++-2.0/sigc++/functors/mem_fun.h:1787
#26 0x00000000009368ba in sigc::adaptor_functor<sigc::bound_mem_functor0 >::operator() (this=0x1287d40)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:251
#27 0x0000000000933d95 in sigc::internal::slot_call0<sigc::bound_mem_functor0, void>::call_it (rep=0x1287d10)
    at /usr/include/sigc++-2.0/sigc++/functors/slot.h:103
#28 0x0000000000928daa in sigc::internal::signal_emit0::emit (
    impl=0x1425b20) at /usr/include/sigc++-2.0/sigc++/signal.h:772
#29 0x000000000092dd04 in sigc::signal0::emit (this=0x11d5688)
    at /usr/include/sigc++-2.0/sigc++/signal.h:2669
#30 0x000000000092b414 in sigc::signal0::operator() (this=
    0x11d5688) at /usr/include/sigc++-2.0/sigc++/signal.h:2677
#31 0x00007ffff260dd14 in Gtkmm2ext::UI::run (this=0x11d5600, old_receiver=...)
    at libs/gtkmm2ext/gtk_ui.cc:229
#32 0x0000000000bdb540 in main (argc=1, argv=0x7fffffffd9b8)
    at gtk2_ardour/main.cc:585
(gdb) 

Please post this in Mantis(See the Issue Tracker link at the top of every page on the site), which is the appropriate place for bug reports and is much better suited for this. A copy of the problematic session file can also be attached there. You can also check in IRC and see if anyone can give you a hand in a more immediate fashion there as well, but no promises of course. I would also mention how old these sessions are you are trying to load.

Also please include any console output as well up to the hang point. Thanks.

  Seablade

Thanks very much for the reply. I’ve reported this in Mantis (ID 0005257).

I’ve seen JACK’s patchbay cause similar weirdness. If you’re using qjackctl, open Patchbay, deactivate any active patch, and see if the problem goes away.

If it does, then you may need to tweak your patchbay, or keep it inactive.

If the patchbay is causing problems and you don’t want to bother troubleshooting it, leave it deactivated, but make sure “patchbay persistence” is disabled. Go to Setup->Options and uncheck “Activate Patchbay persistence”

If it’s not checked, then don’t check it. This may compound the problem.