Make scheduler respond nicely to SIGTERM/SIGHUP and logging tweaks.