I used bash sed to replace ip address in a group of files, i.e 10.1.1.x => 10.2.2.x-19:
file1: 10.1.1.29 => 10.2.2.10,
file2: 10.1.1.30 => 10.2.2.11,
file3: 10.1.1.31 => 10.2.2.12,
etc.
I almost managed with:
for file in ifcfg* ; do sed -e "s/10.1.1./10.2.2./" $file >tmp/$file ; done
but couldn't figure out how to calculate and replace the last address position (x => x-19)
it's probably really easy...