Training, Open Source computer languages
PerlPHPPythonMySQLApache / TomcatTclRubyJavaC and C++LinuxCSS 
Search for:
Home Accessibility Courses Diary The Mouth Forum Resources Site Map About Us Contact
For 2021 - online Python 3 training - see ((here)).

Our plans were to retire in summer 2020 and see the world, but Coronavirus has lead us into a lot of lockdown programming in Python 3 and PHP 7.
We can now offer tailored online training - small groups, real tutors - works really well for groups of 4 to 14 delegates. Anywhere in the world; course language English.

Please ask about private 'maintenance' training for Python 2, Tcl, Perl, PHP, Lua, etc.
single script handling two processes in two diff p

Posted by sharmila (sharmila), 6 October 2005
I have a single script.I need the script to start 2 telnets in two diff processes.It starts two telnets processes in two diff machines but couldn't give expected outputs.Is it script  problem or processor which handles the script create problem?
My problem is :
I have a single script.
It takes commands through a file.
First half of the file is talking to a processor and starts telnet and does all work.
Next half of the script is to talk with a completely diff. processor.It starts telnet and does all the work.
But these 2 processors have to talk to each other according to my software.It doesnt.
Please give a solution....please.

Posted by admin (Graham Ellis), 7 October 2005
If you've got an expect process talking to remote machine "X" via telnet and also talking to remove machine "Y" via telnet, you can have a process on machine X influence a process on machine Y by ...

1. Running a command via the telnet you've spawned on machine X that outputs the data you want to use on machine Y

2. Gather that data in your expect process (via expect's output buffer) into a Tcl variable

3. Use the data gathered as part of a command or response within the spawned process you're using to talk to machine Y.

There isn't any direct connection set up between machines X and Y; there are ways you could do that such as running expect an expect program on one of the remote systems from within the telnet session, but I would advise against this. because it would be hard to maintain and debug, it would mean that you had to load and maintain expect on two systems, and that your systwm would involve two scripts that had to be kept in sync rather than just the one.

Posted by sharmila (sharmila), 7 October 2005

This page is a thread posted to the opentalk forum at and archived here for reference. To jump to the archive index please follow this link.

You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2022: Well House Manor • 48 Spa Road • Melksham, Wiltshire • United Kingdom • SN12 7NY
PH: 01144 1225 708225 • FAX: 01144 1225 793803 • EMAIL: • WEB: • SKYPE: wellho