Next: About this document
Up: No Title
Previous: Running computationally intensive jobs
The following sections may be useful guides if you are familiar with the VMS
or MS-DOS operating systems.
The UNIX and VMS operating systems both have advantages and
disadvantages and there is no answer to the question ``which one is
better?'' The main reason that UNIX has become so popular is that it is
runs on many different types of machines, not just on Digital Equipment
Corporation VAXes. It is also cheaper to buy and it is typically
many times faster than VMS on machines of similar cost.
Here are a few comments on the differences between UNIX and VMS from a
user's perspective (albeit one biased in favour of UNIX).
- UNIX is terser. VMS tends to use easy to remember (although often
verbose)
English language option names, whereas UNIX uses single letters. Once
you become familiar with UNIX you will appreciate the compactness of the syntax,
however, it is difficult for beginners.
- UNIX distinguishes between upper and lower case letters in command and
file names, i.e., the file prog.f is quite distinct from PROG.F,
Prog.F, and so on. This takes a bit of getting used to. In particular,
you must use lower case letters for your username when login,
otherwise UNIX will assume that you only have an upper case terminal and
will refuse to echo lower case characters.
- UNIX filenames are more logically organized than VMS. VMS uses
a clumsy square bracket notation which makes it difficult to parse
filenames. With UNIX there is no need to worry about the various fields
of the file specification (e.g., disk, directory, filename, filetype).
- Some VMS commands assume default file types if you don't specify one.
For example PRINT TEXT will print the file TEXT.LIS. UNIX makes
no such assumptions, and if you specify the file TEXT then that is
what you will get. A side effect of this is that you must specify complete
filenames when using UNIX compilers. For example, when using VMS the command
FORTRAN PROG will compile the program PROG.FOR, whereas the
UNIX equivalent is f77 prog.f (note also that the UNIX FORTRAN
compiler requires source files to end in ``.f'').
- UNIX treats all files and peripherals as streams of bytes, whereas
VMS has a multitude of different file organizations (e.g., sequential,
fixed-length, indexed, blocked, unformatted, relative, and so on). Using
UNIX you can easily read a tape as a byte-stream, whereas with VMS you have
to worry about record-lengths and buffer-sizes.
- The output from UNIX commands is designed to be easily processed
by following commands. For example, a directory listing obtained with
the UNIX command ls -l has a simple format, whereas
the VMS equivalent DIRECTORY/SIZE/DATE/PROTECTION is not so simple.
Also UNIX has the mechanisms of pipes and I/O redirection, which can
not be simulated with VMS.
- UNIX has a superb wildcard facility based on a concept known as
``regular expressions'' that is
considerably more flexible than VMS. For example, ls [0-9]*.dat will list all
the files in the current directory that have filenames beginning with a digit
and ending in ``.dat''.
- You execute UNIX programs by simply typing their name. With VMS
you have to type ``RUN PROG'', and there is the added complexity
that if you want the program to be able to read the command line, you
have to set it up as a foreign command. UNIX is simpler and more
logical in its approach. UNIX has the concept of a PATH, i.e., a list of
directories in which it searches for commands to execute. VMS has no
equivalent feature.
- UNIX gives you a choice of shells (a ``shell'' is simply the program
that is the interface between you and the operating system)
some of which are considerably
more flexible than the VMS ``shell'', e.g., they have filename completion
and the recall of a user-selectable number of commands.
Filename completion is sufficient reason alone for abandoning VMS in
favour of UNIX.
- Starting a sub-process in UNIX is very much easier and faster than
the equivalent in VMS. VMS uses a clumsy system of mailboxes to transmit
environment information to sub-processes, and this slows down their
creation.
- UNIX displays characters on your terminal as you type them, regardless
of whether the operating system is ready to accept a command. VMS will
buffer, but not display, terminal input when it is busy executing the
previous command.
- There is more public domain software available for UNIX. Some
of this software is of very high quality, and the VMS equivalents cost
many thousands of dollars.
- On the negative side, there is no doubt that UNIX documentation is
far less readable than VMS documentation. The VMS HELP command is
probably superior to UNIX's man. A nasty aspect of UNIX is that the
various error messages that commands may produce are rarely documented,
whereas every VMS message is catalogued.
- VMS has superior built-in BATCH queues. Under UNIX, batch queues are
not usually required, although they can be implemented through public
domain software.
- VMS files have version numbers. This provides you with a level
of safety against catastrophic modification of a file. UNIX doesn't give
you this protection.
- VMS compilers generally produce more highly optimized code that most UNIX
compilers. VMS is reknowned for the accuracy of its floating point transcendental
functions.
- VMS security and system management facilities are superior to those
provided by UNIX.
- UNIX has no equivalent to VMS's '136 T command. In most
cases this is not a problem since you can always use '136 Z to
suspend the job, bg to background it, and then ps -x to see
what it is up to.
- The UNIX philosophy it to do what the user asked, quietly, even if
this means deleting all the user's files. Quite often UNIX commands don't
do careful error checking and may not inform you that an operation succeeded
or failed, for example, the command lprm for removing jobs from the
print queue will not tell you that anything is wrong if you type lprm 671
when the job 671 doesn't exist. The VMS philosophy is to try and protect the
user to some extent, and to give very clear indication of what a command has
done and of the severity of errors.
When all is said and done, after using UNIX for a few months you will not
want to use VMS again.
The following table gives rough equivalences between VMS and UNIX commands.
Note: the commands mmv, hd, and less are local
additions.
UNIX and MS-DOS have much in common, primarily because MS-DOS was
partly developed using ideas from UNIX. Here are some of the major
differences:
- UNIX filenames are arbitrary strings of up to 255 characters,
MS-DOS filenames are limited to an 8 character file name and a 3
character file type, and have restrictions on allowable characters.
- UNIX doesn't require the notion of a disk drive modifier for
a file specification, i.e., you don't need A:, B:, C:, and so
on like MS-DOS. Note that MS-DOS has the JOIN command which can
simulate the UNIX file system.
- UNIX uses forward slashes (/) to separate directories in
a file specification, whereas MS-DOS uses backslashes ( ).
- UNIX is a full multiuser multitasking operating system, whereas MS-DOS
is a single-user OS without concepts like file-ownership and process
priorities.
- UNIX has a richer command set than MS-DOS.
- UNIX and MS-DOS both have the concept of a PATH.
- UNIX and MS-DOS both have pipes and I/O redirection.
- UNIX displays characters on your terminal as you type them, regardless
of whether the operating system is ready to accept a command. MS-DOS will
buffer, but not display, terminal input when it is busy executing the
previous command.
- MS-DOS programs generally have a nicer user interface than
traditional UNIX ones. This situation is changing with the emergence
of X-windows applications on UNIX.
The following table gives rough equivalences between UNIX and MS-DOS
commands. As you can see, there are many similarities. Note
particularly the UNIX mechanism for putting a directory name into the
prompt string (for more details, see man tcsh).
Next: About this document
Up: No Title
Previous: Running computationally intensive jobs
Michael C. B. Ashley
Fri Jun 28 13:34:23 EST 1996