bug-cfengine
[Top][All Lists]
Advanced

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

Re: Several Bugs in cfengine 2.0.4?


From: Andreas Poenicke
Subject: Re: Several Bugs in cfengine 2.0.4?
Date: Mon, 16 Sep 2002 19:25:00 +0200
User-agent: Mutt/1.2.5.1i

Hello Mark,

On Thu, Sep 12, 2002 at 10:58:47PM +0200, address@hidden wrote:

snip
> 
> If you are seeing a segfault, please try to run in gdb
> and when it stops, get a backtrace, so that I can see
> what is happening. You can also run with -d2 to find
> more info,


Sorry for the delay, here it is:

First I did a small change in the code, otherwise the segfault
happens on different places on different machines:

*** cfengine-2.0.4_rep/src/parse.c      Mon Sep 16 19:04:02 2002
--- cfengine-2.0.4/src/parse.c  Mon Aug 12 11:04:45 2002
***************
*** 278,286 ****
  free(CLASSBUFF);
  free(LINKFROM);
  free(LINKTO);
- 
- LINKTO=NULL;
- 
  free(ERROR);
  free(EXPR);
  free(RESTART); 
--- 278,283 ----

And here is the backtrace:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 20841)]
0x4018ae23 in bzero () from /lib/libc.so.6
(gdb) backtrace
#0  0x4018ae23 in bzero () from /lib/libc.so.6
#1  0x0807d015 in CompressPath (dest=0x0, src=0xbfff6b34 
"/opt/CF/ClusterNodes/cfengine-2.0.4/sbin/cfagent")
    at /home/src/Build/cfengine-2.0.4_rep/src/filenames.c:550
#2  0x08075532 in RelativeLink (from=0xbfff7b34 
"/opt/cfengine-2.0.4/sbin/cfagent", 
    to=0xbfff6b34 "/opt/CF/ClusterNodes/cfengine-2.0.4/sbin/cfagent", 
inclusions=0x0, exclusions=0x0, copy=0x0, nofile=0, ptr=0x819e5f0)
    at /home/src/Build/cfengine-2.0.4_rep/src/link.c:672
#3  0x08074ac0 in RecursiveLink (lp=0x819e5f0, from=0xbfff9bc4 
"/opt/cfengine-2.0.4/sbin", 
    to=0xbfff8bc4 "/opt/CF/ClusterNodes/cfengine-2.0.4/sbin", maxrecurse=-101) 
at /home/src/Build/cfengine-2.0.4_rep/src/link.c:397
#4  0x08074a48 in RecursiveLink (lp=0x819e5f0, from=0xbfffbc54 
"/opt/cfengine-2.0.4", to=0xbfffac54 "/opt/CF/ClusterNodes/cfengine-2.0.4", 
    maxrecurse=-100) at /home/src/Build/cfengine-2.0.4_rep/src/link.c:374
#5  0x08074a48 in RecursiveLink (lp=0x819e5f0, from=0xbfffdd4c "/opt", 
to=0xbfffcd4c "/opt/CF/ClusterNodes", maxrecurse=-99)
    at /home/src/Build/cfengine-2.0.4_rep/src/link.c:374
#6  0x0804fd01 in MakeChildLinks () at 
/home/src/Build/cfengine-2.0.4_rep/src/do.c:444
#7  0x0804d6c5 in DoTree (passes=2, info=0x80e9329 "Main Tree") at 
/home/src/Build/cfengine-2.0.4_rep/src/cfagent.c:1106
#8  0x0804b672 in main (argc=2, argv=0xbffffe04) at 
/home/src/Build/cfengine-2.0.4_rep/src/cfagent.c:168
(gdb) print LINKTO
$1 = 0x0


I still think it's the free(LINKTO) which gives rise to this
SIGSEGV.


The Linux distribution is debian-woody

node11:~# uname -a
Linux node11 2.4.18 #6 Tue Sep 3 14:28:30 CEST 2002 i686 unknown

node11:~# cfagent -V
GNU 2.0.4
Free Software Foundation 1994-2001
Donated by Mark Burgess, Faculty of Engineering,
Oslo University College, 0254 Oslo, Norway
This program is covered by the GNU Public License and may be
copied free of charge.  No warranty is implied.

node11:~# ldd `which cfagent`
        libcrypto.so.0.9.6 => /usr/lib/libcrypto.so.0.9.6 (0x40017000)
        libnss_nis.so.2 => /lib/libnss_nis.so.2 (0x400d7000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x400e1000)
        libm.so.6 => /lib/libm.so.6 (0x400f5000)
        libc.so.6 => /lib/libc.so.6 (0x40116000)
        libdl.so.2 => /lib/libdl.so.2 (0x40233000)
        libnsl.so.1 => /lib/libnsl.so.1 (0x40236000)
        libnss_files.so.2 => /lib/libnss_files.so.2 (0x4024a000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)

Statically linked against db-4.0.14 (otherwise I get conflicts with
libdb3.so.3.0.2 used by libnss_db-2.2.so)


Regards,
Andreas

(BTW, have you already analyzed the code with valgrind?)
-- 
Andreas Poenicke
Institut f"ur Theoretische Festk"orperphysik
Universit"at Karlsruhe, Wolfgang-Gaede-Str. 1, D-76128 Karlsruhe
e-mail: address@hidden




reply via email to

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