Bug 19013 - pump never returns ip in script arguments
pump never returns ip in script arguments
Product: Red Hat Linux
Classification: Retired
Component: pump (Show other bugs)
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Elliot Lee
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2000-10-12 21:39 EDT by Need Real Name
Modified: 2007-04-18 12:29 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2003-11-03 15:43:31 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Need Real Name 2000-10-12 21:39:13 EDT
when calling a script with pump.conf's script directive I never get a
useful IP as the third argument as per the man page.

It's always something like up eth1
Comment 1 Erik Troan 2000-10-23 10:30:54 EDT
I've managed to replicate this only by letting pump fail on eth1, in which case
it does exactly what you described. It shouldn't be running the script at all in
this case (which I've fixed), but I have a feeling you're seeing something else?

Is pump working otherwise? What script are you using? How do you know what the
parameters look like? Is the script actually being run properly? Does
/var/log/messages have anything useful in it? Does the script work properly on
eth0 (can you test that?).
Comment 2 chris 2000-10-24 07:15:46 EDT
For what it's worth, there seem to be pretty weird things going on with the
script on my system too (RH7.0, pump-0.8.3-2).  With the following script:

# Script to modify /etc/hosts when pump gains a new IP address.

echo "pump-script running with arguments ($1) ($2) ($3)..." >/tmp/pumpscr.txt

if [ "$1" = up -a "$2" = eth0 -a "$3" != ]; then
  echo "pump-script doing its thing" >>/tmp/pumpscr.txt
  ( /bin/cp -fp /etc/hosts /etc/hosts.bak && \
  echo "$3	`/bin/hostname -s`	`/bin/hostname`" >/etc/hosts && \
  /bin/grep -v "`/bin/hostname | sed 's/\./\\\./g'`" /etc/hosts.bak >>/etc/hosts
) 2>>/tmp/pumpscr.txt
  # Bring up the firewall.
  /etc/sysconfig/network-scripts/firewall $2 $3
  echo "pump-script failed with arguments ($1) ($2) ($3)" >>/tmp/pumpscr.txt

I get the "pump-script running" and "pump-script doing its thing" messages in
/tmp/pumpscr.txt, followed by "/bin/cp: write error: Bad file descriptor".  And
if I change those "echo >/tmp/pumpscr.txt" lines to invocations of
/usr/bin/logger, nothing at all gets logged to syslog.

Anything else I can try?

Comment 3 Need Real Name 2000-11-11 16:30:25 EST
My setup eth1 as an interface to a cable modem, so your fix addresses my bug
report. It is reporting the IP correctly now.

Comment 4 chris 2000-11-13 08:11:26 EST
Hmm...upgrading to pump-0.8.4-1 and then downgrading back to 0.8.3-2 seems to
have fixed the above: no more "Bad file descriptor" errors, and logging to
syslog now seems to work fine.

Very peculiar...
Comment 5 Elliot Lee 2003-11-03 15:43:31 EST
Old, dead bug.

Note You need to log in before you can comment on or make changes to this bug.