The CLI provides multiple command views. All commands are registered in one or more command views. In general, you can run a command only after entering its view.
In two-phase validation mode, if any configurations are not submitted in the system, * is used for identification in the view. If all configurations have been submitted in the system, ~ is used for identification in the view.
# Set up a connection with the router. If the default configuration is adopted on the router, enter the user view. The following prompt is displayed:
<HUAWEI>
# Enter system-view and press Enter to enter the system view.
<HUAWEI> system-view [~HUAWEI]
# Enter aaa in the system view to enter the AAA view.
[~HUAWEI] aaa [~HUAWEI-aaa]
The default device name is HUAWEI. You can run the sysname command to specify a device name. You can determine the current view based on the prompt. For example, <> indicates the user view, and [] indicates any view except the user view.
In the multi-level view, you can directly enter # to return to the system view.
You can enter ! or # followed by a character string in any view. All entered content (including ! and #) is displayed as comments. That is, the corresponding configuration is not generated.
You can run the quit command to quit the current view and enter a view of a lower level. If the current view is the user view, you are logged out of the system.
You can run the return command to quit the current view and enter the user view. If the current view is the user view, the user view is still displayed.
Certain commands that can be run in the system view can also be run in other views. The function implemented by a command is determined by the command view in which the command is run. For example, if the mpls command is run in the system view, MPLS is enabled globally; if the mpls command is run in the interface view, MPLS is enabled on the interface.