发布网友
共2个回答
热心网友
eth1似乎是Linux下的命名方法,Mac OS不是这么定义的。前排童鞋说的,先查一下有没有eth1这个设备。
热心网友
ifconfig命令看看,有没有 eth1 这个网卡?追问
执行过ifconfig,没有这个网卡,有en0/en1
en0的信息如下
在linux上执行print get_ip_address('eth0') 能够获取到IP
在Mac OS上执行 print get_ip_address('en0') 就报"Device not configured"