Skip to content

A new root shell.

July 2, 2005

Fed up with the bourne shell for root? All the power of root but with a proper shell, not csh, a proper shell! You can add a role with the korn shell or any other shell and then assign that role to the users you wish to be able to access it. They still have to type the password of the role but they get a sensible shell when they get it right, plus others don’t even get the option.

Here is how. For the a korn shell “root” account:

# roleadd -d /root -P "Primary Administrator" -s /usr/bin/pfksh kroot 
# usermod -R root,kroot me 
# passwd kroot 
New Password: 
Re-enter new Password: 
passwd: password successfully changed for kroot 

Now I have a role, kroot, to which only I can su(1M) and it has a decent shell. I can still use the root role if I want pain and I have not changed root’s shell which is probably a good thing. Make sure /root already exists, it did for me as it is root’s home directory already.

Tags: topic:[Solaris] topic:[ksh] topic:[csh] topic:[rbac] topic:[roles]


From → bsc, Solaris

Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: