Menu

#9 'command' scripts make metalog stall

closed-fixed
nobody
None
5
2007-01-28
2006-01-01
dothebart
No

if i add a script to be executed, metalog will block
all proceses actualy on write to the syslog pipe.
so just do call a command that does /bin/sleep 60, and
try to do an 'su - ' and if your system adds an entry
to syslog for processing you did su, your su process
will stall for 60 seconds.

as i.e. ssh commands allso will behave like that, your
server will become unreachable and any program
utilizing the syslog engine will halt.
If such a program does like that, you're bound.

I think, metalg should cmpletely fork off the process,
and put the output to another syslog pipe....

Discussion

  • Mike Frysinger

    Mike Frysinger - 2007-01-01

    Logged In: YES
    user_id=114429
    Originator: NO

    no, the problem here has nothing to do with the way forks are handled

    metalog uses non-safe functions in its signal handler (like localtime() and syslog()) and the hang here comes from libc mutexes deadlocked

    so all of metalog's logging from signal handlers needs to be rewritten / rethought

     
  • Mike Frysinger

    Mike Frysinger - 2007-01-28
    • status: open --> closed-fixed
     
  • Mike Frysinger

    Mike Frysinger - 2007-01-28

    Logged In: YES
    user_id=114429
    Originator: NO

    0.8-rc2 is out with this fixed

     

Log in to post a comment.