PDA

View Full Version : Problem running rtcheck on RT kernel



guyafe
03-Aug-2013, 12:02
Hi I am using SLES 11 with RT kernel.
I tried to run (as root) the rtcheck -v and got the following error:

RTCheck 0.7.6 - Linux Real-Time Environment Checker
---------------------------------------------------
RTCheck Initialization:
Locking all memory: ok
Setting up real-time scheduling: ok

System Tests:
Looking up boot_id (378798aa-d760-4d89-a52b-fecc5941127a): ok
Checking for out-of-tree RT extensions: ok
Checking for robust (PI) mutex support: ok
Testing for acceptable hrtimer resolution (<=100us): ok
Reporting 53us
Testing for acceptable clock resolution (<=200us): ok
Reporting 1ns
Caching results in /var/cache/rtcheck: ok

User Permission Tests:
Trying to lock memory: failed
RLIMIT_MLOCK is: 65536

Some tests failed, exiting with status: 1

It looks like some permissions issue, but I couldn't find any guide which explains how to solve this problem.
Does anyone know how to set the proper permissions to run RT on this OS?

Guy

jmozdzen
03-Aug-2013, 21:59
Hi Guy,


Hi I am using SLES 11 with RT kernel.
I tried to run (as root) the rtcheck -v and got the following error:

RTCheck 0.7.6 - Linux Real-Time Environment Checker
---------------------------------------------------
RTCheck Initialization:
Locking all memory: ok
Setting up real-time scheduling: ok

System Tests:
Looking up boot_id (378798aa-d760-4d89-a52b-fecc5941127a): ok
Checking for out-of-tree RT extensions: ok
Checking for robust (PI) mutex support: ok
Testing for acceptable hrtimer resolution (<=100us): ok
Reporting 53us
Testing for acceptable clock resolution (<=200us): ok
Reporting 1ns
Caching results in /var/cache/rtcheck: ok

User Permission Tests:
Trying to lock memory: failed
RLIMIT_MLOCK is: 65536

Some tests failed, exiting with status: 1

It looks like some permissions issue, but I couldn't find any guide which explains how to solve this problem.
Does anyone know how to set the proper permissions to run RT on this OS?

Guy

AFAIR rtcheck tests whether RLIMIT_MEMLOCK is RLIM_INFINITY, but in your case seems to be limited to 64k. So that would make it less a "permissions" problem, but rather one of too restrictive user limits.

Do you have "@realtime - memlock unlimited" in /etc/security/limits.conf and root is member of the realtime group (assuming that you performed the test as user "root" and rt is granted via group)?

Regards,
Jens

guyafe
04-Aug-2013, 06:57
Do you have "@realtime - memlock unlimited" in /etc/security/limits.conf and root is member of the realtime group (assuming that you performed the test as user "root" and rt is granted via group)?

Regards,
Jens

Thank you for your reply.
The memlock entry was correct, but as you said the root was not part of the realtime group. After adding it correctly to the group, the test went well.

Thanks,
Guy

codri
04-Sep-2013, 10:55
Hi,

I have the same problem:


RTCheck Initialization:
Locking all memory: ok
Setting up real-time scheduling: ok

System Tests:
Looking up boot_id (5def02a0-8284-4dc1-be99-57353438ca8d): ok
Checking for PREEMPT_RT kernel: failed
Kernel was not built with CONFIG_PREEMPT_RT=y
Checking for robust (PI) mutex support: ok
Testing for acceptable hrtimer resolution (<=100us): ok
Reporting 68us
Testing for acceptable clock resolution (<=200us): ok
Reporting 1ns
Caching results in /var/cache/rtcheck: ok

User Permission Tests:
Trying to lock memory: failed
RLIMIT_MLOCK is: 65536

Some tests failed, exiting with status: 9


How can i add the root to the realtime group?

Thanks

Andrea

jmozdzen
04-Sep-2013, 11:45
Hi Andrea,

Hi,

I have the same problem:



How can i add the root to the realtime group?

Thanks

Andrea

manually by editing /etc/groups accordingly. In YaST, it's "security and users" - "manage users and groups" (or something alike) - select the user in question ("root" in this case) and "Edit" - go to the details page - set the check mark for the group "realtime" - "OK" to confirm the change. Or via CLI program "usermod" (see "man usermod" for all the details).

You may have to re-login to make everyone aware of the change.

Regards,
Jens

codri
04-Sep-2013, 13:37
Thanks for the answer, I'm using Ubuntu 12.04 so there'is no Yast interface, and usermod is a bit complicate to use for me. how can i do?

jmozdzen
04-Sep-2013, 16:41
Hi codri,


Thanks for the answer, I'm using Ubuntu 12.04 so there'is no Yast interface, and usermod is a bit complicate to use for me. how can i do?

well, these are SLES forums, after all - it does have YaST ;) You only mentioned two of three ways I recommended... if usermod is too complicated for you, why not edit /etc/groups manually?

Regards,
Jens