[smokeping-users] Master/slave Mode doens't work anymore

Tobias Oetiker tobi at oetiker.ch
Wed Apr 16 23:19:38 CEST 2008


Hoi Ralf,

The following patch will help:

Index: Smokeping/Master.pm
===================================================================
--- Smokeping/Master.pm (revision 979)
+++ Smokeping/Master.pm (working copy)
@@ -210,8 +210,11 @@
             close $hand;
             return $1;
         }
-    }
-    warn "WARNING: Opening $cfg->{Slaves}{secrets}: $!\n";
+    } else {
+        print "Content-Type: text/plain\n\n";
+        print "WARNING: Opening secrets file $cfg->{Slaves}{secrets}: $!\n";
+        return '__HORRIBLE_INLINE_SIGNALING__';
+    }
     return;
 }

@@ -227,6 +230,7 @@
     my $q = shift;
     my $slave = $q->param('slave');
     my $secret = get_secret($cfg,$slave);
+    return if $secret eq '__HORRIBLE_INLINE_SIGNALING__';
     if (not $secret){
         print "Content-Type: text/plain\n\n";
         print "WARNING: No secret found for slave ${slave}\n";


I wonder though how the WARNING about the secrets fileopening
problem did not show up in your apache error.log ...

cheers
tobi



Today Ralf Hildebrandt wrote:

> * Niko Tyni <ntyni+smokeping-users at mappi.helsinki.fi>:
> > On Wed, Apr 16, 2008 at 04:07:59PM +0200, Ralf Hildebrandt wrote:
> >
> > > Can't be a permission problem, since when I change the permissions of
> > > the slavesecrets.conf file, smokeping won't even start.
> >
> > It still could, in case slavesecrets.conf is not readable by the web
> > server on the master. Please check that.
>
> YEES, that could be! Good idea!!
> YEAAAAAAAAAAAAAAAH, you da man.
>
> But let's face it. The docs could mention that :)
>
>

-- 
Tobi Oetiker, OETIKER+PARTNER AG, Aarweg 15 CH-4600 Olten
http://it.oetiker.ch tobi at oetiker.ch ++41 62 213 9902



More information about the smokeping-users mailing list