Write log to file when called debugd