[LAU] Multiple fluidsynth instances

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: A list for linux audio users <linux-audio-user@...>
Date: Sunday, November 24, 2013 - 4:27 pm

Hi folks,

I was recently stuck on an issue that I could not readily find
solutions for online. So I thought documenting the solution here may
be of use to someone in the future.

Problem: when attempting to start two independent instances of
fluidsynth in server mode from the command line, I get the following
error:

fluidsynth: error: Failed to bind server socket

After a bit of research, it seems that the problem is a result of the
fact that in server mode (and probably in other modes as well, though
I am not sure) fluidsynth communicates with the shell through a socket
on the local machine. From what I saw in the source, there is no
automatic checking to see if the default port is already bound, so the
second instances tries to grab the same socket as the first, and fails
with the above error. There is a setting "shell.port", which needs to
be set explicity in this case (see man page). the -o command line
option allows one to define settings. In the end, the following two
commands give me the kind of environment I need (notice the "-o
shell.port="):

$ fluidsynth -a jack -m alsa_seq --portname=fluidsynth_piano
--no-shell -s -g 1 \
-o audio.jack.id=fl_piano -o shell.port=9800 piano.sf2 &

$ fluidsynth -a jack -m alsa_seq --portname=fluidsynth_drums
--no-shell -s -g 1 \
-o audio.jack.id=fl_drums -o shell.port=9801 drums1_harris.sf2 &

I do not know if this problem occurs when using Qsynth, I am doing
this in a text only environment.

Machine info:
$ uname -a
Linux mervag 3.12.1-1-ARCH #1 SMP PREEMPT Thu Nov 21 08:18:42 CET 2013
x86_64 GNU/Linux

$ jackd -V
jackdmp 1.9.9.5
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@lists.linuxaudio.org
http://lists.linuxaudio.org/listinfo/linux-audio-user

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

This is the only confirmed message in this thread.