cannot open session/ JACK connection

cannot open a session.
“ARDOUR is not connected to JACK” comes up when try to open a session.
what are the likely cause?
I’m on latest UBUNTU release. 10.04 LTS, installed fresh just a while ago.
can’t quite track down the same problem online.
thanks in advance for any help.

I think there is an error with the packaging of JACK on 10.04, when I installed it, it asked me if I wanted it to make some changes to the /etc/security/limits.conf file that are essential for reliable JACK operation. I selected “Yes” and it said it had done it, although in reality it hadn’t.

Open your /etc/security/limits.conf using gedit, from the terminal type

sudo gedit /etc/security/limits.conf

Add the following lines

@audio - rtprio 95
@audio - memlock 512000
@audio - nice -19

You might have to change the memlock value to suit the amount of memory your system has. After you have edited the file, you will also need to add your username to the audio group. At the terminal type:

sudo usermod -a -G audio username

where username is the name you login with. When you do these commands you may be prompted for your password in order to authenticate yourself to make the changes, just enter your normal user password (the one you log in with)

When you have made these changes, log out and back in again (I normally do a complete restart) and now JACK should be able to start in realtime mode and ardour should start working.

thanx, more prob., this problem seems similar to mil. question threads here and there, but it still remain so.

Given that all of your suggestions been done,

as of JACK:

  1. after reboot, JACK starts, but crashes or similar. more like freezes.
  2. forcequit it, then Jack does not start again.
  3. when so, it spits message, that says ‘default server already active’ somewhere along the lines
  4. the message also says memlock unlimited is dagerous(even though it is not set so in ./limit.conf)

as of ARDOUR
it says: ARDOUR could not start JACK, someone else using it or try different parameters.

I do find similar threads everywhere but nothing definite been found.
what’s the best move from this stage?
thanks in advance

@linuxdsp: on at least some versions of Ubuntu, the edit is no longer made directly in limits.conf, but shows up in /etc/security/audio.conf. Just FYI.

@paul: That’s interesting, I wasn’t aware that had changed (although on my 10.04 install I only seem to have /etc/security/limits.conf - after a clean install, followed by installing ardour / jack from the ubuntu repositories) - Perhaps the problem I had is more likely related to just not being added to the correct group after installing jack, I just did all the changes and it worked, but perhaps all I really needed to do was add myself to the correct group.

On my install of Ubuntu 10.04 it asked if I wanted to install the realtime kernel, but it ended up not getting installed. I am going to try a fresh install tonight, but paying more attention to the prompts, and see if it is a bug witht he install.

yyup, it in the end isn’t making a lot of sense… I guess.
i’ll just try get fresh install of Studio,(though then they’ll be some cinelerra install problems…yikes)
well, that seems to be relatively easier than this particular problem for me…
for the time being…
thank you all tho.
keep posting up if any has any idea, that’ll help, thanks.

I just did the fresh install, and the rt kernel is not installed by default. I had to do a

apt-get install linux-rt

to get a real time kernel in ubuntu studio 10.04

But Jack still does not start.

Will post over in the Jack forums to see what might be the issue.

I think this is what is going on.

jackd does set up a file called

/etc/security/limits.d/audio.conf

with the lines

@audio - rtprio 99
@audio memlock unlimited
#@audio nice -19

If you run Ubuntu Studio Controls it will add lines to

/etc/security/limits.conf

that may conflict with the

/etc/security/limits.d/audio.conf file

I deleted the lines from the

/etc/security/limits.conf

Rebooted and jack starts and stops nicely.

Now to figure out how to use Ardour…

I just remembered, I had to purge pulseaudio from my machine in order to get any sound to work with anything (including getting JACK to run - I can’t guarantee this won’t break anything else (like desktop sound-effects or youtube stuff in a browser etc, but on an audio machine you shouldn’t need that anyway :slight_smile: it might be worth trying:

sudo apt-get purge pulseaudio

After I did that everything worked fine (just like it did for me in the days before PulseAudio inexplicably became the default method for screwing the sound up… Grrr… I suppose Pulse does at least enable the ubuntu bongos to play during boot up without a glitch, even if nothing else works afterwards… as if I really needed that…)

@grtyvr: I guess /etc/security/limits.d/audio.conf must be the file that Paul was refering to - I was looking for /etc/security/audio.conf - it seems as though the problems I had after installing JACK were related to not being correctly added to the audio group and not the config file, although I changed the /etc/security/limits.conf file because that was where it always used to be… and got rid of pulseaudio…

PURGE PULSEAUDIO
THAT’S THE WAY WE LIKE IT
THANKS

Followed steps posted by linuxdsp and that fixed the problem:

Open your /etc/security/limits.conf using gedit, from the terminal type

sudo gedit /etc/security/limits.conf

Add the following lines

@audio - rtprio 95
@audio - memlock 512000
@audio - nice -19

You might have to change the memlock value to suit the amount of memory your system has. After you have edited the file, you will also need to add your username to the audio group. At the terminal type:

sudo usermod -a -G audio username