The snapshot pseudo-directory enable NFS clients access to the contents of filesystem snapshots. The snapshot directory allows the end-user to recover deleted or modified files autonomously with no admin assistance. Using snapshot directory, the end-user can run a backup from a static view of the filesystem, without mounting the snapshot.

This feature supports customers migrating from existing NAS solutions by allowing the admin to determine the way the snapshot directory is named.

Visibility and contents of the snapshot directory

  • The snapshot directory appears and is accessible as a regular folder. 
  • Its name is configurable upon creating the filesystem. The default name is .snapshot
  • Only RO snapshots that have never been writable can be visible and accessible on the snapshot directory
  • Visibility of the snapshot directory:
    • The visibility of snapshot directory is configurable per export
    • Snapshot directory that is not visible can still be accessible - by providing the specific path
    • Snapshots of snapshots are not accessible from the snapshot directory. They can be accessible if mounted to the first-level snapshots
  • The snapshot directory is accessible from any folder 
    • Replication snapshot are not visible on the snapshot directory


Prior InfiniBox software version did not impose any restrictions on the directory names. Potentially, a customer may have a directory whose name is .snapshot. In such a case, following an upgrade to a software version that supports snapshot directory, the existing folder will not be accessible. In such a case, the customer can disable the snapshot directory feature on the specific filesystem, rename the existing directory and enable the feature again.

Snapshot refresh

Whenever a snapshot is refreshed:

  • The snapshot is accessible to the user as was prior to the refresh operation
  • Files that existed in the pre-refreshed snapshot and whose content was refreshed will display the refreshed content to the user
  • Files that are added to the snapshot during the refresh operation are visible after the refresh operation is complete

The snapshot directory of a replicated filesystem

  • When replicating from an InfiniBox system with a software version that supports snapshot directory to an InfiniBox version with a software version that does not:
    • The will not be a snapshot directory on the target
    • Upon upgrading the target InfiniBox system to a software version that supports snapshot directory, the snapshot directory will be created automatically
  • When replicating from an InfiniBox system with a software version that does not support snapshot directory to an InfiniBox version with a software version that does:
    • A snapshot directory will be automatically created on the target

Viewing the I/O performance of snapshots via the snapshot directory

I/O on a snapshot accessed via the snapshot directory folder are counted as an access to the snapshot, not as an access the parent filesystem. This includes every aspect of the I/O "target": filesystem, export, TreeQ and file path.

Enabling the feature for an existing filesystem

Enabling the snapshot directory feature for a filesystem takes effect only after remounting the export

Recovering deleted files using the .Snapshot directory

The following displays an example of how to recover files from the .Snapshot directory folder without the assistance of an administrator:

Step 1. Use the "ls" command to see the files in the regular folder:

root@ubuntu-1:/mnt/fs-test-1# ls
file1.txt  file2.txt  file3.txt  file4.txt  file5.txt

Step 2. Delete a file, then re-display the files in the folder:

root@ubuntu-1:/mnt/fs-test-1# rm file3.txt
root@ubuntu-1:/mnt/fs-test-1# ls
file1.txt  file2.txt  file4.txt  file5.txt

Step 3. Move to the .Snapshot folder (the .Snapshot is named snap-fs-test-1), and display the files. It will contain all of the files in the snapshot:

root@ubuntu-1:/mnt/fs-test-1# cd .snapshot
root@ubuntu-1:/mnt/fs-test-1/.snapshot# cd snap-fs-test-1
root@ubuntu-1:/mnt/fs-test-1/.snapshot/snap-fs-test-1# ls
file1.txt  file2.txt  file3.txt  file4.txt  file5.txt

Step 4. Use the "cp" command to copy a file from the .Snapshot folder to the original location. Using the "cp" command allows you to rename the file if you desire. For the purposes of this example. the file was renamed file3restored.txt:

root@ubuntu-1:/mnt/fs-test-1/.snapshot/snap-fs-test-1# cp file3.txt /mnt/fs-test-1/file3restored.txt
root@ubuntu-1:/mnt/fs-test-1/.snapshot/snap-fs-test-1# cd ..
root@ubuntu-1:/mnt/fs-test-1/.snapshot# cd ..
root@ubuntu-1:/mnt/fs-test-1# ls
file1.txt  file2.txt  file3restored.txt  file4.txt  file5.txt
Was this article helpful?
0 out of 0 found this helpful

0 out of 0 found this helpful

Last edited: 2020-11-05 10:31:12 UTC