Thread: Server Access
View Single Post
Old 13th August 2013
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,977
Default

The wc(1) program -l option just counts lines of output. If you want to count addresses you will have to parse the CIDR addresses and convert to them to address counts.

e.g: 10.10.10.0/24 is 254 addressable devices, plus two reserved addresses for network and broadcast. 0.0.0.0/0 is 4,294,967,294 addresses plus the two reserved addresses.
Reply With Quote