fixes in upgradev2 script

fixes update script.