I'm trying to write a script that will take as input a network and subnet mask and then ping each host.
I can get it to work fine for any class C address that only increments that last octet. However, I'm kind of stuck on how can I work through larger subnets. Once the last octet hits 255, it would need to increment the third octet and then reset the last to 0.
Any suggestions would be appreciated.
Thanks.
Jason