HPE Aruba Commands

HPE Aruba ArubaOS and AOS-CX CLI commands.

Switch Startup Procedure

Step 1: Power on switchBoth

Boot the switch hardware

Step 2: Wait for bootBoth

Wait 2-4 minutes for OS to load

Step 3: Check system statusBoth

Verify system is operational

show versionBoth

Display OS version and system info

show systemArubaOS

Display system status

show system resource-utilizationAOS-CX

Display system resources

Step 4: Verify interfacesBoth

Check interface states

show interfaces briefBoth

Display interface summary

Switch Shutdown Procedure

Step 1: Save configurationBoth

Ensure configuration is saved before shutdown

write memoryBoth

Save configuration

Step 2: Verify config saved (AOS-CX)AOS-CX

Create checkpoint for safety

checkpoint pre-shutdownAOS-CX

Create configuration checkpoint

Step 3: Graceful shutdown/rebootBoth

Reboot or power off the switch

reloadArubaOS

Reboot switch

boot systemAOS-CX

Reboot switch

Step 4: Factory reset (if needed)Both

Reset to factory defaults

erase startup-configBoth

Erase startup configuration

Basic Navigation - ArubaOS

enableArubaOS

Enter privileged mode

configure terminalArubaOS

Enter configuration mode

exitArubaOS

Exit current mode

endArubaOS

Exit to privileged mode

show running-configArubaOS

Display running configuration

show startup-configArubaOS

Display startup configuration

write memoryArubaOS

Save configuration

show tech allArubaOS

Display all technical information

Basic Navigation - AOS-CX

configure terminalAOS-CX

Enter configuration mode

endAOS-CX

Exit configuration mode

exitAOS-CX

Exit current context

show running-configAOS-CX

Display running configuration

show startup-configAOS-CX

Display startup configuration

write memoryAOS-CX

Save configuration

checkpoint <name>AOS-CX

Create configuration checkpoint

show checkpointsAOS-CX

List configuration checkpoints

rollback <name>AOS-CX

Rollback to checkpoint

Interface Configuration - ArubaOS

interface <port>ArubaOS

Enter interface configuration mode

description "<text>"ArubaOS

Set interface description

enableArubaOS

Enable interface

disableArubaOS

Disable interface

speed-duplex <value>ArubaOS

Set speed and duplex (10-half, 100-full, auto, etc)

untagged vlan <vlan-id>ArubaOS

Set access VLAN

tagged vlan <vlan-list>ArubaOS

Set trunk allowed VLANs

lacp <mode>ArubaOS

Configure LACP (passive/active)

show interfacesArubaOS

Display all interfaces

show interfaces <port>ArubaOS

Display specific interface

Interface Configuration - AOS-CX

interface <slot>/<port>AOS-CX

Enter interface configuration

description <text>AOS-CX

Set interface description

no shutdownAOS-CX

Enable interface

shutdownAOS-CX

Disable interface

speed <speed>AOS-CX

Set interface speed

vlan access <vlan-id>AOS-CX

Set access VLAN

vlan trunk native <vlan-id>AOS-CX

Set native VLAN

vlan trunk allowed <vlan-list>AOS-CX

Set allowed VLANs

lag <lag-id>AOS-CX

Add interface to LAG

show interface <port>AOS-CX

Display interface details

show interface briefAOS-CX

Display interface summary

VLAN Configuration

vlan <vlan-id>ArubaOS

Create VLAN

name <vlan-name>ArubaOS

Name VLAN

show vlansArubaOS

Display VLAN information

vlan <vlan-id>AOS-CX

Create VLAN

name <vlan-name>AOS-CX

Name VLAN

interface vlan <vlan-id>AOS-CX

Create VLAN interface (SVI)

ip address <ip>/<mask>AOS-CX

Set IP on VLAN interface

show vlanBoth

Display VLANs

show vlan <vlan-id>Both

Display specific VLAN

Link Aggregation

trunk <port-list> trk<id> lacpArubaOS

Create LACP trunk

show trunksArubaOS

Display trunk information

show lacpArubaOS

Display LACP status

interface lag <id>AOS-CX

Create LAG interface

no shutdownAOS-CX

Enable LAG

lacp mode activeAOS-CX

Set LACP mode

show lacp aggregatesAOS-CX

Display LAG information

show lacp interfacesAOS-CX

Display LACP interface details

Routing - Static

ip route 0.0.0.0 0.0.0.0 <gateway>ArubaOS

