dihewidd has asked for the wisdom of the Perl Monks concerning the following question:
ALTERNATIVELY how do we get the output line by line from Net::Telnet and work with it? Every example I see has it logging in and getting a single line of text. My telnet server has no login. My server just starts spitting data at you. ----------open TELNET, "telnet 192.168.1.88 < /dev/tty |"; while (<TELNET>){ # writes data to mySQL DB }
use Net::Telnet; $telnet = new Net::Telnet ( Timeout=>10, Errmode=>'die'); $telnet->open('192.168.1.88');
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Safely close TELNET connection?
by Mr. Muskrat (Canon) on Jan 18, 2011 at 18:58 UTC |