Fix bugs in start.sh