Ajust the code, now error message log to syslog.