====== Shutdown Cisco Interface ====== Jan 2024 \\ \\ ---- ===== Introduction ===== While working with certain products, usually remotely, it is quite handy to unplug a Network Cable to test resilience (ensure that a backup route or device is used). \\ \\ However, when remote this is almost impossible, so to simulate this we can just take down the relevant interface on the Cisco to simulate a cable disconnect. \\ ---- ==== Shutdown Interface ==== Before shutting down any interfaces, lets look a the status of the interfaces from the console. We can do this at the top level buy using this command: sh interfaces status \\ You will get an output similar to below: \\ Port Name Status Vlan Duplex Speed Type Gi0/1 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/2 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/3 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/4 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/5 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/6 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/7 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/8 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/9 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/10 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/11 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/12 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/13 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/14 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/15 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/16 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/17 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/18 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/19 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/20 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/21 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/22 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/23 ENCtoMuxPri connected 100 a-full a-1000 10/100/1000BaseTX Gi0/24 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Interface 23 is connected, the rest are not. \\ To shutdown an interface, we first have to select it as we would normally do for any other operation. \\ en (enter password) conf t int gigabitEthernet 0/1 (nic 1) - (or you could shutdown a range with int gigabitEthernet 0/1-12 for example) sh end \\ Now if you repeat the following command: \\ \\ sh interfaces status \\ You will see that the first interface is shown as //**disabled**//. \\ Port Name Status Vlan Duplex Speed Type Gi0/1 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/2 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/3 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/4 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/5 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/6 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/7 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/8 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/9 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/10 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/11 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/12 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/13 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/14 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/15 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/16 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/17 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/18 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/19 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/20 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/21 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/22 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/23 ENCtoMuxPri connected 100 a-full a-1000 10/100/1000BaseTX Gi0/24 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX \\ ---- ==== Bring Up Interface ==== To bring the interface back up, use the following: \\ en (enter password) conf t int gigabitEthernet 0/1 (nic 1) - (or you could bring up a range with int gigabitEthernet 0/1-12 for example) no sh end \\ ---- ==== Bring Up/Down more Interfaces ==== When we select the interface to Shutdown/Bring up we used in this above example: \\ int gigabitEthernet 0/1 \\ \\ This shuts down a single interface (The first interface on the box). We could however shutdown the first 10 interfaces by using: \\ en (enter password) conf t int range gigabitEthernet 0/1-10 no sh end \\ Now we can see the first 10 interfaces are down: \\ Port Name Status Vlan Duplex Speed Type Gi0/1 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/2 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/3 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/4 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/5 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/6 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/7 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/8 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/9 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/10 MNGT disabled 100 auto auto 10/100/1000BaseTX Gi0/11 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/12 MNGT notconnect 100 auto auto 10/100/1000BaseTX Gi0/13 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/14 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/15 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/16 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/17 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/18 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/19 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/20 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/21 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/22 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX Gi0/23 ENCtoMuxPri connected 100 a-full a-1000 10/100/1000BaseTX Gi0/24 ENCtoMuxPri notconnect 100 auto auto 10/100/1000BaseTX \\ ----