Unix Filesystem Basics - DirectoriesThe Unix filesystem is a hierarchical structure generally organized like a pyramid, as in the following example:
|
|||||||||
| Directories |
Each of the above headings is either a directory or a file. A directory
may contain files and/or more directories. The highest level of the
filesystem tree is called the root directory and is symbolized by
the slash " / ".
|
||||||||
| Current Directory |
To find out what directory you are currently located in type the
command pwd. The computer will display your absolute path.
You need pathnames to change directories, copy files, and add more files.
** Note: When executing the pwd command, users may notice an unusual prefix to their path. For example, from your home directory, the pwd command may output: /tmp_mnt/homes/sunserv1/stdt/joeuser The /tmp_mnt should be ignored. It is used as part of the NFS (Network File System) Automounter. When referencing files or directories, do not include the /tmp_mnt . |
||||||||
| Changing Directories |
To change directories, you type cd and the pathname of where
you are going. For example: To return to your home directory, type cd without any arguments. To insure that you are home, type pwd. You do not always have to use absolute pathnames to change directories. Some shortcuts are:
|
| For more information on UNIX Basics one can look at: |
|---|
|