check the linux interfaces with ip address


128T runningsystemctl status 128T
Active

systemctl status 128T | grep "[[:space:]]Active"

Active: active (running) since Wed 2021-12-08 16:03:02 UTC; 19h ago


ip a | awk '{print $1, $2}' | grep "^[[:digit:]]:"

ip netns

ip netns exec routingEngine ip a | awk '{print $1, $2}' | grep "^[[:digit:]]:"

linux interfaces
[root@dc1 ~]#  ip a | awk '{print $1, $2}' | grep "^[[:digit:]]:"
1: lo:
3: eth1:
4: eth2:
6: kni254:

[root@dc1 ~]# ip netns
routingEngine


[root@dc1 ~]#  ip netns exec routingEngine ip a | awk '{print $1, $2}' | grep "^[[:digit:]]:"
1: lo:
2: g2:    Global id: 2
3: g11:   Global id: 11
4: g4294967294:

Stoppedsystemctl status 128T

systemctl status 128T | grep "[[:space:]]Active"

linux interfaces
[root@dc1 ~]#  ip a | awk '{print $1, $2}' | grep "^[[:digit:]]:"
1: lo:
3: eth1:
4: eth2:
7: eth0:
8: eth3:

, 6: kni254:  >>> has been removed too!

[root@dc1 ~]# ip netns
>>> nothing , the name space has been removed