I am trying to separate the ip/block address and place the ip in a variable and the block in another. This is what I have so far.
#!/bin/bash
ipblock="100.100.40.160/29"
block="$(basename $ipblock)"
#ipaddress="100.100.40.160"
echo "block=\"$block\""
#echo "address=\"$ipaddress\""
I need the ip address equation so that the results are ...
block="29"
address="100.100.40.160"