Added logging for the daemon