problem using sed for pattern matching

if abc.sh is
192.168.1.41

then the output that i get is v5c01

my code is
sed 's/192.168.1.4/v5c0/g
s/192.168.1.41/acc1/g' abc.sh 2>&1 | tee abc.sh

i want to find 192.168.1.4 and replace it with v5c0
and find 192.168.1.41 and replace it with acc1

and i want to do it using sed

Nearly there:

rm abc.sh.$$ 2>/dev/null
sed -e 's/192.168.1.4/v5c0/g' -e 's/192.168.1.41/acc1/g' abc.sh > abc.sh.$$ && \
cp abc.sh.$$ abc.sh && \
rm abc.sh.$$

sed 's/'^192.168.1.4$'/v5c0/g
s/192.168.1.41/acc1/g' abc.sh 2>&1 | tee abc.sh

it works with this

can you explain what your code does..mine seemed to be working yesterday but I see the same problem with it again today

The script removes the temporary file we are going to use, ensuring it is not a symbolic link pointing elsewhere, the the sed line does:
for every line in abc.sh it looks for
192.168.1.4 and replaces it with v5c0 however many times 192.168.1.4 occurs in each line, without the "g" only the first occurrence in each line would get replaced, and: sed looks for 192.168.1.41 and replaces and replaces it with acc1 however many times it repeated in each line,
the output from sed is put into a temporary file because normal text processing commands cannot write back to the file they are reading from without corrupting them, the temporary filename is abc.sh. with the PID of the script added on the end to make it unique, the ">" means that if abc.sh.$$ already existed it will get overwritten, if the sed does not fail (the && test) then the next command is run which is to copy the temporary file back to the original, copying the temporary file rather than moving it preserves the permissions of abc.sh, if the copy is successful then the temporary file is deleted.

thanks for the detailed explanation