change mode of daemon script