Changed location of pidfile
Changed stop condition