Xiode

Well-Known Member
Oct 14, 2005
73
0
156
a while back just after we got the server I tried setting up a user to login to shell with. Then I could just su to root. like your suppose to well I was unable to get su to work. so I abandoned it until a later date.. I could login no problem. I had so many pressing things to setup and do.. Well recently I was reading a tutorial on a program setup and noticed that it recommended to su to root... Well I got back to playing with it and the problem persists... Tell me if I am doing this wrong... I logged in to root the normal way with "root" "pass".... then "adduser **** " then "passwrd **** " and logged out of SSH using root.. and logged in with ****. Now when I su I get this.

****@satellite1 [~]# su
-bash: /bin/su: Permission denied

Is there another way in WHM that I accomplish this.. or am I just being stupid and doing it the wrong way...
 

jayh38

Well-Known Member
Mar 3, 2006
1,212
0
166
WHW > Security > Manage Wheel Group Users

add the user to the group....
 

Xiode

Well-Known Member
Oct 14, 2005
73
0
156
knew I had to be doing something wrong... Now can't I take root off that list and use then new name... that wouldn't let anyone be able to login with root and you could still login with **** and then su to root?
 

mctDarren

Well-Known Member
Jan 6, 2004
665
8
168
New Jersey
cPanel Access Level
Root Administrator
Not sure if removing root from wheel will cause permission problems when you su into it from your login user account... ? Never actually thought about that one before. :)

However you can stop ssh from allowing root to login by editing the sshd conf file. Usually /etc/sshd/sshd_config - find the line "PermitRootLogin" and change the value after it to "no". Restart and it will no longer accept root login.

Be sure to test logging in through your other account and switching into root - using "su -", not just "su". Once you know it works you can disable root login as described above. I also recommend using only Protocol 2, and changing the default port to avoid those annoying dictionary attacks.