Hi David, I've installed an rpm installation downloaded from OpenSUSE.org.
After putting /bin/mail in usr/lib/ocf/resource.d/heartbeat/.ocf-binaries::
${MAILCMD:=/bin/mail} i'm getting the e-mails when one host is shutting down.
Greetz Stefan
-----Ursprüngliche Nachricht-----
Von: [EMAIL PROTECTED] im Auftrag von David Lee
Gesendet: Mi 12.11.2008 18:06
An: General Linux-HA mailing list
Betreff: Re: AW: AW: AW: [Linux-HA] Linux-HA: E-Mail Notification
Problembytakeover
On Wed, 12 Nov 2008, Bruening, Stefan wrote:
> This ist the Result of grep -r MAILCMD /usr/lib/ocf/resource.d/*
>
> /usr/lib/ocf/resource.d/heartbeat/.ocf-binaries:: ${MAILCMD:=}
> /usr/lib/ocf/resource.d/heartbeat/MailTo: $MAILCMD -s "$1" "$email"
>
> Is anything wrong?
I am guessing a bit here...
Firstly, and probably most important, who built your heartbeat package?
Possibly you built it yourself from source. But I think this might be the
key to the problem.
Lots of technical detail now follows. Feel free to skip it if you wish.
But if you built heartbeat yourself, then you will probably need to read
it to make progress.
<TECHNICAL DETAIL STARTS>
That "${MAILCMD:=}" in ".ocf-binaries" feels as though it might be wrong.
I think it should contain the full pathname (such as "/usr/bin/mail") of
the mail program on your machine.
If it did contain that pathname, the command issued would become (after
substitution):
/usr/bin/mail -s "subject" [EMAIL PROTECTED]
But if that MAILCMD specification is empty, the command would become:
-s "subject" [EMAIL PROTECTED]
(which is clearly wrong); the shell would try to invoke a binary called
"-s", not find it, and so complain something like "-s: command not found".
(And I think that is what you saw, isn't it?)
If that is right, then the problem would seem to relate to your copy of
".ocf-binaries" not specifying "MAILCMD".
How was your installation of heatbeat built? Might you have built it
yourself? The build process (done either by you or the person/site from
which you got the package) ought to have tried to find the mail program
and placed it into that line in ".ocf-binaries". And I suspect that might
have failed, leaving that specification empty.
The principle of hearbeat's building process finding and substituting
"MAILCMD" has been around for years. (I know; it's an area I had to look
at for Solaris!) And I think all the main package maintenance people and
procedures are reasonably robust. But there IS a weakness, not easily
solvable, of handling self-build (e.g. individuals such as you or me
building from source) when it is built (for instance) on a machine which
lacks a "mail" program, or whose mail program isn't the build-time PATH.
<TECHNICAL DETAIL ENDS>
In summary...
This sounds like a "packaging issue"; something you would need to take up
with the people or site who provided your heartbeat package.
And if you built it yourself, that would be you youself. In that case
check the result of the build process "the ConfigureMe (configure)" output
for stuff to do with the mail program. And check any Makefile to see its
value of "MAILCMD": this ought to be a real pathname, but I suspect might
be empty in your case.
Hope that helps.
--
: David Lee I.T. Service :
: Senior Systems Programmer Computer Centre :
: UNIX Team Leader Durham University :
: South Road :
: http://www.dur.ac.uk/t.d.lee/ Durham DH1 3LE :
: Phone: +44 191 334 2752 U.K. :
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems
<<winmail.dat>>
_______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
