Latest

Cisco DNA Center Guardian Version 2.3.3.x - Host entry cleanup in Maglev

Cisco DNA Center Guardian Version 2.3.3.x - Host entry cleanup in Maglev

We are going to discuss on the commands in order to cleanup host entry from the DNA Center controller maglev. This is specifically for the Guardian version as it is locked by default and in the earlier versions it is not locked. Below are the steps to verify and cleanup the host entry. 

Cisco DNA Center currently provides the option of bypassing the restricted shell if you use any CLI-based scripts or troubleshooting commands.


Cisco DNA Center defaults to restricted shell. The steps below will guide you through the process of disabling restricted shell.

Step 1: Enter the following CLI command to determine your shell type:

$ magctl ssh shell display
Active shell for current user: bash

The command returns one of the following outputs, depending on your shell:

$ magctl ssh shell display
Active shell for current user: magshell

The _shell commands work only when you are in magshell.

Step 2: If the preceding command output confirms that you are in magshell, and you then want to disable restricted shell, enter the following CLI command and password:

$ _shell -c 'sudo magctl ssh shell bash'
Password:
Warning! Activity within this shell can jeopardize the functioning of the system!
[sudo] password for maglev:
Successfully enabled bash for user, will be effective from next login.

Step 3: For the change to take effect, exit from the CLI session and then log back in to the CLI session.

Step 4: (Optional) To re-enable restricted shell, enter the following CLI command and password:

$ sudo magctl ssh shell magshell
[sudo] password for maglev:
Successfully enabled magshell for user, will be effective from next login.

Step 5: For the change to take effect, exit from the CLI session and then log back in to the CLI session.

For other Maglev commands on Cisco DNA center, please check the below article 

Cisco DNA Center Maglev command reference