IPCALC(1) OpenBSD Reference Manual IPCALC(1) NAME ipcalc - calculate IPv4 network sizes, masks and broadcasts SYNOPSIS ipcalc address / netmask ipcalc -s mask1,mask2,... [-v] address / netmask ipcalc -r [-v] address : address ipcalc -n netmask DESCRIPTION ipcalc is a small tool that operates on IPv4 networks. It can operate in one of four modes: network describing, netmask describing, finding or splitting. When called without any flags, ipcalc operates in network de- scribing mode. Options are exclusive except for -v and are as follows: -s Enable network splitting, the argument is a list of integers sep- arated by commas. Each integer represents a number of IPs. For each integer, ipcalc will try to find a network that is a sub network of the main network and that can contain the number of IPs specified. -r Enable network finding. Ipcalc will find as few networks as pos- sible between the two addresses specified. -n Netmask describing. Ipcalc will print the netmask in all formats it knows. -v Operates only on network finding and splitting in which case it prints detailed information for each network. NETMASKS Netmasks can be specified in one of three ways: prefix length An integer between 1 and 32 inclusive which indicates the numbers of bits set in the address. quad-dotted address A traditionnal IPv4 address such as 255.255.255.0 hex notation address An address in hex notation such as 0xffffff00 OpenBSD 4.0 October 19, 2006 1