Basic Show Commands
Objective
This document explains how to use basic show commands on community sonic to retrieve system information, hardware details, software versions, and transceiver status. These commands help network administrators quickly check the operational status and hardware inventory of a device.
Show Versions
Show System Status
Show Hardware Platform
Transceivers
Prerequisites
Hardware:
Switches or routers that support VLANs
(e.g., edgecore, ufispace)
Software:
Network operating systems that support VLAN configuration
(e.g., SONiC.master )
Access:
Administrative or privileged CLI access
Basic Show commands
Example:
Accessing a switch or router via SSH or console to run diagnostic commands.
1.Show Versions
show version
This command displays software component versions of the currently running SONiC image. This includes the SONiC image version as well as Docker image versions.
root@sonic:/home/admin# show version
SONiC Software Version: SONiC.master.265656-14a5f21c0
SONiC OS Version: 11
Distribution: Debian 11.7
Kernel: 5.10.0-18-2-amd64
Build commit: 14a5f21c0
Build date: Wed May 3 14:46:49 UTC 2023
Built by: AzDevOps@vmss-soni000ZPG
Platform: x86_64-accton_as5712_54x-r0
HwSKU: Accton-AS5712-54X
ASIC: broadcom
ASIC Count: 1
Serial Number: N/A
Model Number: N/A
Hardware Revision: N/A
Uptime: 12:13:20 up 1 day, 5 min, 4 users, load average: 0.04, 0.06, 0.09
Date: Thu 22 Jun 2023 12:13:20
Docker images:
REPOSITORY TAG IMAGE ID SIZE
docker-gbsyncd-broncos latest 1d86f1bff3f6 362MB
docker-gbsyncd-broncos master.265656-14a5f21c0 1d86f1bff3f6 362MB
docker-gbsyncd-credo latest d674155ecc1c 334MB
docker-gbsyncd-credo master.265656-14a5f21c0 d674155ecc1c 334MB
docker-syncd-brcm latest 83dadedc1863 686MB
docker-syncd-brcm master.265656-14a5f21c0 83dadedc1863 686MB
docker-orchagent latest fa685c05fe9b 342MB
docker-orchagent master.265656-14a5f21c0 fa685c05fe9b 342MB
docker-fpm-frr latest bd961143de60 359MB
docker-fpm-frr master.265656-14a5f21c0 bd961143de60 359MB
docker-nat latest 1dfee97506e5 333MB
docker-nat master.265656-14a5f21c0 1dfee97506e5 333MB
docker-sflow latest 9d2f0e1c0756 331MB
docker-sflow master.265656-14a5f21c0 9d2f0e1c0756 331MB
docker-teamd latest c5d65d0de2c7 330MB
docker-teamd master.265656-14a5f21c0 c5d65d0de2c7 330MB
docker-macsec latest 9dde7795fa79 332MB
docker-dhcp-relay latest ae0e89b74516 323MB
docker-eventd latest a42b41d38350 313MB
docker-eventd master.265656-14a5f21c0 a42b41d38350 313MB
docker-sonic-p4rt latest a53a6dfc3e0a 884MB
docker-sonic-p4rt master.265656-14a5f21c0 a53a6dfc3e0a 884MB
docker-snmp latest 35846b8faab9 352MB
docker-snmp master.265656-14a5f21c0 35846b8faab9 352MB
docker-sonic-telemetry latest 415a44bfe7b8 611MB
docker-sonic-telemetry master.265656-14a5f21c0 415a44bfe7b8 611MB
docker-router-advertiser latest 21113252f215 313MB
docker-router-advertiser master.265656-14a5f21c0 21113252f215 313MB
docker-platform-monitor latest cabcc7bfc2d1 434MB
docker-platform-monitor master.265656-14a5f21c0 cabcc7bfc2d1 434MB
docker-lldp latest d1e535df05a8 355MB
docker-lldp master.265656-14a5f21c0 d1e535df05a8 355MB
docker-mux latest 45d88628a5a8 362MB
docker-mux master.265656-14a5f21c0 45d88628a5a8 362MB
docker-database latest dd81f39dcc4e 313MB
docker-database master.265656-14a5f21c0 dd81f39dcc4e 313MB
docker-sonic-mgmt-framework latest 49ef5510de31 413MB
docker-sonic-mgmt-framework master.265656-14a5f21c0 49ef5510de31 413MB
2.Show System Status
show clock
This command displays the current date and time configured on the system.
root@sonic:/home/admin# show clock
Thu 22 Jun 2023 12:15:20 PM IST
Show clock timezones
Show boot
This command displays the current OS image, the image to be loaded on next reboot, and lists all the available images installed on the device.
root@sonic:/home/admin# show boot
Current: SONiC-OS-master.265656-14a5f21c0
Next: SONiC-OS-master.265656-14a5f21c0
Available:
SONiC-OS-master.265656-14a5f21c0
Show environment
This command displays the platform environment, such as voltages, temperatures and fan speeds.
root@sonic:/home/admin# show environment
lm75-i2c-61-48
Adapter: i2c-0-mux (chan_id 5)
Main Board Temperature: +24.5 C (high = +80.0 C, hyst = +75.0 C)
cpr_4011_4mxx-i2c-58-3f
Adapter: i2c-0-mux (chan_id 2)
PSU 2 Voltage In: 0.00 V
PSU 2 Voltage Out: 0.00 V
PSU 2 Fan: 0 RPM
PSU 2 Temperature: +0.0 C
PSU 2 Power In: 0.00 W
PSU 2 Power Out: 0.00 W
PSU 2 Current In: 0.00 A
PSU 2 Current Out: 0.00 A
lm75-i2c-63-4a
Adapter: i2c-0-mux (chan_id 7)
Main Board Temperature: +21.0 C (high = +80.0 C, hyst = +75.0 C)
coretemp-isa-0000
Adapter: ISA adapter
Core 0: +23.0 C (high = +98.0 C, crit = +98.0 C)
Core 1: +23.0 C (high = +98.0 C, crit = +98.0 C)
Core 2: +24.0 C (high = +98.0 C, crit = +98.0 C)
Core 3: +24.0 C (high = +98.0 C, crit = +98.0 C)
lm75-i2c-62-49
Adapter: i2c-0-mux (chan_id 6)
Main Board Temperature: +23.0 C (high = +80.0 C, hyst = +75.0 C)
cpr_4011_4mxx-i2c-57-3c
Adapter: i2c-0-mux (chan_id 1)
PSU 1 Voltage In: 226.00 V
PSU 1 Voltage Out: 12.00 V
PSU 1 Fan: 6240 RPM
PSU 1 Temperature: +0.0 C
PSU 1 Power In: 87.00 mW
PSU 1 Power Out: 75.00 mW
PSU 1 Current In: 429.00 mA
PSU 1 Current Out: 6.25 A
as5712_54x_fan-isa-0000
Adapter: ISA adapter
Fan 1 Front: 11400 RPM
Fan 2 Front: 11550 RPM
Fan 3 Front: 11550 RPM
Fan 4 Front: 11550 RPM
Fan 5 Front: 11550 RPM
Fan 1 Rear: 9750 RPM
Fan 2 Rear: 9750 RPM
Fan 3 Rear: 9750 RPM
Fan 4 Rear: 9750 RPM
Fan 5 Rear: 9750 RPM
Show reboot-cause
This command displays the cause of the previous reboot.
root@sonic:/home/admin# show reboot-cause
User issued 'warm-reboot' command [User: admin, Time: Wed 21 Jun 2023 12:06:49 PM IST]
Show reboot-cause history
This command displays the history of the previous reboots up to 10 entries.
root@sonic:/home/admin# show reboot-cause history
Name Cause Time User Comment
------------------- ----------- ------------------------------- ------ ---------
2023_06_21_12_08_05 warm-reboot Wed 21 Jun 2023 12:06:49 PM IST admin N/A
2023_06_21_12_04_21 reboot Wed 21 Jun 2023 12:02:04 PM IST admin N/A
2023_06_21_09_46_36 warm-reboot Wed 21 Jun 2023 09:45:13 AM IST admin N/A
2023_06_21_09_42_30 warm-reboot Wed 21 Jun 2023 09:41:14 AM IST admin N/A
2023_06_20_22_31_05 reboot Tue 20 Jun 2023 10:29:13 PM IST admin N/A
2023_06_16_10_46_38 reboot Fri 16 Jun 2023 10:44:21 AM IST admin N/A
2023_06_15_17_13_13 reboot Thu 15 Jun 2023 05:10:56 PM IST admin N/A
2023_06_15_14_21_56 reboot Thu 15 Jun 2023 02:19:39 PM IST admin N/A
2023_06_15_10_46_35 reboot Thu 15 Jun 2023 10:44:17 AM IST admin N/A
2023_06_14_17_22_03 reboot Wed 14 Jun 2023 05:19:44 PM IST admin N/A
Show uptime
This command displays the current system uptime.
root@sonic:/home/admin# show uptime
up 1 day, 31 minutes
Show logging
This command displays all the currently stored log messages.
root@sonic:/home/admin# show logging --lines 10
Jun 22 13:41:28.792910 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:28] "GET /platform HTTP/1.1" 200 1611 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:28.803525 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:28] "GET /version HTTP/1.1" 200 1063 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:38.203700 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:38] "GET /interfaces HTTP/1.1" 200 35709 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:38.647339 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:38] "GET /lldp HTTP/1.1" 200 11111 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:38.705266 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:38] "GET /platform HTTP/1.1" 200 1611 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:38.719819 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:38] "GET /version HTTP/1.1" 200 1063 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:48.220558 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:48] "GET /interfaces HTTP/1.1" 200 35709 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:48.696186 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:48] "GET /lldp HTTP/1.1" 200 11111 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:48.720628 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:48] "GET /platform HTTP/1.1" 200 1611 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
Jun 22 13:41:48.772952 sonic INFO python3[32240]: 172.26.1.101 - - [22/Jun/2023:13:41:48] "GET /version HTTP/1.1" 200 1063 "" "Apache-HttpClient/4.5.14 (Java/11.0.19)"
root@sonic:/home/admin# show logging sensord --lines 20
Jun 22 13:41:16.754370 sonic INFO pmon#sensord: Adapter: i2c-0-mux (chan_id 6)
Jun 22 13:41:16.757565 sonic INFO pmon#sensord: Main Board Temperature: 23.0 C (limit = 80.0 C, hysteresis = 75.0 C)
Jun 22 13:41:16.757565 sonic INFO pmon#sensord: Chip: cpr_4011_4mxx-i2c-57-3c
Jun 22 13:41:16.757565 sonic INFO pmon#sensord: Adapter: i2c-0-mux (chan_id 1)
Jun 22 13:41:16.780379 sonic INFO pmon#sensord: PSU 1 Voltage In: +226.00 V
Jun 22 13:41:16.780379 sonic INFO pmon#sensord: PSU 1 Voltage Out: +12.00 V
Jun 22 13:41:16.780657 sonic INFO pmon#sensord: PSU 1 Fan: 6272 RPM
Jun 22 13:41:16.780715 sonic INFO pmon#sensord: PSU 1 Temperature: 0.0 C
Jun 22 13:41:16.780857 sonic INFO pmon#sensord: Chip: as5712_54x_fan-isa-0000
Jun 22 13:41:16.780940 sonic INFO pmon#sensord: Adapter: ISA adapter
Jun 22 13:41:16.788950 sonic INFO pmon#sensord: Fan 1 Front: 11400 RPM
Jun 22 13:41:16.788950 sonic INFO pmon#sensord: Fan 2 Front: 11550 RPM
Jun 22 13:41:16.789249 sonic INFO pmon#sensord: Fan 3 Front: 11700 RPM
Jun 22 13:41:16.789343 sonic INFO pmon#sensord: Fan 4 Front: 11550 RPM
Jun 22 13:41:16.789586 sonic INFO pmon#sensord: Fan 5 Front: 11550 RPM
Jun 22 13:41:16.789719 sonic INFO pmon#sensord: Fan 1 Rear: 9750 RPM
Jun 22 13:41:16.789838 sonic INFO pmon#sensord: Fan 2 Rear: 9750 RPM
Jun 22 13:41:16.790039 sonic INFO pmon#sensord: Fan 3 Rear: 9750 RPM
Jun 22 13:41:16.790139 sonic INFO pmon#sensord: Fan 4 Rear: 9750 RPM
Jun 22 13:41:16.790369 sonic INFO pmon#sensord: Fan 5 Rear: 9750 RPM
Show users
This command displays a list of users currently logged in to the device.
root@sonic:/home/admin# show users
admin pts/0 2023-06-22 13:39 (172.26.1.108)
admin pts/1 2023-06-22 13:41 (172.25.1.10)
3.Show Hardware Platform
Show platform summary
This command displays a summary of the device's hardware platform.
root@sonic:/home/admin# show platform summary
Platform: x86_64-accton_as5712_54x-r0
HwSKU: Accton-AS5712-54X
ASIC: broadcom
ASIC Count: 1
Serial Number: N/A
Model Number: N/A
Hardware Revision: N/A
Show platform syseeprom
Show platform ssdhealth
This command displays health parameters of the device's SSD.
root@sonic:/home/admin# show platform ssdhealth
Device Model : TS32GMSA370
Health : 99%
Temperature : 100C
Show platform psustatus
Show platform fan
This command displays the status of the device's fans.
root@sonic:/home/admin# show platform fan
Drawer LED FAN Speed Direction Presence Status Timestamp
-------- ----- ----------- ------- ----------- ---------- -------- -----------------
Fantray1 green FAN_1 9400RPM intake Present OK 20221225 07:15:36
Fantray5 green FAN_10 7700RPM intake Present OK 20221225 07:16:36
N/A PSU_1_FAN_1 5000RPM intake Present OK 20221225 07:16:36
Show platform temparature
This command displays the status of the device's thermal sensors.
root@sonic:/home/admin# show platform temperature
Sensor Temperature High TH Low TH Crit High TH Crit Low TH Warning Timestamp
-------- ------------- --------- -------- -------------- ------------- --------- -----------------
TEMP 1 38 80 N/A N/A N/A False 20190214 23:27:18
TEMP 4 32 80 N/A N/A N/A False 20190214 23:28:18
TEMP 5 33 80 N/A N/A N/A False 20190214 23:28:18
TEMP 6 0 80 N/A N/A N/A False 20190214 23:28:18
4.Transceivers
Displays diagnostic monitoring information of the transceivers.
Show interface transceivers eeprom
Decode and display information stored on the EEPROM of SFP transceiver connected to Ethernet60.
root@sonic:/home/admin# show interfaces transceiver eeprom Ethernet60
Ethernet60: SFP EEPROM Not detected
root@sonic:/home/admin# show interfaces transceiver eeprom
Ethernet0: SFP EEPROM Not detected
Ethernet1: SFP EEPROM Not detected
Ethernet2: SFP EEPROM Not detected
Ethernet3: SFP EEPROM Not detected
Ethernet4: SFP EEPROM Not detected
Ethernet5: SFP EEPROM Not detected
Ethernet6: SFP EEPROM Not detected
Ethernet7: SFP EEPROM Not detected
Ethernet8: SFP EEPROM Not detected
Ethernet9: SFP EEPROM Not detected
Ethernet10: SFP EEPROM Not detected
Ethernet11: SFP EEPROM Not detected
Ethernet12: SFP EEPROM Not detected
Ethernet13: SFP EEPROM Not detected
Ethernet14: SFP EEPROM Not detected
Ethernet15: SFP EEPROM Not detected
Ethernet16: SFP EEPROM Not detected
Ethernet17: SFP EEPROM Not detected
Ethernet18: SFP EEPROM Not detected
Ethernet19: SFP EEPROM Not detected
Ethernet20: SFP EEPROM Not detected
Ethernet21: SFP EEPROM Not detected
Ethernet22: SFP EEPROM Not detected
Ethernet23: SFP EEPROM Not detected
Ethernet24: SFP EEPROM Not detected
Ethernet25: SFP EEPROM Not detected
Ethernet26: SFP EEPROM Not detected
Ethernet27: SFP EEPROM Not detected
Ethernet28: SFP EEPROM Not detected
Ethernet29: SFP EEPROM Not detected
Ethernet30: SFP EEPROM Not detected
Ethernet31: SFP EEPROM Not detected
Ethernet32: SFP EEPROM Not detected
Ethernet33: SFP EEPROM Not detected
Ethernet34: SFP EEPROM Not detected
Ethernet35: SFP EEPROM Not detected
Ethernet36: SFP EEPROM Not detected
Ethernet37: SFP EEPROM Not detected
Ethernet38: SFP EEPROM Not detected
Ethernet39: SFP EEPROM Not detected
Ethernet40: SFP EEPROM Not detected
Ethernet41: SFP EEPROM Not detected
Ethernet42: SFP EEPROM Not detected
Ethernet43: SFP EEPROM Not detected
Ethernet44: SFP EEPROM Not detected
Ethernet45: SFP EEPROM Not detected
Ethernet46: SFP EEPROM Not detected
Ethernet47: SFP EEPROM Not detected
Ethernet48: SFP EEPROM Not detected
Ethernet49: SFP EEPROM Not detected
Ethernet50: SFP EEPROM Not detected
Ethernet51: SFP EEPROM Not detected
Ethernet52: SFP EEPROM Not detected
Ethernet53: SFP EEPROM Not detected
Ethernet54: SFP EEPROM Not detected
Ethernet55: SFP EEPROM Not detected
Ethernet56: SFP EEPROM Not detected
Ethernet57: SFP EEPROM Not detected
Ethernet58: SFP EEPROM Not detected
Ethernet59: SFP EEPROM Not detected
Ethernet60: SFP EEPROM Not detected
Ethernet61: SFP EEPROM Not detected
Ethernet62: SFP EEPROM Not detected
Ethernet63: SFP EEPROM Not detected
Ethernet64: SFP EEPROM Not detected
Ethernet65: SFP EEPROM Not detected
Ethernet66: SFP EEPROM Not detected
Ethernet67: SFP EEPROM Not detected
Ethernet68: SFP EEPROM Not detected
Ethernet69: SFP EEPROM Not detected
Ethernet70: SFP EEPROM Not detected
Ethernet71: SFP EEPROM Not detected
root@sonic:/home/admin#
Show interface transceivers info
Decode and display information stored on the EEPROM of SFP transceiver connected to Ethernet60.
root@sonic:/home/admin# show interfaces transceiver info Ethernet60
Ethernet60: SFP EEPROM Not detected
Show interface transceivers lpmode
Show interface transceivers pm
Display performance monitoring info of SFP transceiver connected to Ethernet60.
root@sonic:/home/admin# show interfaces transceiver pm Ethernet60
Ethernet60: Transceiver performance monitoring not applicable
Show interface transceivers presence
Display presence of SFP transceiver connected to Ethernet60.
root@sonic:/home/admin# show interfaces transceiver presence Ethernet60
Port Presence
---------- -----------
Ethernet60 Not present
root@sonic:/home/admin# show interfaces transceiver presence
Port Presence
---------- -----------
Ethernet0 Not present
Ethernet1 Not present
Ethernet2 Not present
Ethernet3 Not present
Ethernet4 Not present
Ethernet5 Not present
Ethernet6 Not present
Ethernet7 Not present
Ethernet8 Not present
Ethernet9 Not present
Ethernet10 Not present
Ethernet11 Not present
Ethernet12 Not present
Ethernet13 Not present
Ethernet14 Not present
Ethernet15 Not present
Ethernet16 Not present
Ethernet17 Not present
Ethernet18 Not present
Ethernet19 Not present
Ethernet20 Not present
Ethernet21 Not present
Ethernet22 Not present
Ethernet23 Not present
Ethernet24 Not present
Ethernet25 Not present
Ethernet26 Not present
Ethernet27 Not present
Ethernet28 Not present
Ethernet29 Not present
Ethernet30 Not present
Ethernet31 Not present
Ethernet32 Not present
Ethernet33 Not present
Ethernet34 Not present
Ethernet35 Not present
Ethernet36 Not present
Ethernet37 Not present
Ethernet38 Not present
Ethernet39 Not present
Ethernet40 Not present
Ethernet41 Not present
Ethernet42 Not present
Ethernet43 Not present
Ethernet44 Not present
Ethernet45 Not present
Ethernet46 Not present
Ethernet47 Not present
Ethernet48 Not present
Ethernet49 Not present
Ethernet50 Not present
Ethernet51 Not present
Ethernet52 Not present
Ethernet53 Not present
Ethernet54 Not present
Ethernet55 Not present
Ethernet56 Not present
Ethernet57 Not present
Ethernet58 Not present
Ethernet59 Not present
Ethernet60 Not present
Ethernet61 Not present
Ethernet62 Not present
Ethernet63 Not present
Ethernet64 Not present
Ethernet65 Not present
Ethernet66 Not present
Ethernet67 Not present
Ethernet68 Not present
Ethernet69 Not present
Ethernet70 Not present
Ethernet71 Not present
root@sonic:/home/admin#
Verification
Ensure all components report OK or Normal status.
Check for any missing or failed modules or transceivers.
Review uptime and version information for maintenance planning.
Troubleshooting Tips
If hardware components are missing, reseat or replace them.
For high CPU or memory usage, check running processes or active services.
If transceivers show faults, check compatibility and clean fiber connectors.
Always compare current software versions with the recommended version from the vendor.