telnet

Hi All,

I have written a script called findwho.sh

findwho.sh in Development Server

who -M>x

I want to copy the file findwho.sh
into Production Server and
run this script on it then output file x copy
back to the Development Server

1) Every time ftp findwho.sh to Production
2) telnet to Production
3) execute findwho.sh from Production
4) ftp x file to Development

Can All the above 4 steps do it in a single
shell program?

If anybody give the solution would be appreciated.

Thanks
Kris

There are zillions of ways to do what you are talking about. FTP is not really the cleanest way and is only one way of many to do this. I would not use FTP on a production system. Here is an email example:

[list=1]
[]Email script to production server.
[
]Production server processes and executes script.
[]Production server email results back.
[
]Message from production server processed locally per requirement.
[/list=1]
A more 'super production' process could be set up using messaging queue software like IBM MQ or BEA MessageQ.

If you are going to do this 'on the cheap' then the email method could be set up in a few hours by anyone who understands the basics of processing incoming email messages on UNIX.

I would look at using perl's' tenet and ftp module , it would be pretty simple if thats an option for you .

Hi Neo,

Can you write a script for all the 4 steps ?

Try to use ssh and scp instead of the telnet and ftp.

1.) they are crypt data
2.) you can use authentication via keys [read docs] - that is ideal for off-line script usage