Paramiko ssh output stops at --more--

Posted by Anesh on Stack Overflow See other posts from Stack Overflow or by Anesh
Published on 2014-07-18T15:07:49Z Indexed on 2014/08/19 16:20 UTC
Read the original article Hit count: 195

Filed under:
|
|
|

The output stops printing at --more-- any idea how to get the end of the output

 >>> import paramiko
 >>> ssh = paramiko.SSHClient()
 >>> ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
 >>> conn=ssh.connect("ipaddress",username="user", password="pass")
 >>> channel = ssh.invoke_shell()
 >>> channel.send("en\n")
 3
 >>> channel.send("password\n")
 9 
 >>> channel.send("show security local-user-list\n")
 30
 >>> results = ''
 >>> channel.send("\n")
 1
 >>> results += channel.recv(5000)
 >>> print results

 bluecoat>en
 Password:
 bluecoat#show security local-user-list
 Default List: local_user_database
 Append users loaded from file to default list: false
 local_user_database
 Lockout parameters:
 Max failed attempts: 60
 Lockout duration:    3600
 Reset interval:      7200
 Users:
 Groups:

 admin_local
  Lockout parameters:
  Max failed attempts: 60
 Lockout duration:    3600
 Reset interval:      7200
 Users:
  <username>
    Hashed Password: 
    Enabled:         true
    Groups:

  <username>
    Hashed Password: 
    Enabled:         true
  **--More--**

As you can see above the output stops printing at --more-- any idea how to get the output to print till the end.

© Stack Overflow or respective owner

Related posts about python-2.7

Related posts about networking