Daemon rewrite