Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17


Difference between shells

Posted on 2001-07-17
Medium Priority
Last Modified: 2010-04-20

I am new to Linux. I would like to ask what is the difference between the types of shells in Linux for example Cshells, sh/Bourne shells and dos shell. What is it that makes them different and when we use different shells?

What about the differences between terminals and consoles?

Thanks for reading and sorry for being naive in this.
Thanks so much. Regards
Question by:megmeg
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

Accepted Solution

DanEgli earned 120 total points
ID: 6296285
A short question, but a long answer :>

1) Shells:
there are really only 4 shells that are common to almost any linux distro:

Bash == Borne Again SHell. NICE! Lot of feature, but a bit big in the memory area (uses a LOT of memory)
sh == BASH's predecessor, the bourne SHell. Doesn't really exist anymore. It's a link to bash in most distros.

KSH == Korn SHell. A half way point between BASH and old Borne shell stuff. The original Korn shell was a commercial product. Thats why you may notice this is called pdksh. The pd is for Public Domain. It's a free rewrit that someone did for Korn. Shell. I use it a lot for scripts that require patern matching and patern substitution on strings.

ZSH == Lightweight contender against bash. Has a lot of the same features (not all of them) and a much smaller memory footprint. I don't use it but I know folks who do.

CSH/TCSH == C SHell / Turbo C SHell
These are moderately powerful shells (TCSH being stringer than CSH) that don't use the normal unix scripting language. Instead they use a more C like syntax for their scripts. I personally don't like it but a friend of mine swears by it.

2) Difference between terminals and consoles:
a TERMINAL is a remote entry port or a local entry port. If I telnet to my ISP's mail server, the logon screen is displayed on my TERMINAL screen. The CONSOLE represents the physical keyboard/mouse/monitor attached to the machine. If someone is logged into a terminal, they're probably remote. If they're logged in through the CONSOLE, then they MUST be physically at the computer.


Expert Comment

ID: 6300788
The choice of shell seems to be a matter of personal preference. Since BASH and TCSH are the most full featured shells in common use most people starting out in Unix/Linux will use one of these. The first one you get to know reasonably well will probably be the one you use for a long time to come.

Expert Comment

ID: 6306416
In the Unix world, the console is considered to be the terminal that the system boots up on.  All other screen devices are usually referred to as terminals (as in dumb terminals).  Dumb terminals do not have memory or a hard disk drive and are usually a cheaper alternative for connecting users to a Unix system.  A PC can be considered a terminal if it is connected via a serial line to the Unix system and is running terminal emulation software.  An Xterminal would be a terminal that has graphics capability.  A true dumb terminal is not a networking device and would connect using a serial port.  In the Linux world, I would consider the console to be the monitor where you see Linux boot messages.  All other screen devices would be considered terminals.

Although bash is a link to sh, sh is the original Unix shell and has its limitations.  The bash seems to incorporate the best features from previous shells such as history, aliases, foreground/background tasking, etc.  Some of us that use versions of Unix that do not have bash tend to rely on sh since it is on all Unix systems.  Other shells evolved over the years with enhanced features compared to sh.  For example, csh was developed by University of California at Berkeley (UCB) and gave us aliases and command history.  If you are pretty much a Linux user, I would use the bash shell.  

Featured Post

RHCE - Red Hat OpenStack Prep Course

This course will provide in-depth training so that students who currently hold the EX200 & EX210 certifications can sit for the EX310 exam. Students will learn how to deploy & manage a full Red Hat environment with Ceph block storage, & integrate Ceph into other OpenStack service

Question has a verified solution.

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

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
Suggested Courses

721 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