TechLibrary

Navigation Back up to About Overview

request system snapshot

List of Syntax

Syntax
Syntax (ACX Series Routers)
Syntax (EX Series Switches)
Syntax (MX Series Routers)
Syntax (TX Matrix Routers)
Syntax (TX Matrix Plus Routers)

Syntax

request system snapshot <partition>

Syntax (ACX Series Routers)

request system snapshot <media type><partition>

Syntax (EX Series Switches)

request system snapshot<all-members | local | member member-id><media type><partition><re0 | re1 | routing-engine routing-engine-id><slice alternate>

Syntax (MX Series Routers)

request system snapshot <all-members><config-partition><local><member member-id><media usb-port-number><partition><root-partition>

Syntax (TX Matrix Routers)

request system snapshot <all-chassis | all-lcc | lcc number | scc> <config-partition><partition><root-partition>

Syntax (TX Matrix Plus Routers)

request system snapshot <all-chassis | all-lcc | lcc number | sfc number> <config-partition><partition><root-partition>

Release Information

Command introduced before Junos OS Release 7.4.

Command introduced in Junos OS Release 10.0 for EX Series switches.

Command introduced in Junos OS Release 12.2 for ACX Series switches.

Options <config-partition> and <root-partition> introduced in Junos OS Release 13.1 for M, MX, T, TX Series switches.

Option media usb-port-number introduced in Junos OS Release 13.2 for MX104 routers.

Description

  • On the router, back up the currently running and active file system partitions to standby partitions that are not running. Specifically, the root file system (/) is backed up to /altroot, and /config is backed up to /altconfig. The root and /config file systems are on the router's flash drive, and the /altroot and /altconfig file systems are on the router's hard drive.
  • On the switch, take a snapshot of the files currently used to run the switch—the complete contents of the root (/) , /altroot, /config, /var, and /var-tmp directories, which include the running Junos OS, the active configuration, and log files.

Caution: After you run the request system snapshot command, you cannot return to the previous version of the software, because the running and backup copies of the software are identical.

Options

The specific options available depend upon the router or switch:

none

Back up the currently running software as follows:

  • On the router, back up the currently running and active file system partitions to standby partitions that are not running. Specifically, the root file system (/) is backed up to /altroot, and /config is backed up to /altconfig. The root and /config file systems are on the router's flash drive, and the /altroot and /altconfig file systems are on the router's hard drive.
  • On the switch, take a snapshot of the files currently used to run the switch and copy them to the media that the switch did not boot from. If the switch is booted from internal media, the snapshot is copied to external (USB) media. If the switch is booted from external (USB) media, the snapshot is copied to internal media.
    • If the snapshot destination is external media but a USB flash drive is not connected, an error message is displayed.
    • If the automatic snapshot procedure is already in progress, the command returns the following error: Snapshot already in progress. Cannot start manual snapshot. For additional information about the automatic snapshot feature, see Understanding Resilient Dual-Root Partitions on Switches.
all-chassis | all-lcc | lcc number

(TX Matrix and TX Matrix Plus router only) (Optional)

  • all-chassis—On a TX Matrix router, archive data and executable areas for all Routing Engines in the chassis. On a TX Matrix Plus router, archive data and executable areas for all Routing Engines in the chassis.
  • all-lcc—On a TX Matrix router, archive data and executable areas for all T640 routers (or line-card chassis) connected to a TX Matrix router. On a TX Matrix Plus router, archive data and executable areas for all routers (or line-card chassis) connected to a TX Matrix Plus router.
  • lcc number—On a TX Matrix router, archive data and executable areas for a specific T640 router (or line-card chassis) that is connected to a TX Matrix router. On a TX Matrix Plus router, archive data and executable areas for a specific router (line-card chassis) that is connected to a TX Matrix Plus router.

    Replace number with the following values depending on the LCC configuration:

    • 0 through 3, when T640 routers are connected to a TX Matrix router in a routing matrix.
    • 0 through 3, when T1600 routers are connected to a TX Matrix Plus router in a routing matrix.
    • 0 through 7, when T1600 routers are connected to a TX Matrix Plus router with 3D SIBs in a routing matrix.
    • 0, 2, 4, or 6, when T4000 routers are connected to a TX Matrix Plus router with 3D SIBs in a routing matrix.
