Nokia 7750 Service Router 7950 Extensible Routing System
MD-CLI Quick Reference Guide
Document Number: 3HE 15218 0000 TQZZA 01
Issue: 01
February 2019
1 MD-CLI Overview
This guide provides a comparison of the Nokia SR OS Model-Driven Command Line Interface (MD-CLI) to those used by Junos OS and IOS XR.
For more information about the MD-CLI, see the following resources:
- SR OS Release Notes for your current release
- MD-CLI User Guide
- MD-CLI Command Reference Guide
- MD-CLI introductory videos: https://www.youtube.com/playlist?list=PLgKNvl454BxcgfUQGMAEGE4yiV8c-ZDLu
Table 1 describes command syntax symbols used in this guide.
Symbol | Description |
---|---|
| | A vertical bar represents an OR, indicating that only one of the parameters in the brackets or parentheses can be selected. |
() | Parentheses indicate that one of the parameters must be selected. |
[] | Brackets indicate optional parameters. |
Bold | Commands in bold indicate commands and keywords. |
Italics | Commands in italics indicate that you must enter text based on the parameter. |
In the following examples, location
and graceful-shutdown
are command names. For the location
command, keyword
must be one of the keywords cf1
, cf2
, or cf3
. For the graceful-shutdown
command, boolean
must be one of the keywords true
or false
, although explicitly using the keyword true
is optional.
location keyword
keyword (cf1 | cf2 | cf3)
graceful-shutdown boolean
boolean ([true] | false)
1.1 Enabling the SR OS MD-CLI
Perform the following procedure to enable the MD-CLI from the classic CLI.
- Back up your configuration. Any existing configuration will be converted to the MD-CLI format.
- Enable the MD-CLI and model-driven mode, using these commands in this order:
configure system management-interface cli md-cli auto-config-save configure system management-interface configuration-mode model-driven
- Log out of the CLI.
- Log back in to the CLI. The MD-CLI engine is now active.
1.2 Disabling the SR OS MD-CLI
Perform the following procedure to return to classic CLI mode while preserving the current router configuration.
- Disable the MD-CLI and model-driven mode in the MD-CLI, using these commands in this order:
configure exclusive system management-interface configuration-mode classic commit
- Log out of the CLI.
- Log back in to the CLI. The classic CLI engine is now active.
2 Navigational and Operational Commands
Table 2 compares the basic navigational and operational commands of the Nokia SR OS MD-CLI to those used by Junos OS and IOS XR.
The //
command can be used to switch CLI engines to access classic CLI commands that are not yet available in the MD-CLI. Enter //command
to run a single command in the other CLI engine. Command completion and ? help are not available when using //command
.
Switching CLI engines is described in the MD-CLI User Guide.
SR OS MD-CLI | Junos OS | IOS XR | |
---|---|---|---|
Move back one or more levels | back [number] |
up [number] |
N/A |
Return to the previous working context or to the operational root | exit [all] |
exit quit |
end exit |
Move to the top level of the context | top |
top |
root |
Access the per-session environment | environment |
set cli |
terminal |
Switch CLI engines | // |
N/A | N/A |
Run a command in the other CLI engine | //command |
N/A | N/A |
Show the command tree under the present working context | tree [flat] |
N/A | N/A |
Exit the CLI session | logout |
exit quit |
exit quit |
3 Entering and Leaving the Configuration Workflow
Table 3 compares the commands for entering and leaving the configuration workflow of the Nokia SR OS MD-CLI to those used by Junos OS and IOS XR.
For more information about the implicit and explicit configuration workflows and the candidate configuration mode, see the MD-CLI User Guide.
SR OS MD-CLI | Junos OS | IOS XR | |
---|---|---|---|
Candidate configuration modes | global exclusive private read-only |
global (not a keyword) exclusive private (not a keyword) |
exclusive |
Enter the implicit configuration workflow | configure mode |
configure [mode] |
configure [mode] |
Leave the implicit configuration workflow | ^Z exit [all] |
exit quit |
^C exit |
Enter the explicit configuration workflow | edit-config mode |
N/A | N/A |
Leave the explicit configuration workflow | quit-config (at operational root) |
N/A | N/A |
4 Configuration Workflow Commands
Table 4 compares the configuration workflow commands of the Nokia SR OS MD-CLI to those used by Junos OS and IOS XR.
SR OS MD-CLI | Junos OS | IOS XR | |
---|---|---|---|
Navigate into a context | Enter the context by typing context For example: router bgp |
edit context For example: edit protocols bgp |
Enter the context by typing context For example: router bgp 65551 |
Set an element in the candidate datastore | Enter the context with a value by typing context value |
set context value |
Enter the context with a value by typing context value |
Delete an element from the candidate datastore | delete context |
delete context |
no context |
Show the candidate configuration from the present working context | info |
show |
show configuration merge |
Show the candidate configuration with default and unconfigured values | info detail |
show | display detail |
N/A |
Show the candidate configuration with inherited values from configuration groups | info inheritance |
show | display inheritance |
show configuration running inheritance |
Show the candidate configuration in a flat format | info flat info full-context |
show | display set |
show configuration merge formal |
Show changes between datastores | compare |
show | compare |
show commit changes diff |
Discard changes in the candidate datastore | discard |
rollback rollback 0 |
abort |
Update the candidate baseline | update |
update |
N/A |
Validate changes in the candidate datastore | validate |
commit check |
N/A |
SR OS MD-CLI | Junos OS | IOS XR | |
---|---|---|---|
Commit changes to the running datastore | commit (also runs validate) |
commit (also runs check) |
commit |
Roll back to a previous configuration | rollback checkpoint | startup |
rollback checkpoint |
rollback configuration to checkpoint |
Run an operational command | /command |
run command |
do command |
4.1 Commit Confirmed Commands
Table 5 compares the commit commands of the Nokia SR OS MD-CLI to those used by Junos OS and IOS XR.
SR OS MD-CLI | Junos OS | IOS XR | |
---|---|---|---|
Start the commit confirmed | commit confirmed [number] |
commit confirmed [number] |
commit confirmed [number] | [minutes number] |
Accept a commit confirmed | commit confirmed accept |
commit |
commit |
Cancel a commit confirmed | commit confirmed cancel |
rollback 1 and commit |
Exit configuration mode or clear the CLI session |
4.2 Configuration Management Commands
Table 6 compares the configuration management commands of the Nokia SR OS MD-CLI to those used by Junos OS and IOS XR.
SR OS MD-CLI | Junos OS | IOS XR | |
---|---|---|---|
Paste configuration | Input is accepted in hierarchical, flat, full-context or compare format, opening ({) and closing (}) braces navigate | Input is accepted in display set format or using load merge terminal relative for hierarchical configuration | Input is accepted in formal format for hierarchical configuration |
Load and merge a configuration file | load merge url commit |
load merge url commit |
load url commit |
Load and replace a configuration file | load full-replace url commit |
load override url commit |
load url commit replace |
Save configuration to a file | info > url |
save url |
copy running-config url |
Show the startup configuration | admin show configuration |
show configuration |
show configuration persistent |
5 Output Modifiers
Table 7 compares the output modifiers of the Nokia SR OS MD-CLI to those used by Junos OS and IOS XR.
SR OS MD-CLI | Junos OS | IOS XR | |
---|---|---|---|
Count occurrences | count |
count |
show | utility wc |
Match a pattern | match string Note: enclose the pattern in apostrophes for regular expression matches |
match regexp |
include regexp |
Disable output pagination | no-more |
no-more |
N/A |
Redirect output to a file | > |
save |
file |
Customer Document and Product Support
Customer Documentation
Customer Documentation Welcome Page
Technical Support
Documentation Feedback