Summary: | After portage upgrade to 2.1.2.9, ELOG emails are blank | ||
---|---|---|---|
Product: | Portage Development | Reporter: | Peter Ruskin <aoyu93> |
Component: | Unclassified | Assignee: | Portage team <dev-portage> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | ||
Priority: | High | ||
Version: | 2.1 | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Peter Ruskin
2007-06-02 12:16:26 UTC
Hmm, that code didn't change at all since 2.1.2. Do other modules work? Yes, everything else seems to work OK. This is the same on 2 different machines (both x86). Sorry for the noise - 2.1.2.9 works fine again after reboot It's back. /var/log/portage/ and /var/log/portage/elog/ entries are OK but emails are blank. Here's the contents of portage-elog-command.sh: #! /bin/sh # Recipient address to="$1" # Sender address from="$2" # ${PACKAGE} - expands to the cpv entry of the processed # package (see $PVR in ebuild(5)) pvr="$3" # ${LOGFILE} - absolute path to the logfile - This will # make up the e-mail body log_file="$4" # Name of the host from which this mail is sent hostname=`hostname -f` # Sender "full name" from_fullname="Portage Log Message" ( printf "From: %s (%s)\nTo: %s\nSubject: [portage] ebuild log for %s on %s\n\n" \ "$from" "$from_fullname" "$to" "$pvr" "$hostname" cat "$log_file" ) | /usr/sbin/sendmail -bm "$to" So you don't acutally use the mail module but a custom handler script? I never learned another way. How would I do otherwise? It looks like the log is being created too late. I've just remerged libexif and this appears at the end: >>> media-libs/libexif-0.6.15-r1 merged. cat: \/var/log/portage/elog/media-libs:libexif-0.6.15-r1:20070603-102218.log: No such file or directory Yet /var/log/portage/elog/media-libs:libexif-0.6.15-r1:20070603-102218.log does exist, with the same date/time as when the emerge finishes and I get an empty email. If I set PORTAGE_ELOG_SYSTEM="save mail", I get no email and at the end of the emerge I get: >>> media-libs/libexif-0.6.15-r1 merged. !!! An error occured while trying to send logmail: Connection unexpectedly closed Please provide the output of emerge --info -v | grep ELOG $ emerge --info -v | grep ELOG PORTAGE_ELOG_CLASSES="info warn error log" PORTAGE_ELOG_COMMAND="/usr/local/bin/portage-elog-command.sh peter@mesh portage '\${PACKAGE}' '\${LOGFILE}'" PORTAGE_ELOG_MAILFROM="portage" PORTAGE_ELOG_MAILSUBJECT="package ${PACKAGE} merged on ${HOST} with notice" PORTAGE_ELOG_MAILURI="root" PORTAGE_ELOG_SYSTEM="save custom" Try with the following settings: PORTAGE_ELOG_SYSTEM="mail" PORTAGE_ELOG_MAILURI="peter@mesh /usr/sbin/sendmail" That seems to have fixed it. Thanks. Ok, so closing this. As for the original problem, I think that's a config issue, that backslash in the posted error messages looks suspicious. |