Newsgroup: it.comp.os.linux.sys
Titolo: syslog

Ciao a tutto il NG,
ho 5 macchine su linux  web-server e vorrei importare i log su un'altra
macchina.
 Adesso in locale ho attivato il logrotate settimanale e che comprimma i
file dopo la rotazione,  ma cmq dopo un certo periodo anche i access_log.gz
pesano sulla macchina e vorrei ridirigerli su un'altra.
Ho letto che dovrei configurare il demone syslog per ottenere questo.
Mi date un link oppure mi spiegate come poter ottenere tale risultato?
Ciao
Giuseppe


da man syslog
SUPPORT FOR REMOTE LOGGING
       These modifications provide network support to the syslogd facility. Network
support means that messages
       can be forwarded from one node running syslogd to another node running
syslogd where they will be actually
       logged to a disk file.
       To enable this you have to specify the -r option on the command line. The
default behavior is that sys­
       logd won't listen to the network.
       The strategy is to have syslogd listen on a unix domain socket for locally
generated log messages. This
       behavior will allow syslogd to inter-operate with the syslog found in the
standard C library. At the same
       time syslogd listens on the standard syslog port for messages forwarded from
other hosts. To have this
       work correctly the services(5) files (typically found in /etc) must have the
following entry:
                   syslog 514/udp
       If this entry is missing syslogd neither can receive remote messages nor
send them, because the UDP port
       cant be opened. Instead syslogd will die immediately, blowing out an error
message.
       To cause messages to be forwarded to another host replace the normal file
line in the syslog.conf file
       with the name of the host to which the messages is to be sent prepended with
an @.
              For example, to forward ALL messages to a remote host use the following
syslog.conf entry:
                   # Sample syslogd configuration file to
                   # messages to a remote host forward all.
                   *.* @hostname
              To forward all kernel messages to a remote host the configuration file would
be as follows:
                   # Sample configuration file to forward all kernel
                   # messages to a remote host.
                   kern.* @hostname
       If the remote hostname cannot be resolved at startup, because the
name-server might not be accessible (it
       may be started after syslogd) you don't have to worry. Syslogd will retry to
resolve the name ten times
       and then complain. Another possibility to avoid this is to place the
hostname in /etc/hosts.
       With normal syslogds you would get syslog-loops if you send out messages
that were received from a remote
       host to the same host (or more complicated to a third host that sends it
back to the first one, and so
       on). In my domain (Infodrom Oldenburg) we accidently got one and our disks
filled up with the same single
       message. :-(
       To avoid this in further times no messages that were received from a remote
host are sent out to another
       (or the same) remote host anymore. If there are scenarios where this doesn't
make sense, please drop me
       (Joey) a line.
       If the remote host is located in the same domain as the host, syslogd is
running on, only the simple host­
       name will be logged instead of the whole fqdn.
       In a local network you may provide a central log server to have all the
important information kept on one
       machine. If the network consists of different domains you don't have to
complain about logging fully
       qualified names instead of simple hostnames. You may want to use the
strip-domain feature -s of this
       server. You can tell the syslogd to strip off several domains other than the
one the server is located in
       and only log simple hostnames.
       Using the -l option there's also a possibility to define single hosts as
local machines. This, too,
       results in logging only their simple hostnames and not the fqdns.
       The UDP socket used to forward messages to remote hosts or to receive
messages from them is only opened
       when it is needed. In releases prior to 1.3-23 it was opened every time but
not opened for reading or
       forwarding respectively.
--------------------------------
Inviato via 
http://usenet.libero.it


Io lascerei syslogd scrivere sul disco locale e sposterei i access_log.gz...
Con scp oppure con un mount NFS. Molto piu' facile IMHO che riconfigurare
syslogd.
Ciao,
-- 
       Roberto Divia`             Love at first sight is one of the greatest
       =============             labour-saving devices the world has ever seen.
Mailbox: C02110                 CERN-European Organization for Nuclear Research
E-mail: 
Robert...@cern.ch
           CH-1211 GENEVE 23, Switzerland