Can I make the root shell in Solaris 8 and 9 /bin/bash?

Posted on 2003-03-05
Medium Priority
Last Modified: 2013-12-27
I have always heard to leave that the root shell should be /bin/sh, but I would like to change it to bash.  I think this would be okay, since bash is backwards compatible to sh in every way I can think of.  I just wanted to know if there are any reasons why I should not do this.  Thanks.
Question by:barthalamu
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 48

Accepted Solution

Tintin earned 800 total points
ID: 8075142
The root shell is not /bin/sh, it is /sbin/sh (BIG difference).

/sbin/sh is a statically linked shell, ie:  it doesn't rely on external libraries.

Changing root's shell to a dynamically linked version in /bin can have consequences when you have troubles with your system and say the /usr filesystem is corrupted and the machine boots in single user mode.  Whoops, root's shell need the libraries in /usr to function.
LVL 21

Expert Comment

ID: 8075938
As Tintin said, don't do it!

But he also made a good suggestion in

However, you should only log in as root when you need to do administrative tasks, so don't make it too easy to use or you'll end up logging as root all the time - and it's very easy to trash the system by mistake if you are root ;-)

Author Comment

ID: 8075968
Thank you both for your help.  Also thanks for the reason why I have always heard not to use any other shell but sh, Tintin.  Also, my mistake, I should have said /sbin/sh instead of /bin/sh.  Thanks.

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

FreeBSD on EC2 FreeBSD (https://www.freebsd.org) is a robust Unix-like operating system that has been around for many years. FreeBSD is available on Amazon EC2 through Amazon Machine Images (AMIs) provided by FreeBSD developer and security office…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Suggested Courses
Course of the Month8 days, 10 hours left to enroll

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question