Operating System - OpenVMS
1748008 Members
4516 Online
108757 Solutions
New Discussion юеВ

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

 
SOLVED
Go to solution
Ragavendran_1
Occasional Advisor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

Thanks Joseph,

I am really happy to receive your valuable replies :)

My system and the remote system is not having DECNET enabled. I can use FTP / TELNET, but in FTP even if i use the SPAWN command to execute the files it refers the local version of that file.

I have to figureout the TELNET more deeper i guess.

REMOTE command you suggested, i guess i cant introduce for completing this job. Still i am happy digging the REMOTE command.

Kindly help me in TELNET and FTP stuffs to execute the COM and EXE files in remote machine.

Thanks in Advance.

Regards,
Ragav.
Joseph Huber_1
Honored Contributor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

>>My system and the remote system is not having DECNET enabled.

But Your previous response showed a response to the SUBMIT/REMOTE command, so there IS DECnet, both on the local as on the remote system!

>> I can use FTP / TELNET, but in FTP even if i use the SPAWN command to execute the files it refers the local version of that file.
>>I have to figureout the TELNET more deeper i guess.

Since You have Telnet and Ftp, You have TCP/IP, and can enable either RSH or SSH.
Neither Telnet nor Ftp have the capability to
send DCL commands to a remote system, (You can dig into Telnet as deep as You like, You will not find such capability).

Decnet remote object/remote submit and TCPIP
RSH/SSH are designed for this purpose. Full stop.
http://www.mpp.mpg.de/~huber
Steven Schweda
Honored Contributor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

> Neither Telnet nor Ftp have the capability
> to send DCL commands to a remote system,
> (You can dig into Telnet as deep as You
> like, You will not find such capability).

Strange. I Telnet to remote systems and
send them commands all the time.

It's also possible to script Telnet sessions
using Kermit. For example

alp $ type ksd.com
$ kermit + sys$input alp-l sms/nocommand insert_password_here
telnet \%1
input 2 Username:
output \%2\13
input 2 Password:
output \%3\13
input 2 $
output show default\13
input 2 $
output logout\13
alp $

alp $ @ ksd.com
DNS Lookup... Trying 10.0.0.9... Reverse DNS Lookup... (OK)

Sorry, Kermit's CONNECT command requires a real terminal;
It can't be used in a batch job.
Use INPUT and OUTPUT commands instead.


I'm ALP. Who are you?

Username: sms/nocommand
Password:

Welcome to VMS (Alpha) V7.3-2 on ALP.

Unauthorized use is prohibited.

Last interactive login on Friday, 5-JUN-2009 09:02:41.81
Last non-interactive login on Saturday, 23-MAY-2009 22:06:12.70
$ show default
HOME_SMS:[SMS]
$
alp $
Joseph Huber_1
Honored Contributor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

Steven, Yes of course, but Telnet as well as kermit is interactive login, which needs a terminal.
I understood the OP wants to execute a remote command (e.g. out of a command file), and don't understand why he refuses to use RSH/SSH/decnet objects.
http://www.mpp.mpg.de/~huber
RBrown_1
Trusted Contributor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

I run kermit in batch to script a telnet session. Take Steven's example and change the "telnet %1" to "set host %1" and I expect that the warning about no batch jobs will go away.
Steven Schweda
Honored Contributor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

> I run kermit in batch to script a telnet
> session.

Same here. I use it do do some things with
my Cisco 628 DSL modem/router.

> Take Steven's example [...]

True. And, as batch jobs, both procedures
work the same as they do interactively.
Joseph Huber_1
Honored Contributor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

I understand Kermit scripting is the only choice when the remote part is a system like routers,switches or printers, which offer only interactive terminal access, not remote shell types.

The original question was about executing DCL commands or procedures on a remote VMS system.
IMHO it is inapropriate to script a terminal session (containing clear text user/password !) just to do that, while RCP/SSH or DECnet remote object is available.
And everytime Your password changes, then the script has to bedited, and such a script can't be offered to other users because of the password inside.
The only reason to do that on VMS I could imagine is, if the remote task involves some kind of dialogue which makes it necessary to pretend to be a terminal session.
http://www.mpp.mpg.de/~huber
Steven Schweda
Honored Contributor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

> And everytime Your password changes, then
> the script has to bedited, and such a
> script can't be offered to other users
> because of the password inside.

I haven't tried it, but I'd guess that one
could write a script/procedure which would
extract a password from a ".netrc" file,
which would solve (or at least alleviate)
these problems.

> IMHO it is inapropriate [...]

Fine, but that's different from saying that
it's impossible.
Rexx
New Member

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

To add the proxy use the following command

mc authorize -
add/proxy node1::username1 username2

You would run this command on node2
username2 is the username on node2

This will mean you will not need to enter a password with your remote command. From what you have stated above it looks like DECnet works between you two nodes.

To view proxies run command

mc authorize show/proxy *::*



Ragavendran_1
Occasional Advisor

Re: DCL Programming - Executing COM files in remote machine through FTP/TELNET

Hi All,

Really thanks to everybody for your different ways in executing remote node's files.

Due to my system architecture i can't use any Decnet commands / functions.

I have come to a conclusion that i will transfer a COM file from local node to the remote machine specific directory thru FTP. When one EOD a batch is executed in my system everyday the new COM will be executed. This will complete my required process.

I think we may have many technical advantages other than this, but my business team have come up with this flow finally.

I will make a notes on this study based on your responses and will try to implement in this in my system after sometime.

Again heartly thanks for your suppport.
Please do keep me in loop for any challenging and difficult process since i am eager to learn new things..

Regards,
Ragav.