Operating System - HP-UX
1830898 Members
2934 Online
110017 Solutions
New Discussion

Remote shell redirection question

 
Randy Hagedorn
Regular Advisor

Remote shell redirection question

HI,

I have a rsh batch file running on DOS that does not seem to be acting the way I planned.

rsh uxdevel -l uxprint echo 'test' > /f01/labels/HARMASTER.ntcl210

When I run this, it displays an error: The system cannot find the path specified.

If I change it to: rsh uxdevel -l uxprint echo 'test' > HARMASTER.ntcl210

It writes it to my local C: drive.

Can anyone tell me how to get this script to write the output to the HP-UX system (uxdevel)?

Thanks,
Randy
2 REPLIES 2
John Poff
Honored Contributor

Re: Remote shell redirection question

Hi,

Try this:

rsh uxdevel -l uxprint echo 'test > /f01/labels/HARMASTER.ntcl210'


Your single quotes will specify what happens on the remote machine, so you need to include the output specification for the file inside the single quotes, otherwise it executes the 'test' command and returns the output locally to your DOS machine.

JP


John Poff
Honored Contributor

Re: Remote shell redirection question

Oops. I think I have a typo in my last post. Try this instead:

rsh uxdevel -l uxprint 'echo test > /f01/labels/HARMASTER.ntcl210'

Assuming that you are trying to echo the word test to your filename.

JP