Table of Contents
In this article, we will see how to install libdnet package on Ubuntu 20.04 LTS (Focal Fossa). libdnet is a free and open source portable interface for low level networking routines including network address manipulation, kernel arp cache and route table lookup and manipulation, network firewalling (IP filter, ipfw, ipchains, pf, ...), network interface lookup and manipulation, raw IP packet and Ethernet frame, and data transmission. libdnet is used by many applications to accomplish different tasks. It is quite easy to install and use on almost all the famous platforms. Here we will see the steps to install libdnet package on Ubuntu 20.04 LTS (Focal Fossa).
How to Install libdnet package on Ubuntu 20.04 LTS (Focal Fossa)
Also Read: How to Install libpcap-dev package on Ubuntu 20.04 LTS (Focal Fossa)
Step 1: Prerequisites
a) You should have a running Ubuntu 20.04 LTS
Server.
b) You should have sudo
or root
access to run privileged commands.
c) You should have apt
or apt-get
utility available in your Server.
Step 2: Update Your Server
Before installing libdnet package, it is mandatory to check and install all the latest available versions from default Ubuntu repo by using sudo apt update && sudo apt upgrade
command as shown below.
cyberithub@ubuntu:~$ sudo apt update && sudo apt upgrade
Hit:1 https://d3nt0h4h6pmmc4.cloudfront.net/ubuntu focal InRelease
Hit:2 http://ppa.launchpad.net/flatpak/stable/ubuntu focal InRelease
Hit:3 http://security.ubuntu.com/ubuntu focal-security InRelease
Hit:4 https://dl.winehq.org/wine-builds/ubuntu focal InRelease
Hit:5 https://dl.google.com/linux/chrome/deb stable InRelease
Hit:6 http://in.archive.ubuntu.com/ubuntu focal InRelease
Hit:7 http://ppa.launchpad.net/gencfsm/ppa/ubuntu focal InRelease
Hit:8 http://in.archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:9 http://ppa.launchpad.net/juju/stable/ubuntu focal InRelease
Hit:10 http://in.archive.ubuntu.com/ubuntu focal-backports InRelease
Hit:11 https://download.sublimetext.com apt/stable/ InRelease
Hit:12 https://ngrok-agent.s3.amazonaws.com buster InRelease
Hit:13 http://ppa.launchpad.net/libreoffice/ppa/ubuntu focal InRelease
Hit:14 https://ftp.postgresql.org/pub/pgadmin/pgadmin4/apt/focal pgadmin4 InRelease
Hit:15 http://ppa.launchpad.net/mojo-maintainers/ppa/ubuntu focal InRelease
Hit:16 http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu focal InRelease
Reading package lists... Done
Building dependency tree
Reading state information... Done
2 packages can be upgraded. Run 'apt list --upgradable' to see them.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
Get more security updates through Ubuntu Pro with 'esm-apps' enabled:
node-hosted-git-info python2.7-minimal python2.7 node-tar libgsasl7
libopusfile0 libjs-jquery-ui libsdl2-2.0-0 libsdl2-2.0-0
libpython2.7-minimal libpython2.7-stdlib
Learn more about Ubuntu Pro at https://ubuntu.com/pro
The following packages have been kept back:
xdg-desktop-portal xdg-desktop-portal-gtk
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
Step 3: Install libdnet package
In the next step, you can install libdnet package from default Ubuntu repo by using sudo apt install libdnet
command as shown below. This will download and install the package along with all its required dependencies.
cyberithub@ubuntu:~$ sudo apt install libdnet Reading package lists... Done Building dependency tree Reading state information... Done Suggested packages: dnet-common The following NEW packages will be installed: libdnet 0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded. Need to get 60.1 kB of archives. After this operation, 253 kB of additional disk space will be used. Get:1 http://in.archive.ubuntu.com/ubuntu focal/universe amd64 libdnet amd64 2.65build2 [60.1 kB] Fetched 60.1 kB in 1s (59.7 kB/s) Selecting previously unselected package libdnet:amd64. (Reading database ... 258301 files and directories currently installed.) Preparing to unpack .../libdnet_2.65build2_amd64.deb ... Unpacking libdnet:amd64 (2.65build2) ... Setting up libdnet:amd64 (2.65build2) ... Processing triggers for libc-bin (2.31-0ubuntu9.9) ...
Similarly to install libdnet-dev
package, you have to run sudo apt install libdnet-dev
command as shown below. This will also download and install the package along with all its dependencies from default Ubuntu repo.
cyberithub@ubuntu:~$ sudo apt install libdnet-dev Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: libdnet-dev 0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded. Need to get 297 kB of archives. After this operation, 743 kB of additional disk space will be used. Get:1 http://in.archive.ubuntu.com/ubuntu focal/universe amd64 libdnet-dev amd64 2.65build2 [297 kB] Fetched 297 kB in 2s (184 kB/s) Selecting previously unselected package libdnet-dev:amd64. (Reading database ... 258482 files and directories currently installed.) Preparing to unpack .../libdnet-dev_2.65build2_amd64.deb ... Unpacking libdnet-dev:amd64 (2.65build2) ... Setting up libdnet-dev:amd64 (2.65build2) ... Processing triggers for man-db (2.9.1-1) ...
Step 4: Verify Installation
After successful installation, you can verify the installed files path of libdnet
package by using dpkg -L libdnet
command as shown below.
cyberithub@ubuntu:~$ dpkg -L libdnet
/.
/usr
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/lib/x86_64-linux-gnu/libdnet-dap.so.2.46.0
/usr/lib/x86_64-linux-gnu/libdnet.so.2.43.2
/usr/lib/x86_64-linux-gnu/libdnet_daemon.so.2.43.1
/usr/lib/x86_64-linux-gnu/librms.so.2.43.0
/usr/share
/usr/share/doc
/usr/share/doc/libdnet
/usr/share/doc/libdnet/changelog.gz
/usr/share/doc/libdnet/copyright
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/libdnet
/usr/lib/x86_64-linux-gnu/libdnet-dap.so.2
/usr/lib/x86_64-linux-gnu/libdnet.so.2
/usr/lib/x86_64-linux-gnu/libdnet_daemon.so.2
/usr/lib/x86_64-linux-gnu/librms.so.2
Likewise, to verify the installed files path of libdnet-dev
package, you need to run dpkg -L libdnet-dev
command as shown below.
cyberithub@ubuntu:~$ dpkg -L libdnet-dev
/.
/usr
/usr/include
/usr/include/convert_vax_data.h
/usr/include/fabdef.h
/usr/include/netdnet
/usr/include/netdnet/dn.h
/usr/include/netdnet/dnetdb.h
/usr/include/rabdef.h
/usr/include/rms.h
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/lib/x86_64-linux-gnu/libdnet-dap.a
/usr/lib/x86_64-linux-gnu/libdnet.a
/usr/lib/x86_64-linux-gnu/libdnet_daemon.a
/usr/lib/x86_64-linux-gnu/librms.a
/usr/lib/x86_64-linux-gnu/libvaxdata.a
/usr/share
................................................