Questa linea è sbagliata:
openlog("vyatta-conntrack", "", LOG_USER);
Il "" dovrebbe sono stati un numero intero:
void openlog(const char *ident, int option, int facility);
Il numero intero dovrebbe essere una di queste costanti ORed insieme:
LOG_CONS Write directly to system console if there is
an error while sending to system logger.
LOG_NDELAY Open the connection immediately (normally, the
connection is opened when the first message is
logged).
LOG_NOWAIT Don't wait for child processes that may have
been created while logging the message. (The
GNU C library does not create a child process,
so this option has no effect on Linux.)
LOG_ODELAY The converse of LOG_NDELAY; opening of the
connection is delayed until syslog() is
called. (This is the default, and need not be
specified.)
LOG_PERROR (Not in POSIX.1-2001.) Print to stderr as
well.
LOG_PID Include PID with each message.
Prova ancora con qualcosa di più simile:
openlog("vyatta-conntrack", LOG_PID, LOG_USER);
Nota che la configurazione syslogd
potrebbe non essere impostato in modo da conservare i messaggi di livello di log LOG_INFO
. Prova a LOG_ALERT
oa qualcosa per il debug di questo problema: se funziona, torna a LOG_INFO
e configura il tuo syslogd
per conservare i messaggi di log che vuoi conservare. L'aggiunta di una linea come:
*.* /var/log/all_messages.log
farà il lavoro per rsyslogd(8)
. Assicurati di leggere la manpage rsyslog.conf(5)
se il tuo sistema utilizza rsyslogd(8)
. Se il sistema utilizza un daemon syslog diverso, controllare le manpage del sistema per i dettagli.
consultare http://www.linuxselfhelp.com/gnu/glibc/html_chapter/libc_18.html –