And, perl is "built in" too. I don't think there is a Linux or Unix that
comes without it. Been that way for years.
Also, I believe it's been pointed out that if it works from the command
line, but not from startup, that's an environment issue. Check your
environment and your dependencies in your bash shell. Use full path
lengths so that you aren't dependent on $PATH. And so on.
---------------
Chris Hoogendyk
-
O__ ---- Systems Administrator
c/ /'_ --- Biology & Geology Departments
(*) \(*) -- 140 Morrill Science Center
~~~~~~~~~~ - University of Massachusetts, Amherst
<hoogen...@bio.umass.edu>
---------------
Erdös 4
Noel Butler wrote:
The point is mon is perl based, and there already exists a perfectly
working sms.alert script, so why re-invent the wheel.
Since you are using a debian based system and they are well known for
screwing things to their own liking I suggest you investigate your
init.d mon script which it is pretty clear where the problem is.
On Wed, 2010-04-28 at 17:30 +0200, ad...@jack-clan.nl wrote:
well, why use perl to do something, when it should work with bash, the
built-in way to do things in linux?
And mind it works, when i start mon -f it executes, but not when i run
/etc/init.d/mon start.
> Why don't you just use the perl sms.alert script?
> whats the fascination with bash?
>
>
> On Tue, 2010-04-27 at 16:28 +0200, ad...@jack-clan.nl <mailto:ad...@jack-clan.nl> wrote:
>
>> No still ain't workin'
>> Pffft ,has anybody used a shell script as an alert before ( in
>> daemon-mode
>> ) ?
>> Otherwise i ll start mon as a program, not as a daemon, or are there
>> reasons not to do so?
>>
>> thanks
>>
>>
>> sms.alert:
>>
>>
>> #!/bin/bash
>>
>> export
>>
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
>>
>> /bin/echo "servers down test" | /usr/bin/gammu --sendsms TEXT
0653638072
>>
>>
>>
>> Jim Trocki :
>>
>>
>> if it works when you do "-d -f" then from that shell do
>>
>> echo $PATH
>>
>> and put that path at the top of your bash script, e.g.
>>
>> #!/usr/bin/bash
>>
>> export PATH=/bin:/usr/bin:....whatever
>>
>>
>>
>> _______________________________________________
>> mon mailing list
>> mon@linux.kernel.org <mailto:mon@linux.kernel.org>
>> http://linux.kernel.org/mailman/listinfo/mon
_______________________________________________
mon mailing list
mon@linux.kernel.org
http://linux.kernel.org/mailman/listinfo/mon