Bugzilla – Bug 137128
amanda-2.4.5-2: SIGSEGV in amadmin <CONFNAME> due (regression from 9.3)
Last modified: 2006-07-31 09:21:38 UTC
running "amadmin FullBacks due" causes a segmentation fault on my machine. amadmin at that time has read disklist, tapelist and configuration, and the crash happens here: Program received signal SIGSEGV, Segmentation fault. due (argc=3, argv=0x1c) at amadmin.c:747 747 for(dp = diskqp->head; dp != NULL; dp = dp->next) (gdb) bt full #0 due (argc=3, argv=0x1c) at amadmin.c:747 dp = (disk_t *) 0xfffffffe #1 0x0804a4bc in main (argc=3, argv=0xbfbbeb44) at amadmin.c:169 fd = <value optimized out> conf_diskfile = <value optimized out> conf_infofile = <value optimized out> conffile = <value optimized out> valgrind confirms this: ==22742== Invalid read of size 4 ==22742== at 0x804B7A0: due (amadmin.c:747) ==22742== by 0x804A4BB: main (amadmin.c:169) ==22742== Address 0x6 is not stack'd, malloc'd or (recently) free'd ==22742== ==22742== Process terminating with default action of signal 11 (SIGSEGV): dumping core ==22742== Access not within mapped region at address 0x6 ==22742== at 0x804B7A0: due (amadmin.c:747) ==22742== by 0x804A4BB: main (amadmin.c:169) ==22742== ==22742==
I've tested the current 2.4.5p1-20051218 snapshot and built it as RPM <http://home.pages.de/~mandree/suse-10.0-i586.de/>, which does not have the bug.
I tested affected file and compared it with newer version. Only minor change were here and not in important parts. It is possible for you to test patched rpm ?
Yes, I can test patched RPMs.
Great, 10.0 i386 ? Or diferent hardware/distro?
10.0 i386.
Could you please check log (with SIGSEGV version) for string "could not load disklist could not load disklist" ? I created patched version of amanda. Should be here http://beta.suse.com/private/pnemec/ (in 15 minutes - mirroring) Please try it and post gdb or valgrind output here. Thank you
I've installed it, and this is what I get: amanda@merlin:~> valgrind --quiet --num-callers=16 amadmin FullBacks due Due in 5 days: merlin:/etc ==15437== Invalid read of size 4 ==15437== at 0x804B4E8: due (in /usr/sbin/amadmin) ==15437== by 0x804EA1B: main (in /usr/sbin/amadmin) ==15437== Address 0x6 is not stack'd, malloc'd or (recently) free'd ==15437== ==15437== Process terminating with default action of signal 11 (SIGSEGV) ==15437== Access not within mapped region at address 0x6 ==15437== at 0x804B4E8: due (in /usr/sbin/amadmin) ==15437== by 0x804EA1B: main (in /usr/sbin/amadmin) Segmentation fault If this does not help, I'll try to recompile with -ggdb3 next week.
Nadvornik find some wrong code. Could you please test fixed package? http://beta.suse.com/private/pnemec/
I somehow missed the package, there is no amanda at the URL given in comment #8.
I already delete it, because i thought you are not responding anymore. I put file back, so you can test it. Thank you for your concern.
OK, I tried 2.4.5-2 again, it crashed. I then updated to your amanda-2.4.5-10, which fixes this problem for me.
Great, i am closing this bug so. Thanks for testing.