all-members | local | member member-id

(EX Series switch Virtual Chassis and MX Series routers only) (Optional) Specify where to place the snapshot (archive data and executable areas) in a Virtual Chassis:

  • all-members—Create a snapshot (archive data and executable areas) for all members of the Virtual Chassis.
  • local—Create a snapshot (archive data and executable areas) on the member of the Virtual Chassis that you are currently logged into.
  • member member-id—Create a snapshot (archive data and executable areas) for the specified member of the Virtual Chassis.
config-partition

(M, MX, T, TX Series routers only) Create a snapshot of the configuration partition only and store it onto the default /altconfig on the hard disk device or an /altconfig on a USB device.

media type

(ACX Series, M320, T640, MX960 routers, and EX Series switches only)(Optional) Specify the boot device the software is copied to:

  • compact-flash—Copy software to the primary compact flash drive.
  • external—(Switches only) Copy software to an external mass storage device, such as a USB flash drive. If a USB drive is not connected, the switch displays an error message.
  • internal—Copy software to an internal flash drive.
  • removable-compact-flash—Copy software to the removable compact flash drive.
  • usb—(ACX Series, M320, T640, MX960 routers only) Copy software to the device connected to the USB port.
  • usb0—(MX104 routers only) Copy software to the device connected to the USB0 port.
  • usb1—(MX104 routers only) Copy software to the device connected to the USB1 port.
partition

(Optional) Repartition the flash drive before a snapshot occurs. If the partition table on the flash drive is corrupted, the request system snapshot command fails and reports errors. The partition option is only supported for restoring the software image from the hard drive to the flash drive.

(Routers only) You cannot issue the request system snapshot command when you enable flash disk mirroring. We recommend that you disable flash disk mirroring when you upgrade or downgrade the software. For more information, see the Junos OS Administration Library for Routing Devices.

(EX Series switches only) If the snapshot destination is the media that the switch did not boot from, you must use the partition option.

re0 | re1 | routing-engine routing-engine-id

(EX6200 and EX8200 switches only) Specify where to place the snapshot in a redundant Routing Engine configuration.

  • re0—Create a snapshot on Routing Engine 0.
  • re1—Create a snapshot on Routing Engine 1.
  • routing-engine routing-engine-id—Create a snapshot on the specified Routing Engine.
root-partition

(M, MX, T, TX Series routers only) Create a snapshot of the root partition only and store it onto the default /altroot on the hard disk device or an /altroot on a USB device.

slice alternate

(EX Series switches only) (Optional) Take a snapshot of the active root partition and copy it to the alternate slice on the boot media.

scc

(TX Matrix router only) (Optional) Archive data and executable areas for a TX Matrix router (or switch-card chassis).

sfc number

(TX Matrix Plus router only) (Optional) Archive data and executable areas for a TX Matrix Plus router (or switch-fabric chassis). Replace number with 0.

Additional Information

  • (Routers only) Before upgrading the software on the router, when you have a known stable system, issue the request system snapshot command to back up the software, including the configuration, to the /altroot and /altconfig file systems. After you have upgraded the software on the router and are satisfied that the new packages are successfully installed and running, issue the request system snapshot command again to back up the new software to the /altroot and /altconfig file systems.
  • (Routers only) You cannot issue the request system snapshot command when you enable flash disk mirroring. We recommend that you disable flash disk mirroring when you upgrade or downgrade the software. For more information, see the Junos OS Administration Library for Routing Devices
  • (TX Matrix and TX Matrix Plus router only) On a routing matrix, if you issue the request system snapshot command on the master Routing Engine, all the master Routing Engines connected to the routing matrix are backed up. If you issue this command on the backup Routing Engine, all the backup Routing Engines connected to the routing matrix are backed up.

