BASIC UNIX, DOS, AND VAX/VMS COMMANDS
A 'CHEAT SHEET'
In the following table, the first line of each entry gives a VMS
command, the second line gives the DOS equivalent, and the third
the UNIX equivalent.
=================================================================
VMS Command
DOS command
UNIX Equivalent Comments
=================================================================
DIR Listing of user's files (brief). For
DIR/W UNIX, ls -a is needed to show files
ls with a "dot" prefix (i.e., .fname).
-----------------------------------------------------------------
DIR/FULL Detailed listing of user's files.
DIR
ls -al
-----------------------------------------------------------------
COPY fname1 fname2 Copies file fname1 to fname2.
COPY fname1 fname2
cp fname1 fname2
-----------------------------------------------------------------
DEL fname.;1 Deletes the specified file.
DEL fname
rm fname
-----------------------------------------------------------------
RENAME fname1 fname2 Renames file fname1 to fname2 (also moves
RENAME fname1 fname2 file, if directory path is included).
mv fname1 fname2
-----------------------------------------------------------------
TYPE fname Displays file fname on the screen.
TYPE fname
cat fname
-----------------------------------------------------------------
TYPE/PAGE fname Displays file, 1 page at a time, with
(or LIST fname) prompting.
TYPE fname |more
more fname
-----------------------------------------------------------------
PRINT fname Prints file on Computing Services' line
PRINT fname printer. For DOS: prints file on local
lpr fname printer.
-----------------------------------------------------------------
SET PROT=O:RWED fname Change protection on a file. VAX:
ATTRIB +R fname O=owner; RWED = read, write, execute,
chmod u+rwx fname delete. For DOS the only protections are
+R (write enabled) and -R (write
disabled). Unix: u=user, +rwx = "on" for
read, write, and execute. Also can use -
for "off", e.g., go-x means "off" for
"group" and "other" i.e., everyone
else).
-----------------------------------------------------------------
SET DEFAULT [dir_name] Change directory to dir_name.
CD dir_name
cd dir_name
-----------------------------------------------------------------
SET DEFAULT SYS$LOGIN Change to root or login directory.
(or HOME)
CD \
cd
-----------------------------------------------------------------
SET DEFAULT [-] Change directories by moving up one
(or UP) level.
CD ..
cd ..
-----------------------------------------------------------------
DIRECTORY/CREATE [.dir_name]
(or MD dir_name)
MKDIR [dir_name] Create a subdirectory named dir_name.
mkdir [dir_name]
-----------------------------------------------------------------
DEL dir_name.;1 Remove (delete) the specified
(or RD dir_name) subdirectory.
RMDIR dir_name
rmdir dir_name
-----------------------------------------------------------------
HELP command_name Find out more about this command. (For
HELP command_name DOS, the HELP command was not available
man command_name in earlier versions.)
-----------------------------------------------------------------
SET PASSWORD Change your password.
[not applicable]
passwd
-----------------------------------------------------------------
CLS Clear the terminal screen.
CLS
clear
-----------------------------------------------------------------
SHOW TIME (or DATE) See date and time. (On DOS, TIME also
TIME (or DATE) allows user to set the clock.)
date
-----------------------------------------------------------------
SHOW QUOTA Find out available disk space quota.
CHKDSK d: (d: stands for drive name on DOS.)
quota -v