HowTos:Restore files from snapshots on Mac OS X from home directory on Math file server
From CompudocWiki
These directions describe how to restore recently deleted files or older copies of recently modified files located on the Math/PACM fileserver, e.g. in your home directory. These instructions do not apply if you are trying to restore files located on your own laptop or desktop.
Snapshot description
In order to restore files deleted or changed within last few days you can use snapshots, as long as the file you are looking for is located somewhere under your home directory. A snapshot is a read-only image of the entire file system (home directories) that reflects the state of the file system at the time the snapshot was created.
Currently, there are four daily and eleven hourly snapshots. Daily snapshots are created at midnight of every day and four of them are kept, e.g. if you are looking at snapshots at 3pm of Friday you will find daily snapshots created at midnight of previous Monday, Tuesday, Wednesday and Thursday - called, respectively, nightly.3, nightly.2, nightly.1 and nightly.0.
Hourly snapshots are created every two hours, except at midnight, and up to 11 are kept. Hourly snapshots are taken at 2am, 4am, 6am, 8am, 10am, 12pm, 2pm, 4pm, 6pm, 8pm and 10pm. E.g. if you are looking at hourly snapshots at 3pm of Friday you will find hourly snapshots from 2pm Friday, 12pm Friday, 10am Friday, 8am Friday, 6am Friday, 4am Friday, 2am Friday, 10pm Thursday, 8pm Thursday, 6pm Thursday and 4pm Thursday (called hourly.0, hourly.1, ..., hourly.10 respectively).
Note that your deleted or changed file will be in one of the snapshots only if it was on the file system at one of the times when snapshots were taken. E.g. if you create a file at 2:15pm but delete it at 3:40pm then you will not be able to find it and restore it from any of the snapshots (as they were created at 2pm and 4pm and file was not there at either of those times).
Restore file from snapshots on Mac OS X
We will assume that you are already familiar with how to connect via cifs/windows sharing to your home directory on Mac OS X. If you are not please first read appropriate instructions in HowTos instructions on how to connect with cifs/windows sharing to Math/PACM file server or follow Linux instructions for restoring files via snapshots instead of these.
In "Finder" select the "Go" menu (1) and then "Connect to Server" (2):
This will bring up the "Connect to Server" window where for the server address you should type "cifs://mathusername@fs.math.princeton.edu/mathusername/.snapshot" (1) and then click on "Connect" (2):
After entering your username and password you will be presented with a window showing all of the snapshots:
At this point you should start looking in various snapshots for the file you want to retrieve/restore. Each snapshot file (e.g. hourly.4) contains a full copy of your home directory as it existed at the time snapshot was mde. For example, if your file was deleted yesterday then you should check in nightly.1.
Once you have found your file you can copy and paste it to its original location or somewhere else.



