LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Solaris / OpenSolaris (http://www.linuxquestions.org/questions/solaris-opensolaris-20/)
-   -   Default shell (http://www.linuxquestions.org/questions/solaris-opensolaris-20/default-shell-545658/)

songeek 04-13-2007 02:16 AM

Default shell
 
Hello Everyone,

Currently default shell for root is /sbin/sh and if i would like to change the default to /sbin/bash

how can i go about doing this,

and also if i want to make some changes to a shell permanently i have to usually incorporate changes to either .bashrc or .profile file isnt it ?

I am sorry I know i am a bit vague but dont really know better way to put things

Thanks in Advance

linuxtesting2 04-13-2007 03:13 AM

You can change shell in /etc/passwd (http://www.roble.com/docs/sol_root_shell.html)

Check out /etc/profile || /etc/skel/


Ole

cseanburns 04-13-2007 03:38 AM

Instead of messing with the /etc/passwd file, you can use the 'chsh' command:

> chsh

See the manpage fmi.

> man chsh

You'll need to know the path for bash:

> which bash

.bashrc is a good file to use. You can get all kinds of examples from searching and you most likely will have a copy of one on your system already. Check the /etc directory. I have one called /etc/bash.bashrc.

Here's more info:

http://www.faqs.org/docs/abs/HTML/files.html

jlliagre 04-13-2007 08:45 AM

There is no (more) a "chsh" command under Solaris.

The closest equivalent is "passwd -e <username>".

cseanburns 04-13-2007 01:23 PM

Quote:

Originally Posted by jlliagre
There is no (more) a "chsh" command under Solaris.

The closest equivalent is "passwd -e <username>".

Woops, I didn't realize what board I was in. :)


All times are GMT -5. The time now is 03:35 PM.