CLI Configuration Guide for Omada SDN Controller (v5.9.9 and above)
CLI configuration is essentially to configure devices via command lines. It is a supplementary means of GUI configuration. CLI configuration may conflict with GUI configuration.
Omada SDN Controller supports two types of CLI configuration: Site CLI and Device CLI.
■ Site CLI
Site CLI supports batch configuration of devices that support CLI configuration on the site.
■ Device CLI
Device CLI supports batch configuration of selected devices.
Currently, CLI configuration only supports switches. Please refer to CLI Reference Guide to understand the CLI commands of TP-Link switches.
If you need to use CLI configuration, please read the precautions and User Guide carefully. You can contact TP-Link technical support if necessary.
After applying the CLI configuration, you can go to Devices > Application Result to view the configuration results.
General Precautions
1. The GUI and CLI configuration should be planned globally according to the actual network topology and requirements.
2. To avoid conflicts, it is recommended not to use the CLI to configure the existing functions of the GUI.
a. When adopting a new device, the Controller will apply configurations to the device in the order of GUI, Site CLI, and then Device CLI. If there is a configuration conflict, the configuration applied last takes effect.
b. CLI profiles (including Site CLI profiles and Device CLI profiles) will only be sent to devices once after applied, unless the “Apply Again” button in the Application Result is clicked to trigger the full configurations application.
c. When a device upgrades its firmware, the Controller will apply the full configurations to the device in the order of GUI, Site CLI, and then Device CLI.
d. Since the later configuration may overwrite the previous configuration, the running configurations of different devices may be different after the same function has been modified repeatedly via GUI, Site CLI and Device CLI.
3. The Omada Controller will not verify the existing GUI and CLI configurations of devices. Be sure to check the existing configurations before performing new configurations. Otherwise, unexpected results may occur after the configurations are applied, and the devices may even go offline.
4. To avoid configuration conflicts, if you really need to use the CLI to configure a certain function, it is recommended not to configure it via GUI at the same time.
5. To avoid disconnection of devices from the Controller due to configuration errors or conflicts, it is recommended to configure VLAN, VLAN Interface, IP Address, ACL, etc. via GUI, and avoid modifying related configurations via CLI.
Repeated Configurations
When the same function is configured via CLI multiple times, the previous configuration may be overwritten, and the last configuration shall prevail.
a. It is recommended to confirm the currently effective commands via the CLI configuration viewing function “Show Running Config”.
b. If you need to cancel a certain configuration, use the “no” command.
c. If you need to modify a certain configuration, you can enter a new command to overwrite the configuration.
d. Apply the final configuration, and confirm that the function is configured correctly and takes effect via the CLI configuration viewing function.
Execution Failures
If a CLI command fails to be executed, an error will be reported and subsequent commands will be executed. You can view the error details via the error message, and the commands that have been successfully executed before will not be undone. It is recommended to follow the steps below:
a. Use the CLI configuration viewing function (Show Running Config) to confirm the commands that have taken effect. If you need to cancel them, you can enter “no” commands and apply them to devices.
b. Troubleshoot and correct the command error, regenerate the CLI configuration, and apply it to devices.
Command Modification
If you need to modify the commands issued via CLI, please follow the steps below:
a. Use the CLI configuration view function (Show Running Config) to confirm the commands that have taken effect, and sort out the commands that need to be canceled.
b. Enter “no” commands to cancel the configurations, and apply them to devices.
Prohibited Commands
1. CLI commands such as modifying user name and password, managing VLAN, SDM profile, reboot, reset, upgrade, import and export configurations have been prohibited. When using other CLI commands, please also pay attention to avoid affecting the management of the Controller.
2. Device CLI supports the variable function. Although the variable content does not have too many restrictions, for example, you can enter CLI commands, but it is not recommended to use it in this way.
1. Site CLI
Overview
Site CLI enables batch configurations of all devices that support CLI configuration on the site via command lines.
Configuration
1. Go to Settings > CLI Configuration > Site CLI.
2. Click Create New Site CLI Profile and create a CLI profile according to your needs.
Note:
• The # character is a special command, which indicates entering the configure mode. Please use it in a separate line. If you add other commands after it in the same line, they will be ignored. • If a command starts with the ! character, the command will be ignored. |
Name |
Specify the name of the CLI profile. |
Description |
(Optional) Enter a description for identification. |
CLI |
Enter the command lines manually. |
Import CLI from Device |
Click and select a device that supports CLI configuration to import its running config. |
Import CLI from File |
Click and select an existing command file to import command lines. |
3. Click Save to add the profile. The new profile is in inactive state and will not be applied to devices.
4. Click Apply to apply the CLI. The profile will change to active state and apply configurations to all devices that support CLI configuration on the site.
Note:
Once the profile becomes active, you will be unable to edit it. |
To check whether the profile is successfully applied to devices and takes effect, click View CLI Details to view the configuration results on the Devices > Application Result page.
Note:
Deleting a CLI profile will not take effect on existing configurations on devices. To delete the configurations, use the “no” command. |
2. Device CLI
Overview
Device CLI enables batch configuration of specific devices via command lines.
Device CLI supports variables. You can use the %x% format to define a variable x, and then set different values for different switches. When the Controller applies the Device CLI configuration to switches, it will automatically modify the variable %x% to the values you set.
Configuration
1. Go to Settings > CLI Configuration > Device CLI. Click Create New Device CLI Profile and create a CLI profile according to your needs.
Note:
•The # character is a special command, which indicates entering the configure mode. Please use it in a separate line. If you add other commands after it in the same line, they will be ignored. •If a command starts with the ! character, the command will be ignored. |
Name |
Specify the name of the CLI profile. |
Description |
(Optional) Enter a description for identification. |
CLI |
Enter the command lines manually. You can enter %xxx% in the CLI template to define variables. |
Import CLI from Device |
Click and select a device that supports CLI configuration to import its running config. |
Import CLI from File |
Click and select an existing command file to import command lines. |
2. Click Next. Select the devices to apply the CLI profile.
3. Click Save to add the profile. The new profile is in inactive state and will not be applied to devices.
4. Click Apply to apply the CLI. The profile will change to active state and apply configurations to the devices you selected.
Note:
Once the profile becomes active, you will be unable to edit it. |
To check whether the profile is successfully applied to devices and takes effect, click View CLI Details to view the configuration results on the Devices > Application Result page.
Note:
Deleting a CLI profile will not take effect on existing configurations on devices. To delete the configurations, use the “no” command. |
Câu hỏi thường gặp này có hữu ích không?
Phản hồi của bạn giúp cải thiện trang web này.