Carnegie Mellon University Website Home Page
 

Your Home Directory and Pathnames

Andrew is based on the UNIX operating system. You have a personal directory in the Andrew system, known as your home directory (your user ID is the name of your home directory). Your home directory is a part of the file system, and it contains subdirectories and files (some created by system administrators, plus any you create yourself). Whenever you perform such actions as copying a file, renaming a file, removing a file, changing to another directory, or listing your files, you are using UNIX commands.

Whenever you log into Andrew you automatically enter your home directory. This directory was created by the Andrew system administrators and contains a number of default (or automatically present) subdirectories and files. They are:

  • OldFiles
  • private
  • public

Pathnames

A path name (also called simply path) is like the address of a file or directory. No two files or directories have the same path. A pathname is a chain of directory names, starting at the root and proceeding down the tree until it stops at a particular file or directory. Each directory name is separated by a slash (/).

Example 1
An example pathname would be:

/afs/andrew.cmu.edu/usr11/juse

Working backwards, we see that this pathname refers to the home directory of a user whose ID is "juser." Joe's home directory is a subdirectory of "usr11," which is one of 24 user directories on Andrew to which each user is randomly assigned.

The user directories are all subdirectories of andrew.cmu.edu, which is a directory of all Andrew accounts at Carnegie Mellon University (the .edu indicates to outside users that CMU is an educational institution).

"AFS" is the name of the distributed file system used at Carnegie Mellon, which includes other universities and sites as well.

The slash (/) at the very beginning of the pathname stands for root, the top level directory.

Example 2
The full name of the file notes.1 in user Joe's history subdirectory, would be:

/afs/andrew.cmu.edu/usr11/juser/history/notes.

If you wish to access a file in a subdirectory of your working directory you can simply type the subdirectory and file name. Because of the way the Andrew system and user accounts are set up, Andrew can still recognize this as the full pathname.

Example
The path name to a file called notes.1 in your history subdirectory, from your home directory would be:

history/notes.1

Last Updated: 8/24/07