Improve restart script