This article explains the difference between 'request vmhost snapshot recovery' and 'request system snapshot recovery' and how they work.
'request vmhost snapshot recovery'
'request system snapshot recovery'
For NG-RE:
NG-RE has two disk's in it: disk1 and disk2. Disk1 is Primary and disk 2 is backup.Boot disk = Primary == disk1Boot disk = Secondary == disk2The RE by default boots up in disk1.
request vmhost snapshot
Take a snapshot of the currently running and active file system partitions from the primary disk to the secondary disk to recover the secondary disk in case of failure. (i.e copies all the file's from primary disk to secondary disk,) deletes all the content of the secondary disk.Works only when RE is booted by in primary disk (disk1).
request vmhost snapshot recovery
Take a snapshot of the currently running and active file system partitions from the secondary disk to the primary disk. (i.e copies all the file's from secondary disk to primary disk,) deletes all the content of the primary disk.Works only when RE is booted by in secondary disk (disk2)
Example:
The snapshot is taken when RE is booted from the default disk (Primary disk):
labroot@mx2020-re0> request vmhost snapshot warning: Existing data on the target may be lostProceed ? [yes,no] (no) yes warning: Proceeding with vmhost snapshotCurrent root details, Device sda, Label: jrootp_P, Partition: sda3Snapshot admin context from current boot disk to target disk ...Proceeding with snapshot on secondary diskMounting device in preparation for snapshot...Cleaning up target disk for snapshot ...Creating snapshot on target disk from current boot disk ...Snapshot created on secondary disk.Software snapshot done
The 'request vmhost snapshot recovery' CLI fails to work as the RE is booted by in primary disk:
labroot@mx2020-re0> request vmhost snapshot recovery warning: Existing data on the target may be lostProceed ? [yes,no] (no) yes warning: Proceeding with vmhost snapshotCurrent root details, Device sda, Label: jrootp_P, Partition: sda3Already running from primary disk.Please try snapshot without recovery option!Snapshot aborted.
The below command displays that the snapshot is done to which disk and the time of snapshot:
"Secondary Disk" == disk2"Snapshot Time: Fri May 14 19:37:55 UTC 2021" = Time of snapshot
labroot@mx2020-re0> show vmhost snapshot UEFI Version: NGRE_v00.53.00.01Secondary Disk, Snapshot Time: Fri May 14 19:37:55 UTC 2021 Version: set pVMHost Version: 3.1198VMHost Root: vmhost-x86_64-16.1R6-20171026_0422_builderVMHost Core: vmhost-core-x86_64-16.1R6-20171026_0422_builderkernel: 3.10.79-ovp-rt74-WR6.0.0.20_preempt-rtJunos Disk: junos-install-x86-64-16.1R6-S3.1Version: set bVMHost Version: 3.1465VMHost Root: vmhost-x86_64-17.3R3-S8-20200319_0024_builderVMHost Core: vmhost-core-x86_64-17.3R3-S11-20210118_2225_builderkernel: 3.10.100-ovp-rt110-WR6.0.0.31_preempt-rtJunos Disk: junos-install-mx-x86-64-17.3R3-S11.4
For non NG-RE
request system snapshot recovery
Create a recovery snapshot and store it in the /oam volume.A recovery snapshot stored in OAM (Operations, Administration, and Maintenance) volume holds a full backup that can be used in case something goes wrong with Junos volume. (i.e stored in the flash disk)
request system snapshot
A non-recovery snapshot is stored in Junos OS volume used for running the device software and hold the configuration and the logs.
labroot@mx240-re0> request system snapshot NOTICE: Snapshot snap.20210514.195000 created successfully labroot@jtac-mx240-r2008-re0> request system snapshot recovery Creating image ... Compressing image ... Image size is 2998MB ln: ../manifest: No such file or directory ln: ../manifest.e*: No such file or directory Recovery snapshot created successfully
21-12-24: Added links to description of "request vmhost snapshot" and "request system snapshot" commands.