[OT] ssh login script - Please Help

Todd Zullinger tmz at pobox.com
Thu May 7 15:58:55 UTC 2009


Dan Track wrote:
> I appreciate this is OT but could someone just give me a little
> advice, I've written this script to logon on each server then
> restart the ntpd daemon. The problem I have is it only restarts the
> daemon for the last server provided in the list, any ideas as to why
> and how to fix it?

While I'm not offering any help on why your expect script is failing
you, I would say that if you have a need to ssh into multiple machines
to copy config files and restart services, you should look into tools
like func and puppet.  Func is perfect for quick, one-off commands.
Puppet is better for complete configuration management.

As a t-shirt from Reductive Labs¹, the makers of Puppet said, "SSH in a
loop is _not_ a solution." ;)

¹ http://reductivelabs.com/images/Layouts.pdf

-- 
Todd        OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
A statesman is a dead politician. Lord knows, we need more statesmen.
    -- Opus

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 542 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20090507/d7392b18/attachment-0001.sig>


More information about the fedora-list mailing list