From: Victor Reyes Date: 2007-09-28T03:08:53+09:00 Subject: Help with error when executing a remote command via ssh ------=_Part_1512_25632351.1190916531825 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Team, I am running the following piece of code, which simply executes a remote command and output its outcome! However, I am getting a warning when executing the remote command. 1 - #!/usr/local/bin/ruby 2 - 3 - fh = File.open "/etc/servers" # Open list of servers for reading 4 - svrs = fh.readlines # This is a small file, read it into memory 5 - fh.close # We don't need the file anymore 6 - 7 - svrs.each do |server| # Iterate over servers list 8 - v = `ssh -q #{server.chomp} date` # Execute cmd on remote server 9 - puts server.chomp.to_s << ": " << v.to_s 10 - end OUTPUT: dshproc:8: warning: Insecure world writable dir /usr/local in PATH, mode 0240777 srv-app1was: Thu Sep 27 14:05:22 EDT 2007 dshproc:8: warning: Insecure world writable dir /usr/local in PATH, mode 0240777 srv-db2db: Thu Sep 27 14:05:25 EDT 2007 dshproc:8: warning: Insecure world writable dir /usr/local in PATH, mode 0240777 srv-app2cmrm: Thu Sep 27 14:05:25 EDT 2007 dshproc:8: warning: Insecure world writable dir /usr/local in PATH, mode 0240777 srv-web3: Thu Sep 27 14:05:26 EDT 2007 dshproc:8: warning: Insecure world writable dir /usr/local in PATH, mode 0240777 srv-db2passapp: Thu Sep 27 14:05:27 EDT 2007 dshproc:8: warning: Insecure world writable dir /usr/local in PATH, mode 0240777 srv-svrsas: Thu Sep 27 14:05:27 EDT 2007 Any help will be appreciated! Thanks Victor ------=_Part_1512_25632351.1190916531825--