Make sure lockfile errors happen before daemonizing. refs #2688