Write log to correct location.