Updated deply and init scripts - to support automatic start after failure.