ensure stopping when restart