add timeout for restart