Unix commands are case-sensitive, and are usually lower-case only. The
following table contains common tasks and commands to carry out those tasks.
For more information on all the options available for each command, use the
man command. For example, man ls will show you a
manual page for the command ls.
The [filename] can refer to a complete or relative path as
well as a filename only. A complete pathname would look something like: /export/home/johnson/myfile.html.
A relative path would look something like: johnson/myfile.html
In addition, check out UNI's Unix Help Utility at http://www.uni.edu/unixhelp or contact the Computer Consulting Center.
| Desired Function | Command |
|---|---|
| Change your password | passwd |
| List files | ls |
| See who else is logged on | who |
| View the contents of a file | more
[filename] or cat [filename] |
| Print a file on the system printer | lp [filename] |
| Copy one file to another | cp
[source-file] [destination-file] |
| Change the name of a file or to move a file | mv [old-file]
[new-file] |
| Delete a file | rm [filename] |
| Create a new directory | mkdir [directoryname] |
| Delete a directory | rmdir
[directoryname] |
| Change your current directory | cd [directoryname] |
| Display current directory name | pwd |
| Send or Read e-mail | mailx
or elm
or pine |
| Exit the system | [Control-D]
or exit |
| Sort a file | sort [infile] >[outfile] |
| Edit a file | vi or
ee
or pico
or vim |
unixref