refactoring restart sh