Hot skills: Bash

What is it?

Microsoft's Powershell has been described as a tribute to the command line shells and scripting languages provided with Linux and Unix....

What is it?

Microsoft's Powershell has been described as a tribute to the command line shells and scripting languages provided with Linux and Unix. The most important of these is Bash, provided as the default shell with almost every Linux distribution.

Bash comes from the open source GNU project. The acronym stands for Bourne Again SHell, a typical open source community pun which refers back to the Bourne shell for Unix, on which Bash was largely built. It is an implementation of the IEEE POSIX shell specification, and is regularly enhanced to maintain its leadership in the surprisingly crowded field of Linux/Unix shells.

Bash has been described by Machtelt Garrels of the Linux Documentation Project as "intuitive and flexible... probably the most advisable shell for beginning users, while being at the same time a powerful tool for the advanced and professional user".

Where did it originate?

Bash was originally written in 1987 by Brian Fox of the Free Software Foundation. The current developer and maintainer is Chet Ramey of Case Western Reserve University. Bash's command syntax is a superset of the Bourne shell, with additional concepts from the Korn shell and C shell.

What's it for?

According to the Linux Documentation Project, "a working knowledge of shell scripting is essential to anyone wishing to become reasonably proficient at system administration, even if they do not anticipate ever having to actually write a script."

Shell scripting is used to automate common tasks that would otherwise have to be done repetitively and manually. The shell provides both an interface to the operating system's own utilities, and a programming language that, according to Bash maintainer Chet Ramey, allows these utilities to be combined. Ramey adds, "Most of the power (and complexity) of shells is due to their embedded programming languages."

Bash's command-line editing facility uses familiar Unix/Linux emacs or vi style text editing. Its history feature remembers commands and allows them to be recalled and re-executed. Users can search for previous commands and reuse bits of them when composing new ones. The Bash line editing library is fully customisable.

What makes it special?

Bash has many of the features of modern programming languages, including code completion and the ability to correct code without having to erase back to the point of error.

How difficult is it to master?

According to the LDP, you should be an experienced Unix or Linux user, familiar with basic commands, understanding matters such as system boot and shutdown processes, naming conventions for devices, partitioning and mounting/unmounting file systems, and creating users and groups. You will need to be able to use a text editor.

What systems does it run on?

Bash has been ported to nearly every version of Unix, configuring itself as part of the build process. It is shipped with most versions of Linux and with MacOS. There are ports to Windows (see the Cygwin website).

What's coming up?

Bash 4.0, which Chet Ramey promised for this summer, is due any time.

Rates of Pay

Linux systems administrators earn £30,000 to £45,000.


If not already supplied with your operating system, Bash can be downloaded from many places including the Bash - GNU Project or The GNU Bourne-Again SHell, which has links to sources for Solaris, AIX and other operating systems.

The Linux Documentation Project's Bash Beginner's Guide can be found online, along with an Advanced Bash Scripting Guide.

See Learning the Shell for more information.

This was first published in September 2008




Read more on Business applications



Forgot Password?


Your password has been sent to: