# Problem running rtcheck on RT kernel

**URL:** <https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229>\
**Category:** SLES Configure-Administer\
**Created:** [August 3, 2013, 2:02pm UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229 "2013-08-03T14:02:05Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![guyafe](https://avatars.discourse-cdn.com/v4/letter/g/77aa72/32.png) [@guyafe](https://forums.suse.com/u/guyafe)\
**Post date:** [August 3, 2013, 2:02pm UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229/1 "2013-08-03T14:02:05Z")

</div>

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

## [CODE]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[/CODE]

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

---

<div class="post-metadata">

**Author:** ![Jens-U](https://avatars.discourse-cdn.com/v4/letter/j/d78d45/32.png) [@Jens-U](https://forums.suse.com/u/Jens-U)\
**Post date:** [August 3, 2013, 11:59pm UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229/2 "2013-08-03T23:59:40Z")

</div>

Hi Guy,

[QUOTE=guyafe;14908]Hi I am using SLES 11 with RT kernel.  
I tried to run (as root) the rtcheck -v and got the following error:

## [CODE]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[/CODE]

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[/QUOTE]

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

---

<div class="post-metadata">

**Author:** ![guyafe](https://avatars.discourse-cdn.com/v4/letter/g/77aa72/32.png) [@guyafe](https://forums.suse.com/u/guyafe)\
**Post date:** [August 4, 2013, 8:57am UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229/3 "2013-08-04T08:57:06Z")

</div>

[QUOTE=jmozdzen;14911]

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[/QUOTE]

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

---

<div class="post-metadata">

**Author:** ![codri](https://avatars.discourse-cdn.com/v4/letter/c/76d3ee/32.png) [@codri](https://forums.suse.com/u/codri)\
**Post date:** [September 4, 2013, 12:55pm UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229/4 "2013-09-04T12:55:02Z")

</div>

Hi,

I have the same problem:

[QUOTE]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  
[/QUOTE]

How can i add the root to the realtime group?

Thanks

Andrea

---

<div class="post-metadata">

**Author:** ![Jens-U](https://avatars.discourse-cdn.com/v4/letter/j/d78d45/32.png) [@Jens-U](https://forums.suse.com/u/Jens-U)\
**Post date:** [September 4, 2013, 1:45pm UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229/5 "2013-09-04T13:45:58Z")

</div>

Hi Andrea,

[QUOTE=codri;15685]Hi,

I have the same problem:

How can i add the root to the realtime group?

Thanks

Andrea[/QUOTE]

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

---

<div class="post-metadata">

**Author:** ![codri](https://avatars.discourse-cdn.com/v4/letter/c/76d3ee/32.png) [@codri](https://forums.suse.com/u/codri)\
**Post date:** [September 4, 2013, 3:37pm UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229/6 "2013-09-04T15:37:30Z")

</div>

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?

---

<div class="post-metadata">

**Author:** ![Jens-U](https://avatars.discourse-cdn.com/v4/letter/j/d78d45/32.png) [@Jens-U](https://forums.suse.com/u/Jens-U)\
**Post date:** [September 4, 2013, 6:41pm UTC](https://forums.suse.com/t/problem-running-rtcheck-on-rt-kernel/24229/7 "2013-09-04T18:41:58Z")

</div>

Hi codri,

> [@codri;15694](#):
>
> 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
