View Full Version : setsebool not recognized as a command?

20th July 2006, 04:09 AM
Hey, I'm installing my nvidia drivers and for some reason setsebool is not recognized as a command? I installed them before without this problem. What should I do?

[root@localhost ~]# setsebool -P allow_execstack=1
bash: setsebool: command not found

20th July 2006, 04:26 AM
Sorry, I figured out the problem - needed to log in as root.

16th August 2006, 04:34 AM
I'm having the same problem...

I think I am logged in as root but ????

It looked like you were logged in as root also??



[root@localhost holbrooka]# setsebool -P allow_execstack=1
bash: setsebool: command not found

16th August 2006, 04:44 AM
Ok, I found the file in /usr/sbin/setsebool

I went there and attempted the command with the same results

I tried

[root@localhost sbin]# sh setsebool
setsebool: setsebool: cannot execute binary file

so it is still not working... my local linux geek said something about it not being compiled?? What? Oh boy I'm confused!

thanks for any help!


16th August 2006, 07:10 AM
Ok, I found out a little bit more trivia in my searches....

It seems the su function has some options of its own! You must use

su -

as opposed to


This thread explains why. I used su - and I didn't get the error message anymore!

Thanks to all!


16th August 2006, 07:30 AM
Because su gives you root permission but keeps the users environment. su - gives you root premission with root environment. /user/sbin is not in your path, but is in roots path.

16th August 2006, 03:39 PM
Thanks for the info on the su/su - commands.

I think there may be a little more going on here also. I traveled to the usr/sbin directory as root and tried the command with the same error. It seems that the su command is not truly the root user but the "sudo" root user login (as it seems from the thread I referenced). Once I logged in as the root user with the su -, I was able to run the command, just like you said, because I was in the root environment, but also because I was ACTUALLY the root user instead of the sudo root user.

That is may take on it since it didn't work when I was physically in that directory...I just tried it again, since I'm new to things I obviously screw things up a lot. But it still doesn't seem to work when I am in the directory usr/sbin.

[root@localhost sbin]# ls setse*
[root@localhost sbin]# setsebool
bash: setsebool: command not found

Luckily the su - got it working so it is installed, not that I noticed ANY difference with or without it!