Windows
Linux
Networking
Windows nmap (Nmap for Windows) equivalent in Linux
Scans networks and hosts to discover open ports, running services, OS versions, and security issues.
Windows
→
nmap (Nmap for Windows)
Linux equivalents
nmap
nmap
nmap
Overview
What this command does
Scans networks and hosts to discover open ports, running services, OS versions, and security issues.
Migration tip:
nmap is the gold standard for network scanning. A simple nmap hostname shows open ports. Add -sV to detect service versions and -sn to just find live hosts.Practical tasks
Common use cases
Network port scanner and host discovery
Scans networks and hosts to discover open ports, running services, OS versions, and security issues.
nmap hostname
Scan common ports on a host
nmap -sV hostname
Detect service versions
nmap -sn 192.168.1.0/24
Ping scan — find all live hosts
Ready to run
Copyable Linux commands
Review paths, device names, package names and permissions before running any command.
sudo apt install nmap
nmap 192.168.1.1
nmap -sn 192.168.1.0/24
nmap -sV target.example.com
Walkthrough
Examples with explanations
# Install:
sudo apt install nmap
# Basic port scan:
nmap 192.168.1.1
# Discover all live hosts:
nmap -sn 192.168.1.0/24
# Full scan with service versions:
nmap -sV target.example.com
Reference
Common options and variations
| Command or option | Use |
|---|---|
nmap hostname | Scan common ports on a host |
nmap -sV hostname | Detect service versions |
nmap -sn 192.168.1.0/24 | Ping scan — find all live hosts |
nmap -p 1-65535 hostname | Scan all 65535 ports |
nmap -A hostname | Aggressive: OS, versions, scripts |
Distro differences
Debian/Ubuntu vs Fedora vs Arch
This command is the same on Debian/Ubuntu, Fedora and Arch Linux when the relevant tool is installed.
| Distribution | Package manager / base | Equivalent command | Difference to notice |
|---|---|---|---|
| Debian/Ubuntu | same command | nmap |
Same command on this distribution. |
| Fedora | same command | nmap |
Same command on this distribution. |
| Arch | same command | nmap |
Same command on this distribution. |
Important
What to watch out for
Only scan networks and hosts you own or have explicit permission to scan. Unauthorised scanning may be illegal.
Keep learning