Re: struggling with vrrp_script [SOLVED]
Paul Slootman <[email protected]>
| Newsgroups | gmane.linux.keepalived.devel |
|---|---|
| Message-ID | <[email protected]> |
Revisiting an old problem I asked about back in May...
I finally found the problem, after someone viewed the config file in an
editor that wasn't UTF8 capable...
There were non-ascii spaces at the beginning of the "script" line :-(
That caused keepalived to simply skip that line silently (no error
given).
Replacing those non-spaces with a tab solved all my problems.
Those non-spaces may have crept in after cutting & pasting from another
document.
Moral: check your config with cat -v when your config doesn't do what it
should.
Paul
On Wed 29 May 2013, Paul Slootman wrote:
> On Tue 28 May 2013, Shivaram Sitaram wrote:
>
> > Hi Paul,
> >
> > Try this out....
> >
> > vrrp_script chk_haproxy {
> > script "/usr/bin/killall -0 haproxy " # exit status 0: for Success,
> > interval 1 # check every second
> > weight -2 # prio = -2 if DOWN
> > fall 2 # require 2 failures for KO
> > rise 2 # require 2 successes for OK
> > }
> > ....
> > vrrp_instance adf {
> > ...
> > track_script {
> > chk_haproxy
> > }
> > }
>
> Hi,
> thanks for your reply, unfortunately this also does not execute the
> script :-(
>
> I still think it's a problem in the parsing of the config file, as
> reflected in the output of --dump-conf:
>
> ------< VRRP Scripts >------
> VRRP Script = chk_haproxy
> Command = (null)
> Interval = 1 sec
> Timeout = 0 sec
> Weight = -2
> Rise = 2
> Fall = 2
> Status = INIT
------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk