<?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 lib$spawn problem in Operating System - OpenVMS</title>
    <link>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6039439#M28527</link>
    <description>&lt;P&gt;We have an old application working for about 20 years&lt;BR /&gt;without major problems on a MicroVAX 3100 running OpenVMS 6.2.&lt;BR /&gt;&lt;BR /&gt;There are a lot of detached processes, one of them&lt;BR /&gt;starting a subprocess every 8 hours to transfer data&lt;BR /&gt;from the previous working shift to another system.&lt;BR /&gt;The source code (VAX-FORTRAN) looks like this:&lt;BR /&gt;&lt;BR /&gt;...&lt;BR /&gt;open a file&lt;BR /&gt;write some data to that file&lt;BR /&gt;close that file&lt;BR /&gt;&lt;BR /&gt;RTC = LIB$SPAWN (SPAWN_CMD,,SPAWN_OUT,CLI$M_NOWAIT)&lt;BR /&gt;IF (.NOT. RTC) write message to Logfile&lt;BR /&gt;&lt;BR /&gt;Since some weeks this doesn't work anymore.&lt;BR /&gt;RTC is 2264 which translates to %SYSTEM-W-MBFULL, mailbox is full.&lt;BR /&gt;&lt;BR /&gt;I know lib$spawn is using a mailbox to transfer&lt;BR /&gt;symbol table, logical names and so on.&lt;BR /&gt;&lt;BR /&gt;I tried to increase DEFMBXBUFQUO and DEFMBXMXMSG&lt;BR /&gt;one value at a time, but it still does not work.&lt;BR /&gt;&lt;BR /&gt;I am sure that after a reboot everything will work fine&lt;BR /&gt;for a long period as it does in the past.&lt;BR /&gt;&lt;BR /&gt;But I'd like to understand what is happening.&lt;BR /&gt;&lt;BR /&gt;Is there a chance ?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;dschwarz&lt;/P&gt;</description>
    <pubDate>Wed, 24 Apr 2013 07:55:07 GMT</pubDate>
    <dc:creator>dschwarz</dc:creator>
    <dc:date>2013-04-24T07:55:07Z</dc:date>
    <item>
      <title>lib$spawn problem</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6039439#M28527</link>
      <description>&lt;P&gt;We have an old application working for about 20 years&lt;BR /&gt;without major problems on a MicroVAX 3100 running OpenVMS 6.2.&lt;BR /&gt;&lt;BR /&gt;There are a lot of detached processes, one of them&lt;BR /&gt;starting a subprocess every 8 hours to transfer data&lt;BR /&gt;from the previous working shift to another system.&lt;BR /&gt;The source code (VAX-FORTRAN) looks like this:&lt;BR /&gt;&lt;BR /&gt;...&lt;BR /&gt;open a file&lt;BR /&gt;write some data to that file&lt;BR /&gt;close that file&lt;BR /&gt;&lt;BR /&gt;RTC = LIB$SPAWN (SPAWN_CMD,,SPAWN_OUT,CLI$M_NOWAIT)&lt;BR /&gt;IF (.NOT. RTC) write message to Logfile&lt;BR /&gt;&lt;BR /&gt;Since some weeks this doesn't work anymore.&lt;BR /&gt;RTC is 2264 which translates to %SYSTEM-W-MBFULL, mailbox is full.&lt;BR /&gt;&lt;BR /&gt;I know lib$spawn is using a mailbox to transfer&lt;BR /&gt;symbol table, logical names and so on.&lt;BR /&gt;&lt;BR /&gt;I tried to increase DEFMBXBUFQUO and DEFMBXMXMSG&lt;BR /&gt;one value at a time, but it still does not work.&lt;BR /&gt;&lt;BR /&gt;I am sure that after a reboot everything will work fine&lt;BR /&gt;for a long period as it does in the past.&lt;BR /&gt;&lt;BR /&gt;But I'd like to understand what is happening.&lt;BR /&gt;&lt;BR /&gt;Is there a chance ?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;dschwarz&lt;/P&gt;</description>
      <pubDate>Wed, 24 Apr 2013 07:55:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6039439#M28527</guid>
      <dc:creator>dschwarz</dc:creator>
      <dc:date>2013-04-24T07:55:07Z</dc:date>
    </item>
    <item>
      <title>Re: lib$spawn problem</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6039625#M28528</link>
      <description>Just as a doublecheck, how did you get that value? Is the number actually in decimal? In HEX, that value translates to:&lt;BR /&gt;%SYSTEM-F-INSSWAPSPACE, insufficient swap file space available&lt;BR /&gt;&lt;BR /&gt;Check for that as well.&lt;BR /&gt;&lt;BR /&gt;DAn</description>
      <pubDate>Wed, 24 Apr 2013 11:13:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6039625#M28528</guid>
      <dc:creator>abrsvc</dc:creator>
      <dc:date>2013-04-24T11:13:58Z</dc:date>
    </item>
    <item>
      <title>Re: lib$spawn problem</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6039805#M28529</link>
      <description>&lt;P&gt;Interesting thought Dan! Wouldn't be the first time.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As one increases&amp;nbsp;&lt;SPAN&gt;DEFMBXBUFQUO, it eats more into the process byte limit quota.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;So you also need to check out: SYSGEN&amp;nbsp;&lt;SPAN&gt;PQL_MBYTLM and/or AUTHORIZE BYTLM&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Hein.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Apr 2013 13:39:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6039805#M28529</guid>
      <dc:creator>Hein van den Heuvel</dc:creator>
      <dc:date>2013-04-24T13:39:55Z</dc:date>
    </item>
    <item>
      <title>Re: lib$spawn problem</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6044753#M28531</link>
      <description>&lt;P&gt;Are you explicitly using mailboxes anywhere in this code?&amp;nbsp; If so, has something written to it but the other party not read from it?&amp;nbsp; (IIRC, some simple DCL to open the mailbox and read a record from it then close it will solve that problem.)&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;How many mailbox devices exist on your system?&amp;nbsp; Tens? Hundreds?&amp;nbsp; Maybe they are not being cleared up or not being re-used by your application or by VMS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Did anything odd happen when this first occurred or in the execution prior to that?&amp;nbsp; I'm wondering if some other failure has caused a mailbox to hang around.&lt;/P&gt;</description>
      <pubDate>Sun, 28 Apr 2013 22:58:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6044753#M28531</guid>
      <dc:creator>John McL</dc:creator>
      <dc:date>2013-04-28T22:58:13Z</dc:date>
    </item>
    <item>
      <title>Re: lib$spawn problem</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6044865#M28532</link>
      <description>&lt;P&gt;First why are you using CLI$M_NOWAIT? Since you're not specifying a completion status address or AST, you have no way of determining if/when the subprocess competes, or the completion status. The function status just tells you about the success or failure of starting the subprocess.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How frequently does this execute, and what happens if there are two or more subprocesses executing simultaneously?&amp;nbsp;Can they interfere with each other?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There's nothing wrong with writing asynchronous code, but&amp;nbsp;unless&amp;nbsp;there&amp;nbsp;really are no implications of&amp;nbsp;issuing multiple&amp;nbsp;simultaneous commands (rare!) then you&amp;nbsp;should&amp;nbsp;implement&amp;nbsp;some kind of syncronisation code.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What is the value of SPAWN_CMD and SPAWN_OUT at the time of the call?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Stuff sent through the mailbox to the subprocess includes the command, I/O specifications, process logical names and CLI symbols.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do you really need process logical names and symbols to be sent to the subprocess?&amp;nbsp;Have any new symbols or logical names&amp;nbsp;been defined?&amp;nbsp;If they aren't required does adding flags CLI$M_NOLOGNAM and/or CLI$M_NOCLISYM make any difference? (it will make the SPAWN faster too).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Apr 2013 00:59:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/lib-spawn-problem/m-p/6044865#M28532</guid>
      <dc:creator>John Gillings</dc:creator>
      <dc:date>2013-04-29T00:59:03Z</dc:date>
    </item>
  </channel>
</rss>

