daemonize, signal handling, avoid chdir