Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Asking for root password when restarting services
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
Belliash
Advocate
Advocate


Joined: 24 Nov 2004
Posts: 2428
Location: Wroclaw, Poland

PostPosted: Thu Mar 22, 2018 2:07 pm    Post subject: Asking for root password when restarting services Reply with quote

Hello guys,


I have recently migrated from GrSec to SELinux and actually, sometimes when I try to start/stop/restart/reload service it is asking me for root password ...

Of course I have root right already. I have this on 2 machines: This is the output from `id`:
id:
uid=0(root) gid=0(root) groups=0(root) context=staff_u:staff_r:staff_t

id:
uid=0(root) gid=0(root) groups=0(root) context=staff_u:sysadm_r:sysadm_t


As you can see context if different but problem exists on both of them.

Sometimes this is working nicely, but sometimes `rc-service [service] restart` or /etc/init.d/[service] lead to the following prompt:
:
# rc-service nginx reload
Authenticating root.
Password:


How can I fix that? It is really annoying that I need to enter root password all the time....



Code:
# rc-service sshd restart
sshd              | * Stopping sshd ...                                                                                                                                                                                                [ ok ]
sshd              | * Starting sshd ...                                                                                                                                                                                                [ ok ]

# /etc/init.d/cronie restart
Authenticating root.
Password:


[Moderator edit: changed [quote] tags to [code] tags to preserve output layout. -Hu]
_________________
Asio Software Technologies
Belliash IT Weblog
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum