First of all, I'm a beginner at perl - so be easy on me :)
I'm trying to write a program which uses Net::Telnet to check information on my router (switch (different manufacturers)), and I have a problem with some commands returning a lot of data.
my @tmp = $telnet->cmd("sh ver");
It causes a time-out and quits the program.
My theory is that the output data is page'd (the switch responds with either "--More--" or "Press c for continous, q for quit, <space> for one more row" and then halts until a char has been pressed. But "->cmd" doesn't issue this, tries to read for X seconds then quits.
Is there any way I can tell the Telnet-package to read everything, or do I need to use $telnet->send and $telnet->getline? :<
I know that this might be the wrong forum to ask this, but I'm running out of ideas. =)
Thanks in advance.