Help please using telnetlib module

Birdman birdfamily at gmail.com
Sun Dec 24 06:30:21 EST 2006


Simplest explanation is that you can't do a 'show run' from global
configuration mode....

try something like

#exit global configuration mode
tn.write('end\n')
print tn.read_until('#')

#disable pause after 24 lines
tn.write('term len 0\n')
tn.read_until('#')

#now show the entire running-config
tn.write('show run\n')
print tn.read_until('#')




More information about the Python-list mailing list