Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

header-navigation
keyboard_arrow_up
close
keyboard_arrow_left
Junos CLI Reference
Table of Contents Expand all
list Table of Contents
file_download PDF
{ "lLangCode": "en", "lName": "English", "lCountryCode": "us", "transcode": "en_US" }
English
keyboard_arrow_right

delete

date_range 19-Nov-23

Syntax

content_copy zoom_out_map
delete <statement-path> <identifier> 

Description

Delete a statement or identifier. All subordinate statements and identifiers contained within the specified statement path are deleted with it.

Deleting a statement or an identifier effectively “unconfigures” or disables the functionality associated with that statement or identifier.

If you do not specify statement-path or identifier, the entire hierarchy, starting at the current hierarchy level, is removed.

Note:

For Junos OS Evolved, if you use the delete configuration command at the top level of the configuration, you cannot commit the resulting empty configuration. At a minimum, the root authentication password is required.

Options

statement-path

(Optional) Path to an existing statement or identifier. Include this if the statement or identifier to be deleted is not at the current hierarchy level.

identifier

(Optional) Name of the statement or identifier to delete.

Required Privilege Level

configure—To enter configuration mode, but other required privilege levels depend on where the statement is located in the configuration hierarchy.

Sample Output

delete (Junos OS Evolved)

content_copy zoom_out_map
[edit]
user@host# delete  
This will delete the entire configuration
Delete everything under this level? [yes,no] (no) yes 

If you then try to commit the change, you get this:

content_copy zoom_out_map
user@host# commit  
error: cannot commit an empty configuration

Release Information

Command introduced before Junos OS Release 7.4.

footer-navigation