Snapshot Mount

Definition

Trilio allows you to view or download a file from the snapshot. Any changes to the files or directories when snapshot is mounted are temporary and are discarded when the snapshot is unmounted. Mounting is a faster way to restore a single or multiple files. To mount a snapshot follow these steps.

Supported File Recovery Manager Image

Create a File Recovery Manager Instance

It is recommended to do these steps once to the chosen cloud-Image and then upload the modified cloud image to Glance.

  • Create an Openstack image using a Linux based cloud-image like Ubuntu, CentOS or RHEL with the following metadata parameters.

openstack image create \
--file <File Manager Image Path> \
--container-format bare \
--disk-format qcow2 \
--public \
--property hw_qemu_guest_agent=yes \
--property tvault_recovery_manager=yes \
--property hw_disk_bus=virtio \
tvault-file-manager
  • Spin up an instance from that image It is recommended to have at least 8GB RAM for the mount operation. Bigger Snapshots can require more RAM.

Steps to apply on CentOS and RHEL cloud-images

  • install and activate qemu-guest-agent

  • Edit /etc/sysconfig/qemu-ga and remove the following from BLACKLIST_RPC section

guest-file-read
guest-file-write
guest-file-open
guest-file-close
  • Disable SELINUX in /etc/sysconfig/selinux

SELINUX=disabled
  • Install python3 and lvm2

yum install python3 lvm2
  • Reboot the Instance

Steps to apply on Ubuntu cloud-images

  • install and activate qemu-guest-agent

apt-get update
apt-get install qemu-guest-agent
systemctl enable qemu-guest-agent
  • Verify the loaded path of qemu-guest-agent

Loaded path init.d (Ubuntu 18.04)

Follow this path when systemctl returns the following loaded path

Loaded: loaded (/etc/init.d/qemu-guest-agent; generated)

Edit /etc/init.d/qemu-guest-agent and add Freeze-Hook file path in daemon args

DAEMON_ARGS="-F/etc/qemu/fsfreeze-hook"

Loaded path systemd (Ubuntu 20.04)

Follow this path when systemctl returns the following loaded path

Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; disabled; vendor preset: enabled)

Edit qemu-guest-agent systemd file

systemctl edit qemu-guest-agent

Add the following lines

[Service]
ExecStart=
ExecStart=/usr/sbin/qemu-ga -F/etc/qemu/fsfreeze-hook

Finalize the FRM on Ubuntu

  • Restart qemu-guest-agent service

systemctl restart qemu-guest-agent
  • Install Python3

apt-get install python3
  • Reboot the VM

Mounting a Snapshot

Mounting a Snapshot to a File Recovery Manager provides read access to all data that is located on the in the mounted Snapshot.

It is possible to run the mounting process against any Openstack instance. During this process will the instance be rebooted.

Always mount Snapshots to File Recovery Manager instances only.

To be able to successfully mount Windows (NTFS) Snapshots the ntfs filesystem support is required on the File Recovery Manager instance.

Unmount any mounted Snapshot once there is no further need to keep it mounted. Mounted Snapshots will not be purged by the Retention policy.

Using Horizon

There are 2 possibilities to mount a Snapshot in Horizon.

Through the Snapshot list

To mount a Snapshot through the Snapshot list follow these steps:

  1. Login to Horizon

  2. Navigate to Backups

  3. Navigate to Workloads

  4. Identify the workload that contains the Snapshot to mount

  5. Click the workload name to enter the Workload overview

  6. Navigate to the Snapshots tab

  7. Identify the searched Snapshot in the Snapshot list

  8. Click the small arrow in the line of the Snapshot next to "One Click Restore" to open the submenu

  9. Click "Mount Snapshot"

  10. Choose the File Recovery Manager instance to mount to

  11. Confirm by clicking "Mount"

Should all instances of the project be listed and there is a File Recovery Manager instance existing verify together with the administrator that the File Recovery Manager image has the following property set:

tvault_recovery_manager=yes

Through the File Search results

To mount a Snapshot through the File Search results follow these steps:

  1. Login to Horizon

  2. Navigate to Backups

  3. Navigate to Workloads

  4. Identify the workload that contains the Snapshot to mount

  5. Click the workload name to enter the Workload overview

  6. Navigate to the File Search tab

  7. Identify the Snapshot to be mounted

  8. Click "Mount Snapshot" for the chosen Snapshot

  9. Choose the File Recovery Manager instance to mount to

  10. Confirm by clicking "Mount"

Should all instances of the project be listed and there is a File Recovery Manager instance existing verify together with the administrator that the File Recovery Manager image has the following property set:

tvault_recovery_manager=yes

Using CLI

workloadmgr snapshot-mount <snapshot_id> <mount_vm_id>

Accessing the File Recovery Manager

The File Recovery Manager is a normal Linux based Openstack instance.

It can be accessed via SSH or SSH based tools like FileZila or WinSCP.

SSH login is often disabled by default in cloud-images. Enable SSH login if necessary.

The mounted Snapshot can be found at the following path:

/home/ubuntu/tvault-mounts/mounts/

Each VM in the Snapshot has its own directory using the VM_ID as the identifier.

Identifying mounted Snapshots

Sometimes a Snapshot is mounted for a longer time and it needs to be identified, which Snapshots are mounted.

Using Horizon

There are 2 possibilities to identify mounted Snapshots inside Horizon.

From the File Recovery Manager instance Metadata

  1. Login to Horizon

  2. Navigate to Compute

  3. Navigate to Instances

  4. Identify the File Recovery Manager Instance

  5. Click on the Name of the File Recovery Manager Instance to bring up its details

  6. On the Overview tab look for Metadata

  7. Identify the value for mounted_snapshot_url

The mounted_snapshot_url contains the Snapshot ID of the Snapshot that has been mounted last.

This value only gets updated, when a new Snapshot is mounted.

From the Snapshot list

  1. Login to Horizon

  2. Navigate to Backups

  3. Navigate to Workloads

  4. Identify the workload that contains the Snapshot to mount

  5. Click the workload name to enter the Workload overview

  6. Navigate to the Snapshots tab

  7. Search for the Snapshot that has the option "Unmount Snapshot"

Using CLI

workloadmgr snapshot-mounted-list [--workloadid <workloadid>]

Unmounting a Snapshot

Once a mounted Snapshot is no longer needed it is possible and recommended to unmount the snapshot.

Unmounting a Snapshot frees the File Recovery Manager instance to mount the next Snapshot and allows Trilio retention policy to purge the former mounted Snapshot.

Deleting the File Recovery Manager instance will not update the Trilio appliance. The Snapshot will be considered mounted until an unmount command has been received.

Using Horizon

  1. Login to Horizon

  2. Navigate to Backups

  3. Navigate to Workloads

  4. Identify the workload that contains the Snapshot to mount

  5. Click the workload name to enter the Workload overview

  6. Navigate to the Snapshots tab

  7. Search for the Snapshot that has the option "Unmount Snapshot"

  8. Click "Unmount Snapshot"

Using the CLI

workloadmgr snapshot-dismount <snapshot_id>

Last updated