How to install SubNetCalc on Debian 9.0
To install SubNetCalc on Debian 9.0
SubNetCalc is a command line Subnet Address Calculator application that calculates IPV4 and IPV6 subnet addresses. It provides the information of binary value of IP, broadcast addresses, network addresses and the number of host. This tutorial explains the installation procedure of SubNetCalc on Debian 9.0.
Installation procedure
To begin with the installation procedure, run the nano command to open a configuration file named sources.list and enter the following contents in the file. Save and exit from the file.
root@debian:~# nano /etc/apt/sources.list
deb http://deb.debian.org/debian-security stable/updates main
deb-src http://deb.debian.org/debian-security stable/updates main
deb http://ftp.debian.org/debian stretch-backports main
deb-src http://ftp.debian.org/debian stretch-backports main
The required repository is added to the system. Now update the apt sources.list file by running the following command.
root@linuxhelppp:~# apt-get update
Ign:1 http://deb.debian.org/debian stable InRelease
Get:2 http://ftp.debian.org/debian stretch-backports InRelease [91.8 kB]
Hit:3 http://deb.debian.org/debian stable-updates InRelease
Get:4 http://deb.debian.org/debian-security stable/updates InRelease [62.9 kB]
Get:5 http://ftp.debian.org/debian stretch-backports/main Sources [86.5 kB]
Get:6 http://ftp.debian.org/debian stretch-backports/main amd64 Packages [137 kB]
Hit:7 http://deb.debian.org/debian stable Release
Get:8 http://ftp.debian.org/debian stretch-backports/main Translation-en [71.9 kB]
Get:10 http://deb.debian.org/debian-security stable/updates/main Sources [60.9 kB]
Get:11 http://deb.debian.org/debian-security stable/updates/main amd64 Packages [155 kB]
Get:12 http://deb.debian.org/debian-security stable/updates/main Translation-en [70.1 kB]
Fetched 736 kB in 2s (337 kB/s)
Reading package lists... Done
root@linuxhelppp:~#
The target system is updated with the required repository. Install the SubNetCalc package by executing the following command.
root@linuxhelppp:~# apt-get install subnetcalc
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libgtkspell0 libimage-magick-perl libimage-magick-q16-perl libmagick++-6.q16-7 libpotrace0
python-bs4 python-html5lib python-lxml python-scour python-webencodings
Use ' apt autoremove' to remove them.
The following additional packages will be installed:
iputils-tracepath whois
Recommended packages:
rsplib-tools
The following NEW packages will be installed:
iputils-tracepath subnetcalc whois
0 upgraded, 3 newly installed, 0 to remove and 33 not upgraded.
Need to get 133 kB of archives.
After this operation, 475 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
.
.
Setting up iputils-tracepath (3:20161105-1) ...
Processing triggers for man-db (2.7.6.1-2) ...
root@linuxhelppp:~#
Now use the command “ subnetcalc” in the terminal to calculate the subnet mask for any IP Address as follows.
root@linuxhelppp:~# subnetcalc 192.168.7.228/24
Address = 192.168.7.228
11000000 . 10101000 . 00000111 . 11100100
Network = 192.168.7.0 / 24
Netmask = 255.255.255.0
Broadcast = 192.168.7.255
Wildcard Mask = 0.0.0.255
Hosts Bits = 8
Max. Hosts = 254 (2^8 - 2)
Host Range = { 192.168.7.1 - 192.168.7.254 }
Properties =
- 192.168.7.228 is a HOST address in 192.168.7.0/24
- Class C
- Private
GeoIP Country = Unknown (??)
DNS Hostname = linuxhelppp
root@linuxhelppp:~#
The installation procedure of SubNetCalc on Debian 9.0.
Comments ( 0 )
No comments available