我有一个Cisco路由器,我需要知道哪个接口用于LAN。这是显示接口描述输出: R1#sho int desc
Interface Status Protocol Description
Em0/0 admin down down
Gi0/0 up up LAN
Gi0/1 up up WAN
Gi0/2 u
我试图创建一个类来使用pexpect连接到框,并从该框中获取一些数据,并且我很难创建一个包含我盒子的pexpect会话的函数并为我在下面的类代码示例中创建的每个对象进行初始化。 class A:
def __init__(self)
# in this way a session will be created for each object and i don't