Linux Mint

How to Install and Use Nmap on Linux Mint 21

As the name defines, the Network map (nmap) is used to manage networks in a system. It is an open-source utility used by network administrators to monitor network tasks.

The first release of Nmap was introduced in September 1997 by Gordon Lyon. Network administrators find this network scanning tool useful as it determines the network and handles it with security. Some of the features of Nmap are port scanning, exploit vulnerabilities in the network, version detection, host discovery, network inventory, handling services update scheduling and many more. Moreover, it is free, reliable, secure, flexible, and portable and has a well-documented man page for user’s help.

How to Install Nmap on Linux Mint 21

There are multiple ways to install Nmap on Linux Mint 21 system; some of the easy ways are mentioned:

1: Through apt

2: Through snap

i: How to Install Nmap Using apt

To install Nmap using apt, update the system’s repository first by making use of update command:

$ sudo apt update

Execute the mentioned command on terminal to let Nmap install on Linux Mint 21:

$ sudo apt install nmap

Now, check its version to confirm if system has installed the updated version of Nmap tool:

$ nmap --version

ii: How to Install Nmap Through snap

To install the Nmap tool through the snap software packaging repository, run the command written-below. Keep in mind snapd is compulsory to install any application using snap packaging repository.

To enable snap on Linux Mint, first remove the nosnap file from the system:

$ sudo rm /etc/apt/preferences.d/nosnap.pref

Then install snapd:

$ sudo apt install snapd

Now, get the Nmap using snap package through the command:

$ sudo snap install nmap

To get its version number, type:

$ nmap --version

How to Use Nmap on Linux Mint 21

Before getting start with Nmap command, let’s run help command to get better understanding:

$ nmap --help

There are few examples mentioned-below that shows the working of Nmap tool on Linux system:

Example 1: To scan IP address of our system, run the command:

$ nmap 192.168.64.128

Example 2: To scan OS information, type:

$ nmap –A 192.168.64.128

Example 3: With the help of given command, you can also display interfaces and routes information:

$ nmap --iflist

Example 4: To get updates about running services on host, type:

$ nmap -sV 192.168.64.128

How to Remove Nmap from Linux Mint 21

We will use the same approaches (mentioned above for installation process) to remove Nmap utility from Linux Mint 21 system.

i: How to Remove Nmap Using apt

To delete Nmap tool through apt packages, run the command given below:

$ sudo apt remove nmap

ii: How to Remove Nmap Using snap

To uninstall Nmap tool from Linux system with the help of snap, do it by executing the command:

$ sudo snap remove nmap

Conclusion

Nmap is an open-source, command-line tool that helps to manage system networks and its related issues. This utility is used by network administration to audit and monitor network tasks, network vulnerability and latency.

In this article, we have mentioned two approaches to install the Nmap command-line tool on Linux Mint i-e, apt and snap. We have also checked how to use it by executing different examples. Furthermore, the uninstallation process of Nmap comment is also present in this article using two ways.

About the author

Syeda Wardah Batool

I am a Software Engineer Graduate and Self Motivated Linux writer. I also love to read latest Linux books. Moreover, in my free time, i love to read books on Personal development.