Bug 105635 - amanda 2.5.1p1,1 : amfetchdump segmentation fault
Summary: amanda 2.5.1p1,1 : amfetchdump segmentation fault
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Jun Kuriyama
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-11-17 13:40 UTC by Andy Hilker
Modified: 2006-11-29 01:10 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andy Hilker 2006-11-17 13:40:01 UTC
Amrecover and amdump works, but amfetchdump not since update to 2.5.1p1,1.
This happens on several amanda installations and I got a report to my mailing list posting from another user.

-- snip --
$ amfetchdump -a -c CONFIG HOST da0s1e 20061108 1
Scanning /home/amanda/hold...
1 tape(s) needed for restoration
sh: segmentation fault (core dumped)  amfetchdump -a -c CONFIG HOST da0s1e 20061108 1
-- snip --

I believe it is not an amanda bug, because the core file with strings gives me something like:

Shared object "nss_dns.so.1" not found, required by "amfetchdump"

How-To-Repeat: 1. Install amanda 2.5.1p1,1 from ports and configure it.
2. run an amdump to have some dumps
3. the above amfetchdump to get the dump, it will core dump
Comment 1 Pav Lucistnik freebsd_committer 2006-11-21 20:18:02 UTC
Responsible Changed
From-To: freebsd-ports-bugs->kuriyama

Amanda ports are maintained by kuriyama.
Comment 2 ah 2006-11-28 21:37:16 UTC
I received a patch from Jean-Louis Martineau / zmanda.com . I have
tested it and the problem was solved.

You (Jean-Louis Martineau) wrote:
> Andy
>
> amfetchdump is broken in 2.5.1p1 and 2.5.1p2.
>
> Could you try the attached patch?
>
> Jean-Louis

diff -u -r --show-c-function --new-file --exclude-from=amanda.diff amanda-2.5.1p2.new/restore-src/restore.c amanda-2.5.1p2.new.amfetchdump/restore-src/restore.c
--- amanda-2.5.1p2.new/restore-src/restore.c    2006-10-03 07:35:48.000000000 -0400
+++ amanda-2.5.1p2.new.amfetchdump/restore-src/restore.c        2006-11-28 14:24:28.000000000 -0500
@@ -1692,14 +1692,14 @@ search_tapes(
     seentapes_t *seentapes = NULL;
     int ret;

+    if(!prompt_out) prompt_out = stderr;
+
     dbprintf(("search_tapes(prompt_out=%d, prompt_in=%d,  use_changer=%d, "
              "tapelist=%p, "
              "match_list=%p, flags=%p, features=%p)\n",
              fileno(prompt_out), fileno(prompt_in), use_changer, tapelist,
              match_list, flags, their_features));

-    if(!prompt_out) prompt_out = stderr;
-
     if(flags->blocksize)
        blocksize = (size_t)flags->blocksize;
     else if(blocksize == (size_t)SSIZE_MAX)
Comment 3 dfilter service freebsd_committer 2006-11-29 01:05:30 UTC
kuriyama    2006-11-29 01:05:24 UTC

  FreeBSD ports repository

  Modified files:
    misc/amanda-server   Makefile distinfo 
    misc/amanda-server/files patch-amanda.conf.5 
  Added files:
    misc/amanda-server/files patch-restore.c 
  Log:
  - Upgrade to 2.5.1p2.
  - Add a patch to fix amfetchdump to dump core [1].
  - Fix GNUTAR, DUMP_SNAPSHOT options handling [2].
  
  Submitted by:   Andy Hilker <ah@cryptobank.de> [1][2]
  PR:             ports/105635 [1], ports/105942 [2]
  
  Revision  Changes    Path
  1.94      +3 -3      ports/misc/amanda-server/Makefile
  1.28      +3 -3      ports/misc/amanda-server/distinfo
  1.2       +8 -8      ports/misc/amanda-server/files/patch-amanda.conf.5
  1.1       +18 -0     ports/misc/amanda-server/files/patch-restore.c (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 4 Jun Kuriyama freebsd_committer 2006-11-29 01:05:38 UTC
State Changed
From-To: open->closed

Committed, thanks!