Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 40193 - mailx crashes when invoked from amanda
Summary: mailx crashes when invoked from amanda
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Net-Mail Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-02-02 09:32 UTC by Lindsay Haisley
Modified: 2004-07-13 19:57 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lindsay Haisley 2004-02-02 09:32:54 UTC
I'm not sure if this is a bug against amanda or mailx, but I suspect the latter since I'm able to substitute /usr/bin/mutt for /bin/mail as the symbolic link target of /bin/Mail and the problem goes away.  Here's a summary:

amanda sends notifications of backup actions and (optionally) checks using the hard-coded mail program /bin/Mail which receives the notification text on stdandard input.  As installed by mailx, /bin/Mail is a symlink to /bin/mail.  When trying to run a system check, I get the following results:

amanda@vishnu:~$ /usr/sbin/amcheck -m Shiva
amcheck: error running mailer /bin/Mail: got signal 11

I can get some information out of the failure by substituting the following script for /bin/mail as the target for the symlink.

#!/bin/sh
echo $1 > /tmp/amandamailarg1
echo $2 > /tmp/amandamailarg2
echo $3 > /tmp/amandamailarg3
/bin/mail $1 "$2" $3

The error is reported as follows:

amanda@vishnu:~$ /usr/sbin/amcheck -m Shiva
/bin/Mail: line 5: 15208 Segmentation fault      /bin/mail $1 "$2" $3
amcheck: error running mailer /bin/Mail: returned 139

As noted above, if I make /usr/bin/mutt the target for /bin/Mail the problem goes away.  mutt is a mailx workalike as far as this particular cmd line invocation form is concerned, and the results from amanda are as expected, so this isn't mission critical for me.

I should note that the use of /bin/mail by amanda _has_ worked in the past, although intermittantly.  If don't invoke amanda with the -m option (mail results to the listed mail admin) but instead, after running the above script, do this:

$ /usr/sbin/amcheck Shiva | /bin/Mail `cat /tmp/amandamailarg1` "`cat /tmp/amandamamailarg2`" `cat /tmp/amandamailarg3`

There's no problem.  Go figure!  mailx also works properly when I invoke it from the CLI using similar notation to send arbitray email.

The system is otherwise an otherwise _very_ stable and reliable desktop platform (yea gentoo!).  If gentoo devs want me to try anything here I'll be glad to poke at the problem and see if anything can be learned.

emerge info...

vishnu:~# emerge info
Portage 2.0.49-r20 (default-x86-1.4, gcc-3.3.2, glibc-2.3.2-r9, 2.4.20-gentoo-r9)
=================================================================
System uname: 2.4.20-gentoo-r9 i686 Intel(R) Pentium(R) 4 CPU 2.60GHz
Gentoo Base System version 1.4.3.10
ccache version 2.3 [enabled]
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -mcpu=pentium4 -march=pentium4 -fprefetch-loop-arrays -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.1/share/config /usr/kde/3/share/config /usr/share/config /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
CXXFLAGS="-O2 -mcpu=pentium4 -march=pentium4 -fprefetch-loop-arrays -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache sandbox"
GENTOO_MIRRORS="ftp://gentoo.noved.org/ http://gentoo.noved.org/ ftp://ftp.ussg.iu.edu/pub/linux/gentoo"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X Xaw3d acl acpi alsa apache2 apm arts avi berkdb bindist bonobo cdr crypt cups curl doc dvd dvdr encode esd evo fastcgi flash foomaticdb gdbm gif gnome gpm gps gstreamer gtk gtk2 gtkhtml guile imap imlib ipv6 java jikes jpeg libg++ libwww mad maildir mcal mikmod motif mozilla mpeg mysql ncurses nls oggvorbis opengl oss pam pdflib perl plotutils png ppds python quicktime readline samba sasl scanner sdl slang slp snmp spell sse ssl svga tcltk tcpd tetex tiff truetype usb x86 xml xml2 xmms xosd xv zeo zlib"
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-05-23 23:56:13 UTC
i can't reproduce this.
could you enable core dumps, and get the core for /bin/Mail, and provide us with the gdb backtrace?
Comment 2 Lindsay Haisley 2004-05-24 15:31:01 UTC
I'll happily put it on my TODO list, but I'm going out of town this week and probably won't be able to give the problem any quality attention until after the 13th of June.

Just to refresh my memory, how do you get an app to dump core when it crashes?  I used to know, but haven't done it in a while.
Comment 3 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-05-24 15:56:55 UTC
run 'ulimit -c 1000000' before using the app.
works best if you recompile the apps with USE="debug" CFLAGS="-g -O1 -pipe" FEATURES="nostrip" first.
Comment 4 Cory Visi (RETIRED) gentoo-dev 2004-06-30 22:40:18 UTC
Lindsay, any progress with this?
Comment 5 Lindsay Haisley 2004-07-09 16:23:39 UTC
Cory, I'm back and will try this out as my time permits.  I tend to file a lot of bug reports, a substantial number of which are genuine bugs, and so I alwyas have a backlog of fixes to try.  It's on my list.
Comment 6 Lindsay Haisley 2004-07-13 19:57:49 UTC
Just updated mailx, as well as amanda a couple of days ago.  The /bin/Mail link which I'd set to point to mutt changed back to /bin/mail and everything seems to work properly.  I'm setting this as resolved.  Thanks for sticking with me on it.