Call me old fashioned, but I still prefer using ifconfig command. It's not as cool as the ip command found in recent Linux distros, but familiar and universal enough to be found pretty much everywhere else. This post shows how to install packages to make ifconfig working again.
/sbin/ifconfig: no such file or directory
Yep, that's the error message I'm seeing on most recent distros. This simply means that ifconfig is no longer a core functionality installed with a base OS. You can still get it by installing net-tools package in your environment.
greys@debian9:~$ ifconfig -a -su: /sbin/ifconfig: No such file or directory
Install net-tools package for ifconfig and more
Simple enough step (I just know and remember that ifconfig is in net-tools package):
greys@debian9:~$ su - Password:
And now we install the net-tools package:
root@debian9:~# apt install net-tools Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: net-tools 0 upgraded, 1 newly installed, 0 to remove and 154 not upgraded. Need to get 248 kB of archives. After this operation, 963 kB of additional disk space will be used. Get:1 http://ftp.ie.debian.org/debian stretch/main amd64 net-tools amd64 1.60+git20161116.90da8a0-1 [248 kB] Fetched 248 kB in 0s (601 kB/s) Selecting previously unselected package net-tools. (Reading database ... 128276 files and directories currently installed.) Preparing to unpack .../net-tools_1.60+git20161116.90da8a0-1_amd64.deb ... Unpacking net-tools (1.60+git20161116.90da8a0-1) ... Processing triggers for man-db (184.108.40.206-2) ... Setting up net-tools (1.60+git20161116.90da8a0-1) ...
That's it, ifconfig should start working right away:
root@debian9:~# ifconfig -a enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 192.168.X.Y netmask 255.255.255.0 broadcast 192.168.1.255 inet6 fe80::a00:27ff:febe:8a41 prefixlen 64 scopeid 0x20<link> ether 08:00:27:be:8a:41 txqueuelen 1000 (Ethernet) RX packets 94337 bytes 138887593 (132.4 MiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 31380 bytes 2338487 (2.2 MiB) 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 1 (Local Loopback) RX packets 1154 bytes 292002 (285.1 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 1154 bytes 292002 (285.1 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0