Trouble editing limits.conf (Ubuntu 18.04)

So Ardour informs me the memlock value in the above mentioned file is set too low. I go
sudo gedit /etc/security/limits.conf
and add the line
#* soft memlock 500000
as suggested in some thread I forgot where I found.
but I get three warnings. gedit: spell language, encoding, and position not supported
Help please, what do I do?

get rid of the # in front of it, that turns it into a comment.

The way I have seen this done is to use the audio group. What does your limits.conf look like at the moment?

If it has:

@audio - memlock unlimited

Then you simply need to add your user to the audio group.

Thank you both for your suggestions. But the problem is that gedit is unhappy with my spell language and encoding no matter what I write. I solved the “position”; I had mindlessly been using tabs and it wanted space between the columns. But the other two? I have no idea what encoding is expected

Most of the time you can safely ignore warnings. If gedit saves the file correctly, you’re good. :slight_smile:

Oh I didn#t know that … still, I seem to be unable to change anything in the systems behaviour.

This is Ardours warning:

WARNING: Your system has a limit for maximum amount of locked memory. This might cause Ardour to run out of memory before your system runs out of memory.

You can view the memory limit with ‘ulimit -l’, and it is normally controlled by /etc/security/limits.conf

This is what ulimit -l returns:

16384

This is my limits.conf … i took everything that I tried to put in there out again since it didn#t help. Looks as if everything is commented out:

#

#* soft core 0
#root hard core 100000
#* hard rss 10000
#@student hard nproc 20
#@faculty soft nproc 20
#@faculty hard nproc 50
#ftp hard nproc 0
#ftp - chroot /ftp
#@student - maxlogins 4

End of file

I may have to look somewhere else but where?

You have nothing in your limits.conf that sets anything at all - everything is commented by # at the start of the line.

You need an entry that actually sets things, such as:

@audio   -  memlock    unlimited

On many Linux systems, there is folder called /etc/security/limits.d that contains individual files that set specific parameters. On my (Debian) system, for example, I have /etc/security/limits.d/audio.conf which contains:

@audio   -  rtprio     95
@audio   -  memlock    unlimited

Thank you sir, this did the trick. My audio.conf looks exactly the same so after adding myself to the audio group, problem was solved. Great job paul!!

I just spotted another similar post, users should generally do things in /etc/security/limits.d/ – since /etc/security/limits.conf is a package-level configuration that could update itself while omitting all previous user changes from it.

jackd is normally responsible for installing this file. on any debian based system (like ubuntu) a reinstall or update of jackd does not change this file. (which should just work as is anyway) On ubuntu, the ubuntustudio-controls package will install this file as well after asking the user. It will also add the user to the audio group for the next time the user logs in.