Debian11安装ifconfig
debian11默认没安装ifconfig命令,运行会报错:
root@debian115:/home/ice# ifconfig
bash: ifconfig:未找到命令
安装步骤如下:
apt install net-tools -y
#查找位置
whereis ifconfig
ifconfig: /usr/sbin/ifconfig /usr/share/man/man8/ifconfig.8.gz
#做个软链接:
ln -s /usr/bin/ifconifg /usr/sbin/ifconfig
后面就可以直接使用啦,当然也可以直接使用ip addr命令查看IP地址:
ice@debian115:~$ ip addr
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: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
link/ether 08:00:27:71:59:ab brd ff:ff:ff:ff:ff:ff
inet 192.168.188.8/24 brd 192.168.188.255 scope global dynamic enp0s3
valid_lft 411sec preferred_lft 411sec
inet6 fe80::a00:27ff:fe71:59ab/64 scope link
valid_lft forever preferred_lft forever
Tag标签:「ifconfig net-tools debian」更新时间:「2022-11-24 21:02:49」阅读次数:「895」