<?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: finding out another process's default directory? in Operating System - OpenVMS</title>
    <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101228#M89229</link>
    <description>{{{Regardless of the above, bear in mind that the current default directory can be a rather ornery beast, depending as it does on any number of process private logical names, particularly where the default directory is set to a search list.}}}&lt;BR /&gt;&lt;BR /&gt;That, and it's wicked fickle.</description>
    <pubDate>Wed, 02 Apr 2008 20:08:13 GMT</pubDate>
    <dc:creator>Hoff</dc:creator>
    <dc:date>2008-04-02T20:08:13Z</dc:date>
    <item>
      <title>finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101224#M89225</link>
      <description>What is the easiest way to determine the current default directory for another process under Alpha VMS 7.3-2 ?&lt;BR /&gt;&lt;BR /&gt;TIA</description>
      <pubDate>Wed, 02 Apr 2008 19:25:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101224#M89225</guid>
      <dc:creator>Jess Goodman</dc:creator>
      <dc:date>2008-04-02T19:25:45Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101225#M89226</link>
      <description>What do you mean, sys$login of this user or the  directory in which he is at the moment ?</description>
      <pubDate>Wed, 02 Apr 2008 19:34:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101225#M89226</guid>
      <dc:creator>labadie_1</dc:creator>
      <dc:date>2008-04-02T19:34:53Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101226#M89227</link>
      <description>Assuming this is not a discussion of SYS$LOGIN or SYS$LOGIN_DEVICE, the RMS parsing defaults are process-private AFAIK.&lt;BR /&gt;&lt;BR /&gt;This information is maintained within some process logical names and within a system service, and AFAIK there are no related APIs to access the associated SYS$DISK logical name and the SYS$SETDDIR system service directory information across processes.&lt;BR /&gt;&lt;BR /&gt;Accordingly, the best approach is to have a cooperating application communicate that setting as needed.&lt;BR /&gt;&lt;BR /&gt;To confirm this, made a quick pass through the sys$getjpi itemcodes for OpenVMS V8.3, and see nothing relevant listed.   This service would be the logical spot to implement this.&lt;BR /&gt;&lt;BR /&gt;Kernel-mode hackery is certainly feasible.&lt;BR /&gt;</description>
      <pubDate>Wed, 02 Apr 2008 19:38:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101226#M89227</guid>
      <dc:creator>Hoff</dc:creator>
      <dc:date>2008-04-02T19:38:52Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101227#M89228</link>
      <description>If this is required purely for informational purposes then the answer is that VMS itself does not provide that functionality.&lt;BR /&gt;&lt;BR /&gt;If this is required because the application design really needs this then I would suggest changing the application design.&lt;BR /&gt;&lt;BR /&gt;Regardless of the above, bear in mind that the current default directory can be a rather ornery beast, depending as it does on any number of process private logical names, particularly where the default directory is set to a search list.</description>
      <pubDate>Wed, 02 Apr 2008 20:02:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101227#M89228</guid>
      <dc:creator>Derek Garson</dc:creator>
      <dc:date>2008-04-02T20:02:21Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101228#M89229</link>
      <description>{{{Regardless of the above, bear in mind that the current default directory can be a rather ornery beast, depending as it does on any number of process private logical names, particularly where the default directory is set to a search list.}}}&lt;BR /&gt;&lt;BR /&gt;That, and it's wicked fickle.</description>
      <pubDate>Wed, 02 Apr 2008 20:08:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101228#M89229</guid>
      <dc:creator>Hoff</dc:creator>
      <dc:date>2008-04-02T20:08:13Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101229#M89230</link>
      <description>Some server processes on our systems sometimes start writing temporary files to a directory that should never be used for temporary files.  The program that is writing the file uses the current default directory (instead of SYS$SCRATCH like it should, but it's not our code and it probably just uses a C RTL call, TMPNAM or TMPFILE).&lt;BR /&gt;&lt;BR /&gt;I can identify the process that wrote the files *after* the fact from security audits.  But I would like to identify when one of these server processes actually changes their default directory by monitoring this important process attribute somehow.&lt;BR /&gt;&lt;BR /&gt;I know there is no $GETJPI item code or other API for it.  I can find out the current default device by getting the tranlation of SYS$DISK via ANALYZE/SYSTEM and CLUE PROCESS/LOGICAL.  So I was looking for a SDA method or a kernel-mode program that could return the current directory.  (On my VAX 6.2 systems we have a program called "P" that can do this.)</description>
      <pubDate>Wed, 02 Apr 2008 20:52:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101229#M89230</guid>
      <dc:creator>Jess Goodman</dc:creator>
      <dc:date>2008-04-02T20:52:45Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101230#M89231</link>
      <description>The way to get this is to queue a kernel mode AST to the PID in question and then pick up PIO$GT_DDSTRING in the context of the targetted PID.&lt;BR /&gt;&lt;BR /&gt;Brian 'VAXman' Schenkenberger made examples of this back in 1993. And there is also an even older 'lib_default_dir' routine out there.&lt;BR /&gt;&lt;BR /&gt;Not sure where that stands with OpenVMS versions, Itanium ports and so on.&lt;BR /&gt;&lt;BR /&gt;With SDA you can most certainly just read it:&lt;BR /&gt;ANAL/SYSTEM&lt;BR /&gt;SDA&amp;gt; SET PROC AUDIT_SERVER&lt;BR /&gt;SDA&amp;gt; ex PIO$GT_DDSTRING;20&lt;BR /&gt;00000000 00000000 00000000 00000000 00000000 0000005D 45584553 59535B08  .[SYSEXE].......................     00000000.7FFD0290&lt;BR /&gt;&lt;BR /&gt;There's your counted string.&lt;BR /&gt;&lt;BR /&gt;SDA&amp;gt; set proc hein&lt;BR /&gt;SDA&amp;gt; ex PIO$GT_DDSTRING;20&lt;BR /&gt;00000000 00000000 00005D4E 4945482E 52455355 5F455652 45535543 45445B15  .[DECUSERVE_USER.HEIN]..........     00000000.7FFD0290&lt;BR /&gt;&lt;BR /&gt;Google is your friend.&lt;BR /&gt;&lt;BR /&gt;hth,&lt;BR /&gt;Hein.&lt;BR /&gt;</description>
      <pubDate>Wed, 02 Apr 2008 23:23:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101230#M89231</guid>
      <dc:creator>Hein van den Heuvel</dc:creator>
      <dc:date>2008-04-02T23:23:08Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101231#M89232</link>
      <description>Re Hein.&lt;BR /&gt;&lt;BR /&gt;Yeah, that DOES get you the -directory-; but _NOT_ the device on which to search that directory. Which might be a Concealed Device, and/or a searchlist. Both are already demonstrated by [SYSEXE] ; which normally should reside in SYS$SYSROOT: , which is both.&lt;BR /&gt;&lt;BR /&gt;This looks to be only half the answer.&lt;BR /&gt;&lt;BR /&gt;Proost.&lt;BR /&gt;&lt;BR /&gt;Have one on me.&lt;BR /&gt;&lt;BR /&gt;jpe</description>
      <pubDate>Thu, 03 Apr 2008 08:31:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101231#M89232</guid>
      <dc:creator>Jan van den Ende</dc:creator>
      <dc:date>2008-04-03T08:31:53Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101232#M89233</link>
      <description>&lt;!--!*#--&gt;Thanks Hein, that was what I was looking for.  I did GOOGLE but I guess I didn't know what to search for.&lt;BR /&gt;&lt;BR /&gt;Jan, that was the entire answer to my quesion -as I already said you can get the current translation of SYS$DISK from SDA's CLUE PROCESS/LOGICAL command.&lt;BR /&gt;&lt;BR /&gt;Thread closed.</description>
      <pubDate>Thu, 03 Apr 2008 14:16:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101232#M89233</guid>
      <dc:creator>Jess Goodman</dc:creator>
      <dc:date>2008-04-03T14:16:38Z</dc:date>
    </item>
    <item>
      <title>Re: finding out another process's default directory?</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101233#M89234</link>
      <description>Regarding Hein's mention of queueing kernel-mode ASTs, VMS made this a lot easier and safer on Alpha and Integrity by providing the kernel-level routine EXE$READ_PROCESS.  It does the AST queueing to fetch data from another process's context.  It still has to be called from kernel-mode, but it wouldn't be very hard to write a kernel-mode routine that will get the PIO$GT_DDSTRING value for another process using EXE$READ_PROCESS.&lt;BR /&gt;&lt;BR /&gt;My GETCMD utility makes use of this (albeit in BLISS):&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://vms.process.com/ftp/vms-freeware/fileserv/getcmd.zip" target="_blank"&gt;http://vms.process.com/ftp/vms-freeware/fileserv/getcmd.zip&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;(The VAX version still does the old queue-an-AST method.)&lt;BR /&gt;&lt;BR /&gt;Hunter</description>
      <pubDate>Fri, 04 Apr 2008 13:31:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/finding-out-another-process-s-default-directory/m-p/5101233#M89234</guid>
      <dc:creator>Hunter Goatley</dc:creator>
      <dc:date>2008-04-04T13:31:49Z</dc:date>
    </item>
  </channel>
</rss>

