Home > Networking Solutions > Enterprise/Data Center Networking Solutions > Enterprise SONiC Networking Solutions > Guides > Zero Touch Deployment of Open Dell Switches with SONiC > Diagnostic commands
The following tables provide an overview of some useful commands to monitor or diagnose status. Some commands are related to the SONiC Click CLI, and others are related to the Dell management CLI (mf-cli or sonic-cli). The click-cli is available after you log in to SONiC. If you type sonic-cli, you enter the management framework CLI. This CLI resembles such as the Cisco, Dell OS10 or Arista CLIs. In the SONiC Click shell, you need to run some commands as root, that is, prefix them with sudo.
COMMAND | SHELL | PURPOSE |
ztp status | SONiC click | Show the status of ztp staging |
sudo ztp | SONiC click | Show available ztp options |
sudo ztp run -y | SONiC click | Start a ztp install |
sudo config save -y | SONiC click | Write configuration to config-db.json file |
sudo cat /var/log/ztp.log | SONiC click | Show SONiC ztp logfile |
sonic-cli | SONiC click | Log in to management-cli (sonic-cli) |
sudo cat /etc/sonic/config_db.json | SONiC click | Show SONiC saved configuration file (startup config) |
show interface Management | Sonic-cli | Show management interface details |
show version | Sonic-cli | Show version details of SONiC |
onie_mode_set --help | SONiC click | Show available ONIE options that can be set from SONiC |
sudo onie_mode_set -o uninstall | SONiC click | Set ONIE to delete all NOSes and start factory default discovery and execution method of ztp installation (reboot needed after command) |
COMMAND | SHELL | PURPOSE |
docker-compose ps | Linux | Show started containers |
docker-compose ps -a | Linux | Show all containers (started and not started) |
docker ps | Linux | Show started containers with container ids |
docker ps -a | Linux | Show all containers with container ids (started and not started) |
docker logs <container id> | Linux | Show log of container |
docker logs <container id> -f | Linux | Follow log of container |