Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: How to pass --MORE--

by FloydATC (Deacon)
on Feb 13, 2015 at 10:48 UTC ( [id://1116606]=note: print w/replies, xml ) Need Help??


in reply to How to pass --MORE--

On devices such as Cisco and HP switches/routers, you can adjust the "terminal length" or similar to prevent the --MORE-- prompt from appearing.

#term len 0 #show config

On Juniper devices, you can pipe any command output into "no-more" for the same result.

> show configuration | no-more

Check your particular OS/system for similar possibilities. This is a far simpler approach than trying to work around the problem on the receiving end.

-- FloydATC

Time flies when you don't know what you're doing

Replies are listed 'Best First'.
Re^2: How to pass --MORE--
by oguzhantepe (Novice) on Feb 13, 2015 at 11:43 UTC
    Hi, we are try to get configuration backup of a Voice Device on network, it doesn't give all output on screen and there is no terminal length or any other term length command option option so we need to press enter when see --MORE-- ann try to get all input into a txt file is it possible?
      Could you just give us the device details (i.e. maker, operating system, version, etc.)?

      BTW, a capture of a sample session may also help.

        Hi, the vendor is Audiocodes,mediant 800 I don't know the other details about the device. We just try to make telnet with perl and get configuration backup to a txt file. it runs show running config command. thanks.
        hi salva thanks for your advices. here is the outputs of help command on CLI
        Mediant 800> help Use '?' in order to show available commands. 'TAB' can completion Use 'list' to see all available commands Mediant 800> enable Turn on privileged commands exit Exit from current mode help Show available commands history Show a list of previously run co list Available command list nslookup resolve host name ping Ping packets pwd Display current configuration mo quit Disconnect show Show running system information
        Could you please give some examples about the usage of Expect and Net:Telnet to ignore --more--? I've made some tests like below but it does not make sense could you please check?
        $telnet->print('show running-config'); while( my $line = $telnet->getline() ) { push @lines, $line; $match = $telnet->waitfor(Match => '/\-\-More\-\-$/i'); if ($match =~ /\-\-More\-\-/){ $telnet->print(" "); } }
        Hi Salva, here is the output of list command
        Commands available: clear alarms-history clear l2tp-server all clear l2tp-server conn [CONN] clear pptp-server all clear pptp-server conn [CONN] enable exit help history list nslookup [STRING] nslookup [STRING] source voip nslookup [STRING] source voip interface vlan [1-3999] nslookup [STRING] source voip interface vlan [1-3999] type A nslookup [STRING] source voip interface vlan [1-3999] type AAAA nslookup [STRING] source voip interface vlan [1-3999] type NAPTR nslookup [STRING] source voip interface vlan [1-3999] type SRV nslookup [STRING] type A nslookup [STRING] type A source voip nslookup [STRING] type A source voip interface vlan [1-3999] nslookup [STRING] type AAAA nslookup [STRING] type AAAA source voip nslookup [STRING] type AAAA source voip interface vlan [1-3999] --MORE-- nslookup [STRING] source voip interface vlan [1-3999] type SRV nslookup [STRING] type A nslookup [STRING] type A source voip nslookup [STRING] type A source voip interface vlan [1-3999] nslookup [STRING] type AAAA nslookup [STRING] type AAAA source voip nslookup [STRING] type AAAA source voip interface vlan [1-3999] nslookup [STRING] type NAPTR nslookup [STRING] type NAPTR source voip nslookup [STRING] type NAPTR source voip interface vlan [1-3999] nslookup [STRING] type SRV nslookup [STRING] type SRV source voip nslookup [STRING] type SRV source voip interface vlan [1-3999] ping [A.B.C.D or hostname] ping [A.B.C.D or hostname] source voip ping [A.B.C.D or hostname] source voip interface vlan [1-3999] ping [A.B.C.D or hostname] source voip interface vlan [1-3999] repeat + [1-300] ping [A.B.C.D or hostname] source voip interface vlan [1-3999] repeat + [1-300] ize [500-20000] ping [A.B.C.D or hostname] source voip interface vlan [1-3999] size [ +500-20000 ping [A.B.C.D or hostname] source voip interface vlan [1-3999] size [ +500-20000 repeat [1-300] --MORE-- ping [A.B.C.D or hostname] source voip interface vlan [1-3999] size [ +500-20000 repeat [1-300] ping [A.B.C.D or hostname] source voip repeat [1-300] ping [A.B.C.D or hostname] source voip repeat [1-300] size [500-20000 +] ping [A.B.C.D or hostname] source voip size [500-20000] ping [A.B.C.D or hostname] source voip size [500-20000] repeat [1-300 +] pwd quit show running-config show running-config full show system active-alarms show system alarms-history show system assembly show system date show system feature-key show system ntp-status show system time show system uptime show system version show voip dsp perf show voip dsp status show voip gw calls-count ip2tel show voip gw calls-count tel2ip --MORE-- show voip gw statistics basic show voip interface e1-t1 show voip interface e1-t1 [X/Y (Slot/Port)] show voip interface fxs-fxo show voip interface fxs-fxo [X/Y (Slot/Port)] show voip interface network show voip interface network [0-47] show voip interface network description show voip ports show voip register show voip register accounts show voip register gw show voip register ports show voip register sas show voip register sbc show voip register userinfo gw show voip register userinfo sbc show voip route show voip tdm
        thanks
        Hi Salva; I can get the all the configuration to a txt file thanks, but there is some bad characters in this file like BSBSBS is it backspace? How can I replace it with using perl? I can't do this? thanks 
        Hi again salva, is there any way to remove empty lines from array? I tried with grep but it doesn't work. thnaks.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1116606]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (9)
As of 2024-03-28 10:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found