<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: FTP and OpenVMS command file symbols in Operating System - OpenVMS</title>
    <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880560#M28977</link>
    <description>&lt;P&gt;It would have helped if you showed your command procedure - with sensitive information removed.&lt;/P&gt;&lt;P&gt;P1 is a DCL symbol (or variable), which is only substituted (or expanded) in the DCL context. When you enter the FTP command you can use DCL symbols for the command arguments/parameters. But once the&amp;nbsp;FTP program runs and prompts you for an FTP command you are no longer in a DCL context. The PUT command is in the program context and there P1 has no definition (or value).&lt;/P&gt;&lt;P&gt;You need to let DCL substitute the symbols and write that to the input for FTP.&amp;nbsp;FTP reads its input from SYS$INPUT or whatever you direct it to with /INPUT. So either redirect SYS$INPUT or use /INPUT.&lt;/P&gt;&lt;P&gt;Usually this is done by writing an input file - in the DCL context, so with the WRITE command. You can use the PIPE command and WRITE to write the SYS$INPUT for FTP, something like&lt;/P&gt;&lt;PRE&gt;$&amp;nbsp;pipe write sys$output "put ''p1' ''p1'" |ftp host/username=remote-username/password=remote-password&lt;/PRE&gt;&lt;P&gt;Obviously you need to have the remote username and the password in this command. I don't know how you did this in your command procedure and whether this is OK in&amp;nbsp;your environment.&lt;/P&gt;&lt;P&gt;And then there are other tools for example COPY/FTP, which are easier to use from the DCL command line - that is with DCL symbols.&lt;/P&gt;</description>
    <pubDate>Wed, 20 Jul 2016 22:28:33 GMT</pubDate>
    <dc:creator>H.Becker</dc:creator>
    <dc:date>2016-07-20T22:28:33Z</dc:date>
    <item>
      <title>FTP and OpenVMS command file symbols</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880515#M28972</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am attempting to spawn a command file to use FTP to transfer a&amp;nbsp;file.&amp;nbsp; The spawn command spawns the string "@CommandFile FileToTransfer".&lt;/P&gt;&lt;P&gt;The statement in the command file "Sho Sym 'P1'&amp;nbsp; lists "FileToTransfer".&amp;nbsp; But the FTP command&lt;/P&gt;&lt;P&gt;Put 'P1' 'P1'&lt;/P&gt;&lt;P&gt;does not&amp;nbsp;translate P1.&lt;/P&gt;&lt;P&gt;I am working with OpenVMS V8.3-1H1 on an Itanium HP Integrity 2660.&lt;/P&gt;&lt;P&gt;Any suggestions?&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jul 2016 20:32:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880515#M28972</guid>
      <dc:creator>Rich Bordewick</dc:creator>
      <dc:date>2016-07-20T20:32:15Z</dc:date>
    </item>
    <item>
      <title>Re: FTP and OpenVMS command file symbols</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880545#M28973</link>
      <description>&lt;P&gt;If the following is what you are entering, it should work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;$ SPAWN&amp;nbsp;@CommandFile FileToTransfer&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The value "FileToTransfer" should be interpreted as P1 for the procedure. &amp;nbsp;Note the following as a test that works:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;===============&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;$ Cre test.com&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;$ Write sys$output "''p1'" &amp;nbsp; ! note the double quote followed by two apostrophes before the p1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;$exit ! CTRL-Z&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;$ spaw&amp;nbsp;@test test&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;==================&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If you are following the same pattern and it does not work, please post the exact procedure used.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Dan&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The above should print out the word test on the terminal.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jul 2016 21:41:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880545#M28973</guid>
      <dc:creator>abrsvc</dc:creator>
      <dc:date>2016-07-20T21:41:57Z</dc:date>
    </item>
    <item>
      <title>Re: FTP and OpenVMS command file symbols</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880547#M28974</link>
      <description>&lt;P&gt;Missed the actual problem...&lt;/P&gt;&lt;P&gt;If you are attempting to translate P1 once you have invoked FTP, it wont work. &amp;nbsp;To do what you want may take a extra step or two. &amp;nbsp;Please describe EXACTLY what you are trying to do so we can provide a simple solution.&lt;/P&gt;&lt;P&gt;Dan&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jul 2016 21:43:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880547#M28974</guid>
      <dc:creator>abrsvc</dc:creator>
      <dc:date>2016-07-20T21:43:39Z</dc:date>
    </item>
    <item>
      <title>Re: FTP and OpenVMS command file symbols</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880552#M28975</link>
      <description>&lt;P&gt;&amp;gt; Please describe EXACTLY what you are trying to do [...]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Usually a good idea.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; On VMS, scripting the simple FTP client may be difficult.&amp;nbsp; In many&lt;BR /&gt;cases (especially single-file transfers), COPY /FTP can be much easier.&lt;BR /&gt;(But may be less efficient for multi-file transfers, using a new&lt;BR /&gt;connection for each one.)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; help copy /ftp&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; For fetch ("get") operations, Wget can work well.&amp;nbsp; There exists a&lt;BR /&gt;Wput program for doing "put" operations, and I may have an old one lying&lt;BR /&gt;around somewhere, but no bets on its condition.&amp;nbsp; I don't use it, but&lt;BR /&gt;cURL could be worth a look, too.&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;A href="http://antinode.info/dec/sw/wget.html" target="_blank"&gt;http://antinode.info/dec/sw/wget.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jul 2016 22:10:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880552#M28975</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2016-07-20T22:10:00Z</dc:date>
    </item>
    <item>
      <title>Re: FTP and OpenVMS command file symbols</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880553#M28976</link>
      <description>&lt;P&gt;&amp;gt; I am working with OpenVMS V8.3-1H1 on an Itanium HP Integrity 2660.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; For future reference, actual output from:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tcpip show version&lt;/P&gt;&lt;P&gt;can be more informative than any (less complete) summary.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jul 2016 22:14:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880553#M28976</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2016-07-20T22:14:46Z</dc:date>
    </item>
    <item>
      <title>Re: FTP and OpenVMS command file symbols</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880560#M28977</link>
      <description>&lt;P&gt;It would have helped if you showed your command procedure - with sensitive information removed.&lt;/P&gt;&lt;P&gt;P1 is a DCL symbol (or variable), which is only substituted (or expanded) in the DCL context. When you enter the FTP command you can use DCL symbols for the command arguments/parameters. But once the&amp;nbsp;FTP program runs and prompts you for an FTP command you are no longer in a DCL context. The PUT command is in the program context and there P1 has no definition (or value).&lt;/P&gt;&lt;P&gt;You need to let DCL substitute the symbols and write that to the input for FTP.&amp;nbsp;FTP reads its input from SYS$INPUT or whatever you direct it to with /INPUT. So either redirect SYS$INPUT or use /INPUT.&lt;/P&gt;&lt;P&gt;Usually this is done by writing an input file - in the DCL context, so with the WRITE command. You can use the PIPE command and WRITE to write the SYS$INPUT for FTP, something like&lt;/P&gt;&lt;PRE&gt;$&amp;nbsp;pipe write sys$output "put ''p1' ''p1'" |ftp host/username=remote-username/password=remote-password&lt;/PRE&gt;&lt;P&gt;Obviously you need to have the remote username and the password in this command. I don't know how you did this in your command procedure and whether this is OK in&amp;nbsp;your environment.&lt;/P&gt;&lt;P&gt;And then there are other tools for example COPY/FTP, which are easier to use from the DCL command line - that is with DCL symbols.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jul 2016 22:28:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880560#M28977</guid>
      <dc:creator>H.Becker</dc:creator>
      <dc:date>2016-07-20T22:28:33Z</dc:date>
    </item>
    <item>
      <title>Re: FTP and OpenVMS command file symbols</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880910#M28978</link>
      <description>&lt;P&gt;&lt;A href="http://h71000.www7.hp.com/doc/83final/ba548_90007/ch07s02.html" target="_blank"&gt;The preferred command for network file transfers is scp or sftp with the "-B" option and with certificates in place of passwords&lt;/A&gt;&amp;nbsp;(and &lt;A href="http://www3.sympatico.ca/n.rieck/docs/openvms_notes_ssh2.html" target="_blank"&gt;an ssh and sftp intro&lt;/A&gt;), but — if complete&amp;nbsp;data insecurity, well-known problems with network firewalls, and the exposure of server passwords don't dissuade you — then&amp;nbsp;&lt;A href="http://labs.hoffmanlabs.com/node/136" target="_blank"&gt;use the COPY /FTP command&lt;/A&gt; here.&amp;nbsp;&lt;/P&gt;&lt;P&gt;DCL symbol substitution is only available at the $ DCL command prompt (either prompting interactively, or within a command line within a DCL command procedure beginning with $); when DCL is prompting and processing the command. &amp;nbsp; Within a tool or a utility such as FTP or from&amp;nbsp;&lt;A href="http://labs.hoffmanlabs.com/node/1341" target="_blank"&gt;from within the OpenVMS linker,&lt;/A&gt; no DCL symbol substitutions are honored.&lt;/P&gt;&lt;P&gt;Please also upgrade to HPE OpenVMS I64 V8.4 with current OpenVMS patches, or potentially to VSI OpenVMS I64 V8.4-2; to a more recent release&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jul 2016 19:33:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/ftp-and-openvms-command-file-symbols/m-p/6880910#M28978</guid>
      <dc:creator>Hoff</dc:creator>
      <dc:date>2016-07-21T19:33:19Z</dc:date>
    </item>
  </channel>
</rss>

