Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 11-11-2010, 04:05 AM   #1
LQ Newbie
Registered: Nov 2010
Posts: 10

Rep: Reputation: 0
what is the difference /bin/bash and /bin/sh

i have linux server that dont have user unless root, but i want make another account user with limited access

when i try to make user use webmin i found /bin/bash and /bin/sh
which one do i must choose ? what is the difference ?
Old 11-11-2010, 04:10 AM   #2
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977Reputation: 1977
In principle they are different shells, with different features. There are LOTS of different shells out there, more or less common on different unix variants, e.g. csh, ksh, ash, tcsh and many others. It's quite possible that under your linux system they are actually identical, on my Fedora install I'm on now that is the case:

[chris@thinkpad ~]$ ls -l /bin/*sh
-rwxr-xr-x 1 root root 943360 May 21 18:32 /bin/bash
lrwxrwxrwx. 1 root root 4 Aug 19 20:49 /bin/sh -> bash

So it doesn't matter which one you choose, but then again you shouldn't need to actually make a choice at all anyway, you should never generally need to give any consideration to the shell you use, just leave it alone is probably the best answer. You can see the other shells used with other accounts in /etc/passwd among other places.
Old 11-11-2010, 04:39 AM   #3
LQ 5k Club
Registered: Dec 2008
Location: Tamil Nadu, India
Distribution: Debian
Posts: 8,577
Blog Entries: 31

Rep: Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195
If /bin/sh is a symlink to /bin/bash then the differences are listed here.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] /usr/bin/xterm: Could not exec /bin/bash: Permission Denied suheng Linux - Newbie 2 09-24-2010 06:31 PM
Difference between /bin/bash & /bin/sh paragkalra Programming 11 01-02-2009 07:10 AM
How to add paths to sbin, bin/bash, bin sh for users gopi.d Fedora 3 12-07-2007 01:47 AM
What is the difference between #!/bin/bash and #!/bin/sh? mTorbin Linux - Newbie 5 11-09-2005 01:10 PM
bin/bash:usr/bin/lpr NO SUCH FILE OR DIRECTORY Adibe_Hamm Linux - Newbie 3 10-14-2003 03:30 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:44 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration