redirecting stdout and stderr before daemonizing
Redirecting stdout and stderr to logs