ipcalc

Are you like me and forever forgetting what a /xx network is (like a /32)? I found a cool tool called ipcalc which, when given an IP address and a netmask, shows all the information about that IP and network. You can also pass in an IP/xx style for the same information.

mlambie@prime:~$ ipcalc 192.168.0.1 255.255.255.0

Address: 192.168.0.1 11000000.10101000.00000000 .00000001
Netmask: 255.255.255.0 = 24 11111111.11111111.11111111 .00000000
Wildcard: 0.0.0.255 00000000.00000000.00000000 .11111111
=>
Network: 192.168.0.0/24 11000000.10101000.00000000 .00000000 (Class C)
Broadcast: 192.168.0.255 11000000.10101000.00000000 .11111111
HostMin: 192.168.0.1 11000000.10101000.00000000 .00000001
HostMax: 192.168.0.254 11000000.10101000.00000000 .11111110
Hosts/Net: 254 (Private Internet RFC 1918)

The output is actually coloured too, if your teminal supports it (and my stylesheet doesn't :) So, never again will I get my /xx's mixed up.

1 Comment so far

  1. Hale on June 28th, 2004

    A real nerd can do this in his sleep, he don’t need no steeeenking program ;)