[smokeping-users] ssh-keyscan error starting from boot only
Vinny_Abello at Dell.com
Vinny_Abello at Dell.com
Tue Feb 5 03:47:17 CET 2013
Thanks for the tip. On my system I actually found that smokeping is starting before, sshd oddly enough.
I modified the smokeping rc file from:
# REQUIRE: LOGIN
to
# REQUIRE: LOGIN sshd
The order now looks correct and rcorder shows smokeping will be started after sshd now. I think that dependency should probably be in place in the FreeBSD port rc script by default, unless there is a more proper way to do this. Perhaps something else is wrong on my system and LOGIN is expected to be dependend on sshd or some other chain of events.
-Vinny
-----Original Message-----
From: Jim Long [mailto:smokeping at museum.rain.com]
Sent: Wednesday, January 23, 2013 4:12 PM
To: Abello, Vinny
Cc: smokeping-users at lists.oetiker.ch
Subject: Re: [smokeping-users] ssh-keyscan error starting from boot only
On Wed, Jan 23, 2013 at 07:17:09PM +0000, Vinny_Abello at Dell.com wrote:
> Hello,
>
> I'm wondering if anyone has encountered this problem. We're running smokeping 2.6.7 on FreeBSD 8.3. When the system boots up, the startup script tries to start smokeping, but smokeping errors out on initializing the ssh-keyscan probe with the following error:
>
> Starting smokeping.
> ### parsing dig output...OK
> ERROR: output of '/usr/bin/ssh-keyscan -t dsa,rsa,rsa1 127.0.0.1' does not match (?i-xsm:^# \\S+ SSH-)
> at (eval 56) line 1
>
> /etc/rc: WARNING: failed to start smokeping
>
>
> The very strange thing is if I start smokeping using the same startup script manually after the system has booted, I get no error at all and everything works fine.
>
> Any thoughts on why this is and how I would go about correcting it?
>
> Thanks!
>
> -Vinny
Peter's assessment of the cause is probably accurate, but the
FreeBSD rc(8) system likely is already ordering your startup
scripts correctly.
Read: http://www.freebsd.org/doc/handbook/configtuning-rcd.html
And look at your system's current service dependency order:
rcorder /etc/rc.d/* /usr/local/etc/rc.d/* | less
On my system, I see that sshd starts immediately before
smokeping. If sshd forks into the background quickly, before the
service is 100% up and running, smokeping could start before sshd
is ready for it.
I suspect you'll have to put a 'sleep 3' or something at the
top of your smokeping startup script, for some value of '3'.
Jim
More information about the smokeping-users
mailing list