kevinyangkaiguo

kev@kevin:~/桌面$ ifconfig
enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet6 fe80::8e62:95fc:5e28:b47 prefixlen 64 scopeid 0x20<link>
ether 08:00:27:5e:05:7a txqueuelen 1000 (以太网)
RX packets 11745 bytes 2606989 (2.6 MB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1785 bytes 253998 (253.9 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (本地环回)
RX packets 1464 bytes 124561 (124.5 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1464 bytes 124561 (124.5 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

没有IP地址,网络连不上。

处理:

kev@kevin:~/桌面$ sudo ifconfig enp0s3 up

结果:

kev@kevin:~/桌面$ ifconfig
enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.100.74 netmask 255.255.252.0 broadcast 192.168.103.255
inet6 fe80::8e62:95fc:5e28:b47 prefixlen 64 scopeid 0x20<link>
ether 08:00:27:5e:05:7a txqueuelen 1000 (以太网)
RX packets 11745 bytes 2606989 (2.6 MB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1785 bytes 253998 (253.9 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (本地环回)
RX packets 1464 bytes 124561 (124.5 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1464 bytes 124561 (124.5 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

分类:

技术点:

相关文章: