[syslog-ng] GThread error when starting syslog-ng

Balazs Scheidler bazsi at balabit.hu
Fri Apr 17 12:06:09 CEST 2009


On Thu, 2009-04-16 at 16:49 -0600, Scott Foster wrote:
> I have installed syslog-ng on a CentOS v5.2 server.  I have also
> installed the required dependency rpms.  I am not using any database
> server for this (just plain old logging).  When I attempt to start the
> syslog-ng service I get the below error:
> 
>  
> 
> ---------------------------------------------------------
> 
> [root at it188v ~]# service syslog-ng start
> 
> Starting syslog-ng:
> 
> GThread-ERROR **: file gthread-posix.c: line 140 (): error 'Operation
> not permitted' during 'pthread_getschedparam (pthread_self(), &policy,
> &sched)'
> 
> aborting...
> 
> /bin/bash: line 1:  8888 Aborted                 /sbin/syslog-ng
> 
>                                                            [FAILED]
> 
> [root at it188v ~]#
> 
> ---------------------------------------------------------
> 
>  
> 
> I’ve Googled anything about gthread and can’t find anything useful.
> Any yes I am a newbie to Linux.
> 

This is probably related to your SELinux policy, which does not allow
syslog-ng  get the scheduler parameters. Please look up the SELinux
error in your kernel log (if you don't have a logger running, you can
get to those with "dmesg"), you could perhaps also disable SELinux, or
the syslog-ng related SELinux settings, as the SELinux policy shipped
with CentOS is not compatible with the new syslog-ng. The old one didn't
use threads, the new one does.

You can disable SELinux for syslog-ng by changing the labels for the
syslog-ng binary:

ls -lZ /sbin/syslog-ng

To confirm that it is really SELinux that prevents syslog-ng from doing
pthread_getschedparam(), you could copy the syslog-ng binary to a
different location and change its label using setfilecon.


-- 
Bazsi






More information about the syslog-ng mailing list