Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using Red Hat 6.0 on a testing server. My code contains

syslog(pri,"(%u)%s",(unsigned int)getTid(),buf);

The log message in syslog looks like

(18597)DES=Recved confirmation of successful reception from

How can I configure syslog.conf to make log message priority show up in syslog?

getTid is the function I used to get the thread id; buf(const char*) is a variable I used for the log message, pri is the log level I set, e.g. LOG_ERR, LOG_DEBUG, &c.

When I ask about "log message priority," I mean LOG_ERR, LOG_INFO, &c.

share|improve this question

Your syslogd or sysklogd may not be able to do this. rsyslog can do that, see

share|improve this answer

I know I'm doing some gravedigging here, but for the record you can run sysklogd with -S to include a numeric facility and priority value. -SS includes the names.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.