1

i am trying to replace $old string with $new string in file where:

old=ESX_10.1.1.1\@11.11.11.11
new=host_15_11_0_111.static

I am using sed command:

sed i "s/${old}/${new}/g" /filename

but it does not replace the word and also not shows any error. I have tried it with many ways, like replacing:

sed i "s,${old},${new},g" /filename

and

sed i "s=${old}=${new}=g" /filename

but it does not work. Help me to solve this

John1024
  • 74,655
Rockey
  • 11