Sudo is can not find program / Path related issues
I am toying around with a LFS system and I am suddenly having trouble with sudo not finding binaries in the standard superuser only binary dirs (/sbin /usr/sbin). I am using sudo version 1.8.10p3. The sudoers file parses correctly and I did not modify except to allow users in the wheel group to be able use sudo to call any command. So I imaging something is wrong with the $PATH variable but I am not sure on what it is.
|
What does your sudoers file look like?
|
If you can run any command under sudo I'd think that sudo is working. Sudo ls -l for example.
Should work. http://stackoverflow.com/questions/1...-path-on-linux |
This is my sudoers
Code:
## sudoers file. Code:
Cmnd_Alias REBOOT = /sbin/halt, /sbin/reboot, /sbin/shutdown , /usr/sbin/pm-suspend Quote:
Code:
/bin:/usr/bin:/usr/local/bin Code:
/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin |
I think this discussion covers it pretty well...
I'd also look at Defaults secure_path which is mentioned in one of the comments. |
I had seen that discussion page before however it did get me thinking. I checked sudo -V on my remote lfs machine and my current machine with sudo working as I intended it and sure enough I forgot to set the --with-secure-path= flag before I compiled so sudo did not have defaulted a $PATH variable and fell back to my restricted users $PATH
|
All times are GMT -5. The time now is 10:15 AM. |