Effective Saturday, March 14, OSU will move to a higher level of response that continues the essential operations of the university, but seeks to reduce the frequency of interactions among students, faculty, staff and visitors throughout all university campuses, centers, facilities and operations. Our focus is on continued university operations and social distancing.
File systems on ENGR home directories (Z drive) and research file servers such as "depot" or "farm" allow users to restore previous versions of files and directories from snapshots taken on the hour. This is very useful when a file may become corrupt, or something is accidentally deleted, as you can quickly restore yourself.
If you aren't comfortable with UNIX, Citrix offers a windows environment that can be used to restore snapshots even if you don't own a windows machine.
A basic understanding of UNIX commands is needed here. If commands such as ls, cd, cp, etc. are foreign to you,
read through a Linux primer online, or get help from a friend.
From a terminal window, ssh to access.engr.oregonstate.edu and login with your ENGR account.
Choose your terminal emulation (xterm will usually do the trick):
Snapshots are enabled in both home directories on stak and on research file servers such as depot.
Every directory on stak and depot has a .snapshot directory. It is hidden, so once in the directory you are looking to restore, simply change directory (cd) to .snapshot
As an example you might cd ~/Windows.Documents/Desktop/.snapshot to see the snapshots of the directory ~/Windows.Documents/Desktop
~ is a shortcut to your home directory on stak.
Or for files on other file servers, use nfs to browse (cd /nfs/depot/xxx/xxx.../.snapshot).
In this example, the file I wish to restore is in depot/cce_u1/montagne:
Using ls, list the directory contents to see all the snapshots (hourly and daily snapshots are shown as directories).
Change directories to the snapshot you wish to recover from with another cd command:
List the contents and using ls and you will see the files in the directory from that snapshot: Use cp to copy the file. In this example I am copying previous version of Visionapp.vrb back to my home directory and renaming it Visionapp.vrb.new.
From the Windows operating system, right click the directory or file you wish to restore and select "Properties":
Next select the file or directory you wish to recover and select COPY or RESTORE. You may see several versions in the list depending on how many times there have been changes. When doing a RESTORE, it would be prudent to rename the existing file, or just use COPY to be safe:
A restore WILL overwrite the version you have, so be careful:
Restoring a directory, especially a shared directory, can be tricky. You may not "own" all the files in the directory. Emailing support and ask us to restore for large directory trees would be best.
Also, when doing copies, be cognizant of your quota. It can be easy to exceed your space limitations restoring copies of things, especially large directories. Again, ask support if you aren't sure if you have the space to do a copy.