Carnegie Mellon University

How to Use AFS

AFS Directory Access Rights [pdf]

Common UNIX Commands [pdf]

From an FTP Client

A read-only backup is made nightly, 6pm - 4am, of your AFS  content to the OldFiles directory. If you are accessing these files via an FTP client from your own machine, complete the following steps to recover a file:
  1. Launch an SFTP program. Use the appropriate link below to download the software, if not installed.
  2. Enter linux.andrew.cmu.edu for the server/hostname.
  3. Go to the OldFiles directory.
  4. Transfer your files from remote to local.

From a Computer Lab

Computer labs do not have FTP clients installed on the machines, which means you'll need to restore files through terminal (Mac) or via command line (Windows).

  1. Enter linux.andrew.cmu.edu for the server/hostname.
  2. Enter fs mkm OldFiles user.andrewID.backup to mount the OldFiles directory.
  3. Enter cp -avr source-file|directory target-file|directory top copy files from the remote server to your local drive.

Note: Entering the following will allow you to copy an entire directory: 
 /afs/andrew/usr/userID/Oldfiles/foldername/foldername/foldername  /afs/andrew/usr/userid/foldername/folder 

From an FTP Client

If you are accessing these files via an FTP client from your own machine, complete the following steps to transfer a file:
  1. Launch the SFTP program. Use the appropriate link below to download the software, if not installed.
  2. Enter linux.andrew.cmu.edu for the server/hostname.
  3. Transfer your files from local to remote in the appropriate directory.
    • My Documents, Desktop - files saved in a computer lab
    • Private - files you don't want to share
    • Public - shared files 
    • www - for personal web pages

From an FTP Client

If you deplete or almost deplete your AFS quota, you may have difficulty saving files or logging on to a computer in a computer lab. To resolve this problem and recover storage space, delete AFS files.

  1. Access your AFS directory by logging in with your Andrew userID and password, then authenticate with DUO:
    1. Mac or Linux: Open Terminal and type:
      ssh <Your Andrew userID>@linux.andrew.cmu.edu
    2. PC (Windows): Connect to SSH Tectia or PuTTY.
  2. Type:
    du -hs .[^.]* * |sort -h
    Note: This command displays a list of all files in your AFS directory, including hidden files, folders, and mountpoints/volumes. The list is organized by disk usage from least to greatest. 
  3. Ignore “OldFiles.

    Note: “OldFiles” is a read-only copy of your AFS home directory nightly backup. They do not count towards your quota, so you do not have to delete them.
  4. Identify the largest directories.
  5. Zip or delete files from these directories to recover storage space.

    Note: Consider moving the files to Box or Google Drive instead of deleting them.
  6. To delete all files in a folder, type:
    rm -f -r ./foldername/*
    Note: Repeat the command, inserting the name of each folder you want to delete, until your quota is reduced to the size you want.
  7. Check your Desktop, Downloads, and Documents directories to see if you can archive any of those files. You can also delete folders in the /Library directory.

    Note: This step will remove any preference settings you have on some applications.
  8. The following hidden directories may also pull from your storage quota. You may clear or delete them to  recover space:
    1. .Trash
    2. .ccache
    3. .cache
  9. If needed, review commonly used Unix Commands.