I have created one of the script however its else part is not working for me, any suggestion?
According to the else part it should give “Strings are not equal.” but it is always giving me “Strings are equal.” even the value in both the files are different.
vmware-toolbox-cmd -v > /tmp/output.txt
cat /tmp/output.txt | sed “s/.//g” > /tmp/output1.txt
head -c 10 /tmp/output1.txt > /tmp/output10.txt
systemctl restart vmtoolsd.service
vmware-toolbox-cmd -v > /tmp/output2.txt
cat /tmp/output2.txt | sed “s/.//g” > /tmp/output3.txt
head -c 10 /tmp/output3.txt > /tmp/output11.txt
VALUE= cat /tmp/output10.txt
VALUE1= cat /tmp/output11.txt
if [[ “$VALUE” -eq “$VALUE1” ]]; then
echo "Strings are equal."
echo "Strings are not equal."