HP3000-L Archives

October 1997, Week 3

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Mark Bixby <[log in to unmask]>
Reply To:
Date:
Wed, 15 Oct 1997 09:03:47 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (26 lines)
James Wilkinson writes:
>
> I want to write a command file that will telnet to a Unix server and then
> run a script.  I can't figure out how, though.  I tried building a file of
> commands and running Telnet with the file as stdin.  This worked until the
> connection to the remote machine was made.  No input from stdin is read
> again until the connection ends.
>
> How can I automate things after that point?  Any help would be appreciated.

If you're on 5.5, then Perl/iX is well suited to this kind of work.  You can
use Perl to manually make a TCP connection to the Unix server's port 23
(telnet), or you can use the Comm.pl CPAN module for a more automated "if login:
prompt then send password" kind of solution.

http://www.cccd.edu/~markb/perlix.html
http://www.perl.com/CPAN-local/modules/by-module/Comm.pl/ERICA/

You will not be using telnet.arpa.sys at all.
--
Mark Bixby                      E-mail: [log in to unmask]
Coast Community College Dist.   Web: http://www.cccd.edu/~markb/
District Information Services   1370 Adams Ave, Costa Mesa, CA, USA 92626-5429
Technical Support               +1 714 438-4647
"You can tune a file system, but you can't tune a fish." - tunefs(1M)

ATOM RSS1 RSS2