LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS
User Name
Password
CentOS This forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 08-21-2017, 03:40 AM   #16
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,782

Rep: Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304

If there was no other way I would temporarily remove everything from that sudoers file (I mean all the lines) and keep the only one you need to test the user.
 
Old 08-21-2017, 04:59 AM   #17
xq10907
LQ Newbie
 
Registered: Aug 2017
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by pan64 View Post
If there was no other way I would temporarily remove everything from that sudoers file (I mean all the lines) and keep the only one you need to test the user.
figured out,sudo only has ldap in name service setting, see following
Code:
[root@ark-centos-smb4 /]# grep sudo /etc/nsswitch.conf
sudoers:        ldap
since i have sssd configued so change to following to let sudo working for local users,domain users

[root@ark-centos-smb4 ~]# grep sudo /etc/nsswitch.conf
Code:
#sudoers:       ldap
sudoers:    files sss ldap
 
1 members found this post helpful.
Old 08-21-2017, 05:41 AM   #18
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,782

Rep: Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304Reputation: 7304
great!
If your problem is solved please mark the thread solved.
 
Old 08-21-2017, 08:37 PM   #19
xq10907
LQ Newbie
 
Registered: Aug 2017
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by MensaWater View Post
visudo will check syntax but doesn't check SELinux status. Did you check whether you have that enabled and enforcing? If it is did you check the SELinux context of /etc/sudoers?

Also did you verify permissions of /etc itself and /etc/sudoers?

If you look in /var/log/secure does it show any more detail about the failure?
Quote:
Originally Posted by pan64 View Post
great!
If your problem is solved please mark the thread solved.
Done,thanks for the help guys
 
1 members found this post helpful.
Old 08-22-2017, 12:06 PM   #20
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
Quote:
Originally Posted by xq10907 View Post
figured out,sudo only has ldap in name service setting, see following
Code:
[root@ark-centos-smb4 /]# grep sudo /etc/nsswitch.conf
sudoers:        ldap
since i have sssd configued so change to following to let sudo working for local users,domain users

[root@ark-centos-smb4 ~]# grep sudo /etc/nsswitch.conf
Code:
#sudoers:       ldap
sudoers:    files sss ldap
Nice. Until this post I didn't realize nsswitch.conf had a line for sudoers.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
centos7 Apache/2.4.6 - mod_remoteip Not working athreyavc Linux - Server 5 09-11-2018 05:09 PM
VNC not working with CentOS7 BhushanPathak Linux - Newbie 5 06-09-2017 01:38 AM
javac not working on my centos7 install sigint-ninja Linux - Newbie 2 07-10-2016 12:14 PM
usb speakers not working on centos7 sigint-ninja Linux - Newbie 2 07-09-2016 10:52 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS

All times are GMT -5. The time now is 08:48 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration