[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: Help with error when executing a remote command via ssh

Jano Svitok

9/27/2007 6:28:00 PM

On 9/27/07, Victor Reyes <victor.reyes@gmail.com> wrote:
> 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

This is an old topic... although I haven't encountered it myself, you may try:
http://www.google.com/search?q=insecure+world+wri...

Jano