Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 

request system storage cleanup

 

List of Syntax

Syntax

Syntax (EX Series Switches)

Syntax (MX Series Router)

Syntax (QFX Series)

Syntax (SRX Series)

Syntax (Junos OS Evolved)

Syntax

Syntax (EX Series Switches)

Syntax (MX Series Router)

Syntax (QFX Series)

Syntax (SRX Series)

Syntax (Junos OS Evolved)

Release Information

Command introduced in Junos OS Release 7.4.

dry-run option introduced in Junos OS Release 7.6.

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

Command introduced in Junos OS Release 9.2 for SRX Series.

Command introduced in Junos OS Release 11.1 for the QFX Series.

Command introduced in Junos OS Release 14.1X53-D20 for the OCX Series.

satellite option introduced in Junos OS Release 14.2R3.

no-confirm and (re0 |re1 | routing-engine (backup | both | local | master | other)) options introduced in Junos OS 17.3R1.

Description

Free storage space on the router or switch by rotating log files and proposing a list of files for deletion. User input is required for file deletion. On a QFabric system, you can delete debug files located on individual devices or on the entire QFabric system.

The Junos OS Evolved implementation of the request system storage cleanup command is slightly different from the implementation on Junos OS:

  • The user is prompted to specify the dry-run option:

    The command cleans up any ISO files on the system, rotates syslogs, and clears trace files. It does not remove user-created files.

  • In Junos OS Evolved, the system computes the available space and emits o/p on console for reference.

  • When request system storage cleanup is executed, Junos OS Evolved displays the types of files that are being deleted. See the Sample Output section below for an example.

Note

The request system storage cleanup | display xml rpc command displays different XML tags for different file types. In Junos OS, only the file tag is displayed for all types of files. For more information about the differences between Junos OS and Junos OS Evolved, see How the CLI in Junos OS Evolved Differs from Junos OS.

Options

all-members(EX4200 switches and MX Series routers only) (Optional) Delete files on the Virtual Chassis master Routing Engine only.
Note

To delete files on the other members of the Virtual Chassis configuration, log in to each backup Routing Engine and delete the files using the request system storage cleanup local command.

component (UUID | serial number | all)(QFabric systems only) (Optional) Delete files located on individual QFabric system devices or on the entire QFabric system.
director-group name(QFabric systems only) (Optional) Delete files on the Director group.
dry-run(Optional) List files proposed for deletion (without deleting them).
infrastructure name(QFabric systems only) (Optional) Delete files on the fabric control Routing Engine and fabric manager Routing Engine.
interconnect-device name(QFabric systems only) Optional) Delete files on the Interconnect device.
local(EX4200 switches and MX Series routers only) (Optional) Delete files on the local Virtual Chassis member.
member member-id(EX4200 switches and MX Series routers only) (Optional) Delete files on the specified member of the Virtual Chassis configuration. For EX4200 switches, replace member-id with a value from 0 through 9. For an MX Series Virtual Chassis, replace member-id with a value of 0 or 1.
name-tag name-tag(QFabric systems only) (Optional) Delete debug files that match a specific regular expression.
node-group name(QFabric systems only) (Optional) Delete files on the Node group.
no-confirm(Optional) Do not ask for confirmation before doing the cleanup.
prune(QFabric systems only) (Optional) Delete debug files located in either the core or log debug repositories of a QFabric system device.
qfabric component name(QFabric systems only) (Optional) Delete debug files located in the debug repositories of a QFabric system device.
(re0 | re1 | routing-engine (backup | both | local | master | other))(Optional) Request operation on system storage on RE0, RE1, or on specified Routing Engine by these classifications: backup, both, local, master, or other.

When Routing Engine is specified, the below message is shown before listing the files and deleting them.

repository (core | log)(QFabric systems only) (Optional) Specify the repository on the QFabric system device for which you want to delete debug files.
satellite [slot-id slot-id | device-alias alias-name](Junos Fusion only) (Optional) Specify the satellite device in the Junos Fusion by FPC ID or device alias name for which you want to delete debug files.

Additional Information

If logging is configured and being used, the dry-run option rotates the log files. In that case, the output displays the message “Currently rotating log files, please wait.” If no logging is currently under way, the output displays only a list of files to delete.

Required Privilege Level

maintenance

List of Sample Output

request system storage cleanup dry-run

request system storage cleanup

request system storage cleanup (Junos OS Evolved)

request system storage cleanup dry-run (Junos OS Evolved)

request system storage cleanup force-deep (Junos OS Evolved)

request system storage cleanup director-group (QFabric Systems)

request system storage cleanup infrastructure device-name (QFabric Systems)

request system storage cleanup interconnect-device device-name (QFabric Systems)

request system storage cleanup node-group group-name (QFabric Systems)

request system storage cleanup qfabric component device-name (QFabric Systems)

request system storage cleanup qfabric component device-name repository core (QFabric Systems)

request system storage cleanup qfabric component all (QFabric Systems)

Output Fields

Table 1 describes the output fields for the request system storage cleanup command. Output fields are listed in the approximate order in which they appear.

Table 1: request system storage cleanup Output Fields

Field Name

Field Description

List of files to delete:

Shows list of files available for deletion.

Size

Size of the core-dump file.

Date

Last core-dump file modification date and time.

Name

Name of the core-dump file.

Directory to delete:

Shows list of directories available for deletion.

Repository scope:

Repository where core-dump files and log files are stored. The core-dump files are located in the core repository, and the log files are located in the log repository. The default Repository scope is shared since both the core and log repositories are shared by all of the QFabric system devices.

Repository head:

Name of the top-level repository location.

Repository name:

Name of the repository: core or log.

Creating list of debug artifacts to be removed under:

Shows location of files available for deletion.

List of debug artifacts to be removed under:

Shows list of files available for deletion.

Sample Output

request system storage cleanup dry-run

user@host> request system storage cleanup dry-run

request system storage cleanup

user@host> request system storage cleanup

request system storage cleanup (Junos OS Evolved)

user@host> request system storage cleanup

request system storage cleanup dry-run (Junos OS Evolved)

user@host> request system storage cleanup dry-run

request system storage cleanup force-deep (Junos OS Evolved)

user@host> request system storage cleanup force-deep

request system storage cleanup director-group (QFabric Systems)

user@switch> request system storage cleanup director-group

request system storage cleanup infrastructure device-name (QFabric Systems)

user@switch> request system storage cleanup infrastructure FC

request system storage cleanup interconnect-device device-name (QFabric Systems)

user@switch> request system storage cleanup interconnect IC

request system storage cleanup node-group group-name (QFabric Systems)

user@switch> request system storage cleanup node-group NW-NG

request system storage cleanup qfabric component device-name (QFabric Systems)

user@switch> request system storage cleanup qfabric component Test

request system storage cleanup qfabric component device-name repository core (QFabric Systems)

user@switch> request system storage cleanup qfabric component Test repository core

request system storage cleanup qfabric component all (QFabric Systems)

user@switch> request system storage cleanup qfabric component all