I use xargs like:
Like: cat linuxes | xargs -t -i{} ssh {} ls /rootMarcy Cortes "This message may contain confidential and/or privileged information. If you are not the addressee or authorized to receive this for the addressee, you must not use, copy, disclose, or take any action based on this message or any information herein. If you have received this message in error, please advise the sender immediately by reply e-mail and delete this message. Thank you for your cooperation." -----Original Message----- From: Linux on 390 Port [mailto:[EMAIL PROTECTED] On Behalf Of Michael MacIsaac Sent: Thursday, July 12, 2007 8:45 AM To: [email protected] Subject: [LINUX-390] Wrapper around SSH to run command on mutliple Linuxes? Hello list, Does anyone have a simple wrapper around SSH to run the same command on multiple Linuxes? If I have key-based authentication set up from one server to another server, call it "linux01", I can issue the command: # ssh linux01 ls /root bin and see the output from linux01 without needing a password. But let's say I'd like to issue that command on 5 different linuxes. I could call the command dssh and define a group "linuxes" that consist of linux01-linux05. Then I could issue the command: # dssh linuxes ls /root linux01: bin linux02: bin linux03: bin linux04: bin linux05: bin and see the output from each member in the group. I thought about cobbling together a script, but certainly this has been written. Maybe there's already an RPM in my distro that just has to be installed. Thanks. "Mike MacIsaac" <[EMAIL PROTECTED]> (845) 433-7061 ---------------------------------------------------------------------- For LINUX-390 subscribe / signoff / archive access instructions, send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit http://www.marist.edu/htbin/wlvindex?LINUX-390 ---------------------------------------------------------------------- For LINUX-390 subscribe / signoff / archive access instructions, send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit http://www.marist.edu/htbin/wlvindex?LINUX-390
smime.p7s
Description: S/MIME cryptographic signature
