[syslog-ng] Syslog file to Mysql

Michael Redinger Michael.Redinger at uibk.ac.at
Tue Apr 25 17:03:14 CEST 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

regarding adding information to the local log, you could add this to the
log destination definition, eg.:

destination d_local {
        file("/var/log/mylogfile.log" template("$DATE $HOST
[$FACILITY.$PRIORITY] $MSG\n"));
};

The result looks something like this:

Apr 25 16:59:09 myhost [local1.info] syslog message follows

Greetings,
Michael

Nick Carstensen wrote:
> Hello All,
> 
> Have a question I hope someone can help with.
> 
> Currently I have Syslog-ng running logging to a mysql db along with
> keeping files.  This is working well.  I have a situation where I can
> not log to the box directly.  I need to "pull" the logs to the central
> log server and import them into the db.  As syslogd and syslog-ng do
> not log all the needed fields by default like facility:level and year,
> when they are writing them local I need a way to add that to the file.
> 
> The second problems is how to import them to the db.  Is there any
> tool that will do this for me automatically?
> 
> Thanks for the assistance.
> _______________________________________________
> syslog-ng maillist  -  syslog-ng at lists.balabit.hu
> https://lists.balabit.hu/mailman/listinfo/syslog-ng
> Frequently asked questions at http://www.campin.net/syslog-ng/faq.html
> 
> 


- --
Michael Redinger
Zentraler Informatikdienst (Central IT Services)
Universitaet Innsbruck
Technikerstrasse 13                    Tel.: ++43 512 507 2335
6020 Innsbruck                         Fax.: ++43 512 507 2944
Austria                                Mail: Michael.Redinger at uibk.ac.at
BB98 D2FE 0F2C 2658 3780  3CB1 0FD7 A9D9 65C2 C11D
http://homepage.uibk.ac.at/~c102mr/mred-pubkey.asc
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iD8DBQFETjoyD9ep2WXCwR0RAoo+AKCKxQrcmNfDhCj5MPa+XzcSZbKKegCgpzti
+BssjXgkZbz0OATuDUajyoY=
=FrIc
-----END PGP SIGNATURE-----


More information about the syslog-ng mailing list