Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Intermittent timeouts using expect with Oracle sqlplus

Status
Not open for further replies.

jjg2610

Programmer
Jul 25, 2002
1
US
I am using expect to automate some database maintenance operations using sqlplus. The problem I am seeing is that about 20% of the time, when I log in to sqlplus, my expect script times out waiting for the "SQL>" prompt. I have been unable to reproduce this behavior manually. My timeout is currently set to 30 seconds although extending the timeout length has not helped. When I run the expect script in debug mode, after successfully matching/sending login information, I normally get the sqlplus banner output and eventually match the prompt, "SQL>". However, when it fails, I only get one more "line" of output from expect after the successful login which contains just a couple of spaces. After that, no more output from the spawned process to match against. Again, this happens intermittently and about 20% of the time! It seems as though expect gets "hung" at this point and longer passes output from the process for parsing. I have consulted the O'Reilly book to no avail. Any thoughts/ideas/suggestions from anyone would be greatly appreciated -- I'm stumped!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top