Required Privilege Level

maintenance

List of Sample Output

request system snapshot (Routers)
request system snapshot (EX Series Switches)
request system snapshot (When the Partition Flag Is On)
request system snapshot (MX104 routers when media device is missing)
request system snapshot (When Mirroring Is Enabled)
request system snapshot all-lcc (Routing Matrix)
request system snapshot all-members (Virtual Chassis)

Output Fields

When you enter this command, you are provided feedback on the status of your request.

Sample Output

request system snapshot (Routers)

user@host> request system snapshot
umount: /altroot: not currently mounted
Copying / to /altroot.. (this may take a few minutes)
umount: /altconfig: not currently mounted
Copying /config to /altconfig.. (this may take a few minutes)

The following filesystems were archived: / /config

request system snapshot (EX Series Switches)

user@switch> request system snapshot partition
Clearing current label...
Partitioning external media (/dev/da1) ...
Partitions on snapshot:

  Partition  Mountpoint  Size    Snapshot argument
      s1a    /altroot    179M    none
      s2a    /           180M    none
      s3d    /var/tmp    361M    none
      s3e    /var        121M    none
      s4d    /config     60M     none
Copying '/dev/da0s1a' to '/dev/da1s1a' .. (this may take a few minutes)
Copying '/dev/da0s2a' to '/dev/da1s2a' .. (this may take a few minutes)
Copying '/dev/da0s3d' to '/dev/da1s3d' .. (this may take a few minutes)
Copying '/dev/da0s3e' to '/dev/da1s3e' .. (this may take a few minutes)
Copying '/dev/da0s4d' to '/dev/da1s4d' .. (this may take a few minutes)
The following filesystems were archived: /altroot / /var/tmp /var /config

request system snapshot (When the Partition Flag Is On)

user@host> request system snapshot partition
Performing preliminary partition checks ...
Partitioning ad0 ...
umount: /altroot: not currently mounted
Copying / to /altroot.. (this may take a few minutes)

The following filesystems were archived: / /config

request system snapshot (MX104 routers when media device is missing)

user@host > request system snapshot media usb0
error: usb0 media missing or invalid

request system snapshot (When Mirroring Is Enabled)

user@host> request system snapshot
Snapshot is not possible since mirror-flash-on-disk is configured.

request system snapshot all-lcc (Routing Matrix)

user@host> request system snapshot all-lcc
lcc0-re0:
--------------------------------------------------------------------------
Copying '/' to '/altroot' .. (this may take a few minutes)
Copying '/config' to '/altconfig' .. (this may take a few minutes)
The following filesystems were archived: / /config

lcc2-re0:
--------------------------------------------------------------------------
Copying '/' to '/altroot' .. (this may take a few minutes)
Copying '/config' to '/altconfig' .. (this may take a few minutes)
The following filesystems were archived: / /config

request system snapshot all-members (Virtual Chassis)

user@switch> request system snapshot all-members media internal

fpc0: -------------------------------------------------------------------------- Copying '/dev/da0s2a' to '/dev/da0s1a' .. (this may take a few minutes) The following filesystems were archived: / fpc1: -------------------------------------------------------------------------- Copying '/dev/da0s2a' to '/dev/da0s1a' .. (this may take a few minutes) The following filesystems were archived: / fpc2: -------------------------------------------------------------------------- Copying '/dev/da0s2a' to '/dev/da0s1a' .. (this may take a few minutes) The following filesystems were archived: / fpc3: -------------------------------------------------------------------------- Copying '/dev/da0s2a' to '/dev/da0s1a' .. (this may take a few minutes) The following filesystems were archived: / fpc4: -------------------------------------------------------------------------- Copying '/dev/da0s2a' to '/dev/da0s1a' .. (this may take a few minutes) The following filesystems were archived: / fpc5: -------------------------------------------------------------------------- Copying '/dev/da0s2a' to '/dev/da0s1a' .. (this may take a few minutes) The following filesystems were archived: /

Published: 2014-10-13