Operating System - OpenVMS
1753893 Members
7609 Online
108809 Solutions
New Discussion юеВ

I have a doubt about How running to script DCL in a Linux

 
CIDJULIO
Occasional Contributor

I have a doubt about How running to script DCL in a Linux

Thanks a lot for everything.
I hope that you are very fine, I appreciate all your effort for help me.

How can I run a dcl script since linux?
My little DCL script is done and I have running in Linux with the command rsh:

rsh -l mmote 10.15.17.145 '@smsc_crt0:[STATS]ZA.;1'

I don't know if the way in that I use the command @ is correct(in this case since Linux, because this command run and not appear some message error in the linux propmt but in OpenVms don├В┬┤t run the script za.;1.

What do you recommed to do to I can di it fine.

I have learn about of file .com but I don't know How creat it.

For me your help is very important.

Thanks.


5 REPLIES 5
John Gillings
Honored Contributor

Re: I have a doubt about How running to script DCL in a Linux

Is this a VMS question or a Linux question about rsh?

I'd expect a DCL command procedure to be called ".COM", so perhaps "ZA.COM" or just "ZA" rather than "ZA.;1"? In general, don't specify version numbers in DCL commands, so leave off ";1". I'm also wondering if the quotes are necessary.

I'd start with some simple commands to make sure you've got rsh working. Try these:

rsh 10.15.17.145 -l mmote show time

rsh 10.15.17.145 -l mmote show default

rsh 10.15.17.145 -l mmote show logical smsc_crt0

rsh 10.15.17.145 -l mmote directory smsc_crt0:[STATS]ZA

rsh 10.15.17.145 -l mmote @smsc_crt0:[STATS]ZA


(according to my documentation, the username comes after the host name).
A crucible of informative mistakes
Steven Schweda
Honored Contributor

Re: I have a doubt about How running to script DCL in a Linux

> $ create za.pml
> $ open /write /error=SEND_PML PMLFILE za.pml

As HELP OPEN /WRITE says,

[...]
o Use the /WRITE qualifier to open and create a new, sequential
file. [...]

I don't see how that CREATE command helps
you.

$ pml_script = "za.pml"

And this does what useful thing?


> (according to my documentation, the
> username comes after the host name).

True on HP-UX:

dyi $ remsh alp-l -l sms 'type shd.com'
$ show default

dyi $ remsh alp-l -l sms '@ shd.com'
ALP$DKA0:[SMS]


You can certainly have a command procedure
named "ZA.;1", but ".com" is more usual.

> [...] but in OpenVms don├Г ├В┬┤t run the script
> za.;1.

We can't see what happened. We have only
your vague description. What happens if you
run that command directly on the VMS system?
For example:

alp $ @ shd.com
ALP$DKA0:[SMS]

I don't see where your procedure would send
any output back. All it does for me is to
create two "za.pml" files. (An empty one
from the CREATE, and a non-empty one from the
OPEN).

alp $ @ 337864.TXT
alp $ dire /date /prot /size /sinc

Directory ALP$DKA0:[SMS.ITRC]

337864.TXT;1 1 24-AUG-2009 22:01:12.31 (RWD,RWD,R,)
ZA.PML;2 1 24-AUG-2009 22:19:48.58 (RWED,RWED,RE,)
ZA.PML;1 0 24-AUG-2009 22:19:48.53 (RWED,RWED,RE,)

Total of 3 files, 2 blocks.

What did you expect to happen?
CIDJULIO
Occasional Contributor

Re: I have a doubt about How running to script DCL in a Linux

Thanks!


Lo que quiero es monitorear procesos pml desde linux, por lo que necesito tener la salida del script dcl de OpenVsm en Linux.


I want to monitoring pml process since linux, for that I need to get the information since DCL script in openVMS, but I don├В┬┤t know How pass that information to linux server.

I think in 2 alternatives:
a) Running this command since linux:
rsh -l user 10.15.17.145 @sys$login:my_pml_script ... but this in not good.

b)Copy the result of DCL script througth scp or copy /rcp but I don├В┬┤t know How can I do? I attemp do it with:
scp za.;1 operpresa@10.15.19.5:/home/operacionesps

but It show the next message:
******************

You may have an old style configuration file. Please follow the
instructions in the release notes to use the new configuration
files.

******************
tcpip$ssh_ssh2: FATAL: Error reading config file /etc/ssh2/ssh2_config.

tcpip$ssh_scp2.exe: warning: child process (/sys$system/tcpip$ssh_ssh2) exited with code 188.


And with the command copy /rcp, but it├В┬┤s bad too:

$ COPY/RCP my_file operaciones"operacionesps operpresa."::my_file
%RCP-E-CONHST, error connecting to remote host operaciones

ahh I hope that you can help me. Thanks a lot and excuse me my bad english.

See you soon.


Steven Schweda
Honored Contributor

Re: I have a doubt about How running to script DCL in a Linux

> a) Running this command since linux:
> rsh -l user 10.15.17.145 @sys$login:my_pml_script ... but this in not good.

What's wrong with it? What's in
"sys$login:my_pml_script"?

> You may have an old style configuration file. Please follow the
> instructions in the release notes to use the new configuration
> files.

Having SSH properly installed and configured
can be helpful.

http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1366354

> $ COPY/RCP my_file operaciones"operacionesps operpresa."::my_file
> %RCP-E-CONHST, error connecting to remote host operaciones

Does a plain RSH work to that host with that
user name and that password? (Did you post
the real password here?)
Willem Grooters
Honored Contributor

Re: I have a doubt about How running to script DCL in a Linux

Given the responses, your SSH installation is broken, and RSH/RLOGIN seem to be disabled on the VMS system.

You issued the right command - in general. If your procedure is named 'ZA.COM', the command '@ZA' will do.
ZA.;1 will try to execute file ZA. (without extension).

In your comamnd however, you specified a location: smsc_crt0: The definition of this logical must be defined when you login: either as /SYSTEM or, if RSH actually logs in, /GROUP (of that user) or it must be defined in the login sequence (if RSH actually logs in).

I don't know what the script is to do, but it might be a good idea to re-think the algorithm. We could help you there if we only knew what you want to do.
Willem Grooters
OpenVMS Developer & System Manager