Child pages
  • How-to: Restoring a deleted file or directory

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Expand
titleWindows

Windows Mapped Drive

Windows makes it easy to restore a file or directory from your $LAB or $HOME directory, as long as it is mapped to your computer. Remember, you need to be connected to the VPN to access a mapped directory from off campus.

  1. Navigate to the folder or directory file the Windows File Explorer
  2. Right-click on the file, and click restore previous versions
  3. Navigate to the version you would like to restore, and hit Restore

    Warning

    This will overwrite the existing file in the directory!

Expand
titleSSH terminal

SSH Terminal

Snapshots can be accessed and restored from an SSH terminal from any operating system. Please follow How-to: Connect via SSH (PuTTY, macOS terminal, X2Go) for more information on connecting via SSH.

  1. Open an SSH connection to head-01.arcc.albany.edu
  2. Using the "cd" command, change directories to the file or directory that needs to be restored

    Code Block
    languagebash
    cd /network/rit/lab/[lab_directory]/[]

    In this example, we will demonstrate with an example file
    Image Added

  3. Use the "ls" command to check if the file is in the directory, here we will restore spawn_jupyter.sh

    Image Added

  4. Now, "cd" into the ".snapshot" directory, and "ls" to see what snapshots are available. Note that the snapshots are additional directories.
    Image Added
  5. "cd" into the appropriate snapshot directory. Here we are restoring the backup from 0825 on 15 Apr 2019
    Image Added
  6. You can check the file with the "more" command, or other command of your choice
    Image Added
  7. Next, "cp" the file two directories up (../../) and rename it if you'd like to. Here, we append _restored so the files can be further compared
    Image Added
  8. Navigate out of the snapshot (cd ../../), to the original directory and verify the restored file is there
    Image Added