Virtual Private Server User Guide
Internet and UNIX Basics
Your choice of shell is basically a matter of taste. If you are a C programmer, you
might feel more comfortable with a C like shell such as tcsh. If you ve come from
Linux or are new to a UNIX command line interface you might try bash. The point
is that each shell has unique properties that may or may not work with your
preferred working environment, and that you have a choice of which shell to use.
Changing Your Shell
The easiest way to change your shell is to use the chsh command. Typing the
following will change your shell to bash:
> chsh s /usr/local/bin/bash
Running chsh without the s flag will open your preferred editor and allow you to
change several other user settings, such as your full name, in addition to which
shell you want to use. You must exercise care in running the chsh command.
Giving it a nonexistent shell, or even making a simple typo on the shell path, will
result in you not being able to log in the next time you try.
Filename Completion
One common feature of a shell is filename completion. All of the shells that are
preinstalled on your virtual server, with the exception of the Bourne shell (sh),
include filename completion.
After typing the first few letters of a command or filename, you can usually have
the shell automatically complete the rest of the command or filename by hitting the
[TAB] key on the keyboard. If more than one file begins with the same string of
characters, the file name will be completed only to the point at which the character
strings differ.
Example: Suppose you have the following files within the same directory:
> ls
test.txt
test2.txt
tester.php
testing.sample
Now, suppose you wish to delete the testing.sample file. You might try typing the
following command:
> rm te[TAB]
However, after the filename completion, the following would display:
> rm test
Because there is more than one match, the filename completion cannot continue
beyond the point at which the strings are identical. To complete the filename, you
must:
Technical Training Department
August 2004
1 15