[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SIGSEGV, Segmentation fault.

From: Jan-Henrik Haukeland
Subject: Re: SIGSEGV, Segmentation fault.
Date: 23 May 2003 15:41:19 +0200
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Civil Service)

I'm back in front of my machine and have tried to reproduce your bug-
report but I cannot. The monit code works fine on my RH 7.3 system.
Can others reproduce the SIGSEGV (core dump) Igor is reporting?

I have two theories why you get SIGSEGV:

1. The valgrind log you sent shows some interessting errors of this type:

==2912== Invalid read of size 1
==2912==    at 0x8053CC7: rtrim (util.c:201)
==2912==    by 0x8053C09: trim (util.c:164)
==2912==    by 0x806020F: yylex (l.l:230)
==2912==    by 0x805D115: yyparse (/usr/share/bison/bison.simple:573)
==2912==    Address 0x40C098FB is 1 bytes before a block of size 2 alloc'd
==2912==    at 0x4003AE15: malloc (vg_clientfuncs.c:100)
==2912==    by 0x8056F95: xmalloc (xmalloc.c:70)
==2912==    by 0x805707A: xstrdup (xmalloc.c:104)
==2912==    by 0x8060206: yylex (l.l:230)

  An invalid read is *not* good and may lead to heap coruption and
  then later to SIGSEGV. The problem is that I do not get this type of
  invalid read when I run monit v. 3.2 or the latest CVS with valgrind-1.9.4
  on my machine.

2. Something is not right with libc on your ALT Linux Master 2.2
   system. This theory is supported by your report from running monit
   with valgrind:

   > When i run monit through valgrind (memory debuger) monit running
   > without SIGSERV.

   The reason why monit may work with valgrind is because valgrind is
   replacing or intercepts call to the standard libs with it's own (to
   be able to check for leaks and errors). In other words running
   monit through valgrind means that monit is not directly calling


 1) Can you try running monit on another machine? Your machine may
 have a hardware memory error.

 2) Do you have access to another Linux OS for instance RedHat 7.x? If
 so does monit run okay on this OS? If it does, it could mean that
 there is a problem with libc on ALT Linux.

> Need you core dump ?

I do not know if I can use it but yes, it could be interessting to
try. Remember to compile monit with -g and *do not strip* the
binary. (If you run 'file monit' it should say "not stripped".) 

But before you send me the core file, please try the suggestions above

Jan-Henrik Haukeland

reply via email to

[Prev in Thread] Current Thread [Next in Thread]