r/linuxdev • • Dec 10 '15

syslog vs. rsyslog

Searching the internet for the difference between syslog and rsyslog gives quite a few results geared towards system admins, not for application developers. So, I'm coming to you people for help!

Setup: I am using Ubuntu 14.04 for my applications (building and running natively). When running this command:

ps -aux | grep syslog

I see these two processing running:

/usr/bin/pulseaudio --start --log-target=syslog
rsyslogd

Is my system using rsyslog instead of syslog? Can one/ should one run syslog and rsyslog at the same time? It still looks like my application logs are being written to /var/log/syslog.

From an application running on my system is an openlog(...) system call opening rsyslog instead of syslog? How do I know this?

As you can tell I'm kind of a noob so any extra info you can think of would be appreciated.

3 Upvotes

4 comments sorted by

View all comments

Show parent comment

2

u/ElGringoFlicka Dec 10 '15

Nice explanation. So in my case rsyslog is the daemon running. Is that the default on Ubuntu 14.04?

1

u/lordvadr Dec 10 '15

rsyslog has been the default on a number of distros for a long time--but I only really keep track of CentOS and Fedora. I'm sure you can start a fight somewhere about which one is better, but rsyslog has literally hundreds (that might be an exaggeration) of features the old BSD syslogd doesn't.

1

u/lordvadr Dec 10 '15

To answer your question, yes, rsyslogd is the one running. What you're seeing from pulseaudio is just an option to tell it to use the syslog mechanism. It supports several logging mechanism (man pulseaudio) such as stderr, it's own log file, etc.