Install libsys-hostip-perl by entering the following commands in the terminal:
sudo apt update sudo apt install libsys-hostip-perl
Description:
Perl module to determine local machine's IP address
Sys::HostIP determines the IP address of the local machine by parsing ifconfig(8) (ipconfig on Win32/Cygwin) output. . It has been tested on a wide range of systems including Irix, OpenBSD, FreeBSD, NetBSD, Solaris, Linux, OSX, Win32, and Cygwin. . For convenience, Sys::HostIP offers both object-oriented and functional interfaces.
Homepage: https://metacpan.org/release/Sys-HostIP
Version: 2.000-1
Section: universe/perl