pxssh submit su commands = very very slow

Neil Hodgson nyamatongwe+thunder at gmail.com
Sun Jun 29 01:19:56 CEST 2008


gert:
> This works but after the su command you have to wait like 2 minutes
> before each command gets executed ?
>             s.sendline ('su')
>             s.expect('Password:')

    A common idiom seems to be to omit the start of the expected reply 
since it may not be grabbed quickly enough. Then the prompt has to time 
out. Try
              s.expect('assword:')

    Neil



More information about the Python-list mailing list