Docker 构建 CentOS 7.8.2003 安装ifco

2020-06-12  本文已影响0人  孙瑞锴

1. 借鉴

CentOS 7安装 ifconfig 管理命令

2. 开始

缘起

ifconfig
bash: ifconfig: command not found
yum install ifconfig
Loaded plugins: fastestmirror, ovl
Loading mirror speeds from cached hostfile
 * base: mirrors.aliyun.com
 * extras: mirrors.bfsu.edu.cn
 * updates: mirror.bit.edu.cn
No package ifconfig available.
Error: Nothing to do
yum search ifconfig
Loaded plugins: fastestmirror, ovl
Loading mirror speeds from cached hostfile
 * base: mirrors.aliyun.com
 * extras: mirrors.bfsu.edu.cn
 * updates: mirror.bit.edu.cn
================================================== Matched: ifconfig ============================================
net-tools.x86_64 : Basic networking tools

解决

yum install net-tools.x86_64
ifconfig
eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 172.17.0.2  netmask 255.255.0.0  broadcast 172.17.255.255
        ether 02:42:ac:11:00:02  txqueuelen 0  (Ethernet)
        RX packets 18553  bytes 26721726 (25.4 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 8741  bytes 479526 (468.2 KiB)
        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
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

3. 大功告成

上一篇下一篇

猜你喜欢

热点阅读