Recover accidentally deleted files UPDATE: Snapshots have been indefinitely disabled. The directions below will not work.Last updated: October 11, 2024/projectsIn some cases it is possible to recover files that have been removed from /projects. If you log in to Tigressdata (ssh <YourNetID>@tigressdata.princeton.edu) you will find a directory mounted called /backups. Try looking for your files in /backups/projects. This directory contains a snapshot of your files at the time of the most recent backup. You may be able to find previous snapshots in a hidden .snapshots directory, for example:$ ssh [email protected] [ceisgrub@tigressdata2 ~]$ cd /tigress/projects/c/ceisgrub [ceisgrub@tigressdata2 ceisgrub]$ ls file1.txt file2.txt file3.txt [ceisgrub@tigressdata2 ceisgrub]$ cd .snapshots [ceisgrub@tigressdata2 .snapshots]$ ls SNAP-2020.01.11-00.36.15 SNAP-2020.01.25-03.33.52 SNAP-2020.02.01-02.29.24 SNAP-2020.02.05-19.27.38 SNAP-2020.02.13-22.40.15 [ceisgrub@tigressdata2 .snapshots]$ cd SNAP-2020.02.05-19.27.38/ [ceisgrub@tigressdata2 SNAP-2020.02.05-19.27.38]$ ls file1.txt file2.txt file3.txt file4.txt [ceisgrub@tigressdata2 SNAP-2020.02.05-19.27.38]$ pwd /backups/tigress/c/ceisgrub/.snapshots/SNAP-2020.02.05-19.27.38 [ceisgrub@tigressdata2 SNAP-2020.02.05-19.27.38]$ cp file4.txt /tigress/ceisgrubNote that the date in the .snapshot directory names is when the snapshot was taken. In the example above the user was able to find an accidentally deleted file and copy it to /tigress./homeIt may be possible to recover files that were removed from /home/YourNetID. This must be done by someone in Research Computing. Please send an email to [email protected] and be sure to include the cluster name (e.g., Della, Tiger) and the path to the files (e.g., /home/aturing/project1/data)./scratch/gpfs, /scratch/network, /scratch and /tmpIn general, files on a /scratch or /tmp filesystem at any institution are never backed up. Princeton happens to provide some backups for /scratch/gpfs for Della, Stellar and Traverse but not for any other clusters. To see the available snapshots, run the commands below:$ cd /scratch/gpfs/.snapshots $ ls -l total 4 drwxr-xr-x. 2300 root root 4096 Jan 20 13:33 snap-2023.01.23-09.00.01 drwxr-xr-x. 2304 root root 4096 Jan 24 08:35 snap-2023.01.24-09.00.01 drwxr-xr-x. 2305 root root 4096 Jan 24 19:30 snap-2023.01.25-09.00.01 drwxr-xr-x. 2310 root root 4096 Jan 26 07:13 snap-2023.01.26-09.00.01 drwxr-xr-x. 2310 root root 4096 Jan 26 07:13 snap-2023.01.27-09.00.01 drwxr-xr-x. 2312 root root 4096 Jan 27 14:11 snap-2023.01.28-09.00.01 drwxr-xr-x. 2312 root root 4096 Jan 27 14:11 snap-2023.01.29-09.00.01 drwxr-xr-x. 2312 root root 4096 Jan 27 14:11 snap-2023.01.30-09.00.01 Choose the nearest date and then "cd" into your directory:$ cd snap-2023.01.30-09.00.01 $ cd <YourNetID> $ ls -lYou can then copy files to your /scratch/gpfs/<YourNetID> directory using the "cp" command.Once again, you should never expect a filesystem that begin with /scratch or /tmp to provide backups. As always, be sure to copy or move your important, non-volatile results to /tigress or /projects for long-term storage and backup.