Add default route

ip route <network> <mask> <gateway>ArubaOS

Add static route

show ip routeArubaOS

Display routing table

ip route 0.0.0.0/0 <gateway>AOS-CX

Add default route

ip route <network>/<mask> <gateway>AOS-CX

Add static route

show ip routeAOS-CX

Display routing table

Routing - OSPF

router ospfArubaOS

Enter OSPF configuration

area <area-id>ArubaOS

Configure OSPF area

enableArubaOS

Enable OSPF

show ip ospfArubaOS

Display OSPF status

show ip ospf neighborArubaOS

Display OSPF neighbors

router ospf <process-id>AOS-CX

Enable OSPF

area <area-id>AOS-CX

Configure OSPF area

network <network>/<mask> area <area-id>AOS-CX

Add network to OSPF area

show ip ospfAOS-CX

Display OSPF configuration

show ip ospf neighborAOS-CX

Display OSPF neighbors

Routing - BGP (AOS-CX)

router bgp <as-number>AOS-CX

Enable BGP

bgp router-id <router-id>AOS-CX

Set BGP router ID

neighbor <ip> remote-as <as-number>AOS-CX

Configure BGP neighbor

neighbor <ip> description <text>AOS-CX

Set neighbor description

address-family ipv4 unicastAOS-CX

Enter IPv4 address family

neighbor <ip> activateAOS-CX

Activate neighbor

network <network>/<mask>AOS-CX

Advertise network

show bgp summaryAOS-CX

Display BGP summary

show bgp neighborsAOS-CX

Display BGP neighbors

show bgp ipv4 unicastAOS-CX

Display BGP routes

Access Control Lists

access-list <number> <permit|deny> <source>ArubaOS

Create standard ACL

access-list extended <name>ArubaOS

Create extended ACL

<permit|deny> <protocol> <source> <dest>ArubaOS

Add extended ACL rule

show access-listArubaOS

Display ACLs

access-list ip <name>AOS-CX

Create IPv4 ACL

<seq> <permit|deny> <protocol> <source> <dest>AOS-CX

Add ACL entry

apply access-list ip <name> inAOS-CX

Apply ACL to interface

show access-listAOS-CX

Display ACLs

show access-list <name> commandsAOS-CX

Display ACL in command format

Spanning Tree

spanning-treeArubaOS

Enable STP globally

spanning-tree <port> priority <priority>ArubaOS

Set port priority

show spanning-treeArubaOS

Display STP information

spanning-treeAOS-CX

Enable STP

spanning-tree mode <mode>AOS-CX

Set STP mode (mstp/rpvst+)

spanning-tree priority <priority>AOS-CX

Set bridge priority

show spanning-treeAOS-CX

Display STP status

VSX (Virtual Switching Extension) - AOS-CX

vsxAOS-CX

Enter VSX configuration

system-mac <mac>AOS-CX

Set VSX system MAC

inter-switch-link <lag-id>AOS-CX

Configure ISL

role primaryAOS-CX

Set device as primary

role secondaryAOS-CX

Set device as secondary

keepalive peer <ip> source <ip>AOS-CX

Configure keepalive

show vsx statusAOS-CX

Display VSX status

show vsx briefAOS-CX

Display VSX brief status

active-gateway <mac>AOS-CX

Configure active gateway MAC

Monitoring & Troubleshooting

show systemArubaOS

Display system information

show interfacesBoth

Display interface status

show mac-addressArubaOS

Display MAC address table

show arpBoth

Display ARP table

show lldp info remote-deviceArubaOS

Display LLDP neighbors

show logArubaOS

Display system logs

show system resource-utilizationAOS-CX

Display system resources

show mac-address-tableAOS-CX

Display MAC address table

show lldp neighbor-infoAOS-CX

Display LLDP neighbors

show eventsAOS-CX

Display event logs

ping <ip>Both

Ping destination

traceroute <ip>Both

Trace route to destination

System Management

hostname "<name>"ArubaOS

Set hostname

ip default-gateway <ip>ArubaOS

Set default gateway

timesync sntpArubaOS

Enable SNTP

sntp server priority 1 <ip>ArubaOS

Configure SNTP server

hostname <name>AOS-CX

Set hostname

ntp server <ip>AOS-CX

Configure NTP server

ntp enableAOS-CX

Enable NTP

clock timezone <zone>AOS-CX

Set timezone

show systemBoth

Display system information

show versionBoth

Display OS version