这似乎是一个常见问题,但我认为我的问题可能是独一无二的,因为我找不到 ifconfig。我试图遵循这个教程和其他。我在 Ubuntu 18.04 和 Windows 10 上。当我输入
ifcongig
这就是我所看到的。
Command 'ifconfig' not found, but can be installed with: sudo apt install net-tools
听起来好像我需要重新安装,这次要包含这些默认程序,这样我才能使用 wifi。有人对我如何获取这些默认应用程序有什么建议吗?
答案1
在 Ubuntu 18.04 及更高版本中,ifconfig
被取代为:
ip addr show
以下是示例输出:
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp0s25: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc fq_codel state DOWN group default qlen 1000
link/ether xx:f7:28:ae:83:xx brd ff:ff:ff:ff:ff:ff
3: wlp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether xx:c5:d4:0e:64:xx brd ff:ff:ff:ff:ff:ff
inet 192.168.0.xx/24 brd 192.168.0.255 scope global dynamic noprefixroute wlp3s0
valid_lft 163355sec preferred_lft 163355sec
inet6 2600:1700:5aa0:839:3463:39f0:7595:xxxx/64 scope global temporary dynamic
valid_lft 595357sec preferred_lft 76778sec
inet6 2600:1700:5aa0:839:ed1a:bd8d:e5a:xxxx/64 scope global dynamic mngtmpaddr noprefixroute
valid_lft 2591685sec preferred_lft 604485sec
inet6 fe80::3f3e:a058:dc6d:df91/64 scope link noprefixroute
valid_lft forever preferred_lft forever
以下是一份实用指南:https://p5r.uk/blog/2010/ifconfig-ip-comparison.html