LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Mandriva (https://www.linuxquestions.org/questions/mandriva-30/)
-   -   JACK audio in realtime mode ... not working :o( (https://www.linuxquestions.org/questions/mandriva-30/jack-audio-in-realtime-mode-not-working-o-386921/)

dreamtheater 11-27-2005 05:20 AM

JACK audio in realtime mode ... not working :o(
 
Hello!

I've installed kernel-multimedia-2.6.12-12.mm.1mdk for Mandriva 2006. The realtime module is loaded with 'dmesg | grep -i realtime' yielding:

Realtime LSM initialized (all groups, mlock=1)

When I try to start JACK audio server in realtime mode (via qjackctl) it tells me:

cannot lock down memory for RT thread (cannot allocate memory)
cannot use real-time scheduling (FIFO at priority 9) [for thread -1223894096, from thread -1223894096] (operation not permitted)

[cannot lock down memory for RT thread (Nicht genügend Hauptspeicher verfügbar)
cannot use real-time scheduling (FIFO at priority 9) [for thread -1223894096, from thread -1223894096] (1: Die Operation ist nicht erlaubt)] (same message as above, german)

So jack won't run in realtime mode and I always get xruns. How can I fix this problem?

Thanks in advance!

tkedwards 11-27-2005 09:52 PM

Does this help: http://music.columbia.edu/pipermail/...er/017889.html

Are you sure the module loads properly - do
Code:

/sbin/lsmod | grep -i real
after you've loaded it

Have you tried running it as root?

dreamtheater 11-28-2005 11:13 AM

Runnin JACK in realtime as root works. But that's not very comfortable...

darc26 12-07-2005 12:56 PM

Quote:

Originally Posted by dreamtheater
Hello!

I've installed kernel-multimedia-2.6.12-12.mm.1mdk for Mandriva 2006. The realtime module is loaded with 'dmesg | grep -i realtime' yielding:

Realtime LSM initialized (all groups, mlock=1)

When I try to start JACK audio server in realtime mode (via qjackctl) it tells me:

cannot lock down memory for RT thread (cannot allocate memory)
cannot use real-time scheduling (FIFO at priority 9) [for thread -1223894096, from thread -1223894096] (operation not permitted)

[cannot lock down memory for RT thread (Nicht genügend Hauptspeicher verfügbar)
cannot use real-time scheduling (FIFO at priority 9) [for thread -1223894096, from thread -1223894096] (1: Die Operation ist nicht erlaubt)] (same message as above, german)

So jack won't run in realtime mode and I always get xruns. How can I fix this problem?

Thanks in advance!


You need to do 2 things. Both of them need to be done as root.
1. Using the User Manager add your user to the "audio" group. You do this by selecting your user - edit - groups - put a check mark in the box for audio.
2. You need to edit the file /etc/limits.conf => there will be a line that says
@audio - realtime priority 50 ( or something like that)
you need to change that 50 to something like 80 or 100 (100 is the max)
You then need to add this line in that same file:
@audio - memlock xxxxx ( x is a number ) a good rule of thumb is to make that number equal to half your ram. So if you have a Gig of ram - that number would be 512000

Then just log out of your user account... log back in... and you should be good to go. Let me know if it works.

dreamtheater 12-10-2005 05:02 AM

Hello again!

All I can say is: I followed your instructions and they worked!

So in Mandriva 2006 it's 3 easy steps to get jack working in realtime mode:

1. Install the multimedia kernel from the contrib packages.

Code:

urpmi kernel-multimedia-2.6.12-12.mm.1mdk
2. Configure the realtime module

In /etc/modprobe.conf I commented out capability and added realtime like that:

Code:

# capability

realtime mlock=1 gid=81

Where gid=81 corresponds to the group id of the audio group (according to /etc/group) which I added myself to via drakuser. I could also have substituted gid=81 for any=1 which would have granted any user realtime privileges.

3. Modify limits.conf

In Mandriva 2006 limits.conf is located in /etc/security/

I've got 512MB RAM so I edited the appropriate section to read:

Code:

@audio          -      rt_priority    80
@audio          -      nice            -10

@audio          -      memlock        256000

After booting the new kernel, qjackctl should be able to start jack in realtime mode.


All times are GMT -5. The time now is 03:44 AM.