From: Brian Candler Date: 2012-03-29T06:42:49+09:00 Subject: Re: How to process telnet data(binary) Have you tried setting Binmode option to Net::Telnet? # Binmode:: if false (the default), newline substitution is performed. # Outgoing LF is # converted to CRLF, and incoming CRLF is converted to LF. If # true, this substitution is not performed. This value can # also be set with the #binmode() method. The # outgoing conversion only applies to the #puts() and #print() # methods, not the #write() method. The precise nature of # the newline conversion is also affected by the telnet options # SGA and BIN. However I would say that your proposed way of doing things is very fragile, because if nothing else there will be trailing garbage (the command prompt) added to your data. You might want to look at SCP or SFTP for a more robust way of copying files from a Linux system. -- Posted via http://www.ruby-forum.com/.