Re: [OT] ssh login script - Please Help

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 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

Alternately, Dan ought to, instead of an expect script, use a non-root
user, key-based authentication (bypass the password), scp the conf file to
the non-root user's homedir, and sudo to provide root level privs to move
the conf file into place and restart NTP.

-- 
Mike Burger
http://www.bubbanfriends.org

Visit the Dog Pound II BBS
telnet://dogpound2.citadel.org or http://dogpound2.citadel.org

To be notified of updates to the web site, visit:

https://www.bubbanfriends.org/mailman/listinfo/site-update

or send a blank email message to:

site-update-subscribe@xxxxxxxxxxxxxxxxx

-- 
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [Fedora Magazine]     [Fedora News]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Maintainers]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [Fedora Fonts]     [ATA RAID]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [SSH]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Tux]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Asterisk PBX]     [Fedora Sparc]     [Fedora Universal Network Connector]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux