<?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: Unix Command needed in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853057#M826191</link>
    <description>you can determine what files the process has open using lsof&lt;BR /&gt;&lt;BR /&gt;check the lsof for 64 bit here&lt;BR /&gt;&lt;BR /&gt;&lt;A href="ftp://coast.cs.purdue.edu/pub/tools/unix/sysutils/lsof/binaries/hpux/" target="_blank"&gt;ftp://coast.cs.purdue.edu/pub/tools/unix/sysutils/lsof/binaries/hpux/&lt;/A&gt; &lt;BR /&gt;&lt;BR /&gt;Thanks</description>
    <pubDate>Wed, 27 Nov 2002 09:33:51 GMT</pubDate>
    <dc:creator>T G Manikandan</dc:creator>
    <dc:date>2002-11-27T09:33:51Z</dc:date>
    <item>
      <title>Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853052#M826186</link>
      <description>I'm willing to use the "ps" command in order to detect a used/locked file in a specific directory but this command shows/displays me the similar files used by some processes. Would you please assist me in this case.&lt;BR /&gt;&lt;BR /&gt;I've used  this command:&lt;BR /&gt;&lt;BR /&gt;$ ps -aef | grep PAYXTR.LIS&lt;BR /&gt;===============================================&lt;BR /&gt;ebokoko 21248 21232  0 10:22:15 pts/tk    0:00 vi /consult/6/runs/users/S.O./PAYXTR.LIS&lt;BR /&gt;&lt;BR /&gt;con6 21156 20746  0 10:18:04 pts/tf    0:00 vi /consult/6/users/S.O./PAYXTR.LIS&lt;BR /&gt;&lt;BR /&gt;root 21227 21192  0 10:20:53 pts/tj    0:00 vi PAYXTR.LIS&lt;BR /&gt;===============================================&lt;BR /&gt;&lt;BR /&gt;Thanks.&lt;BR /&gt;&lt;BR /&gt;E.Armand-Blaise&lt;BR /&gt;</description>
      <pubDate>Wed, 27 Nov 2002 09:23:59 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853052#M826186</guid>
      <dc:creator>Bokoko</dc:creator>
      <dc:date>2002-11-27T09:23:59Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853053#M826187</link>
      <description>Hi,&lt;BR /&gt;Are you perhaps looking for "fuser -cu" ?&lt;BR /&gt;Check "man fuser".&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Tom</description>
      <pubDate>Wed, 27 Nov 2002 09:27:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853053#M826187</guid>
      <dc:creator>Tom Geudens</dc:creator>
      <dc:date>2002-11-27T09:27:53Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853054#M826188</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;perhaps the LSOF utility will help:&lt;BR /&gt;&lt;BR /&gt;$ lsof +aL1 /usr&lt;BR /&gt;&lt;BR /&gt;COMMAND  PID   USER   FD   TYPE DEVICE SIZE/OFF NODE NAME&lt;BR /&gt;tail    2790   root    0r  VREG 64,0x4 13394720   97 /home (/dev/vg00/lvol4)&lt;BR /&gt;&lt;BR /&gt;You can download it by:&lt;BR /&gt;&lt;A href="http://hpux.asknet.de/hppd/hpux/Sysadmin/lsof-4.64/" target="_blank"&gt;http://hpux.asknet.de/hppd/hpux/Sysadmin/lsof-4.64/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Or perhaps the FUSER command helps also?! ;-)&lt;BR /&gt;&lt;BR /&gt;Please try it.&lt;BR /&gt;&lt;BR /&gt;Best regards,&lt;BR /&gt;Armin</description>
      <pubDate>Wed, 27 Nov 2002 09:29:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853054#M826188</guid>
      <dc:creator>Armin Feller</dc:creator>
      <dc:date>2002-11-27T09:29:34Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853055#M826189</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;You can use fuser -u file_name. This shows the users and pids that have access to the file/directory.&lt;BR /&gt;&lt;BR /&gt;HTH, Vicente.</description>
      <pubDate>Wed, 27 Nov 2002 09:29:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853055#M826189</guid>
      <dc:creator>Vicente Sanchez_3</dc:creator>
      <dc:date>2002-11-27T09:29:44Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853056#M826190</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Try using fuser to list processes that have the file open, e.g.&lt;BR /&gt;&lt;BR /&gt;# fuser /var/adm/syslog/syslog.log&lt;BR /&gt;/var/adm/syslog/syslog.log:      410o&lt;BR /&gt;&lt;BR /&gt;# ps -fp 410&lt;BR /&gt;     UID   PID  PPID  C    STIME TTY       TIME COMMAND&lt;BR /&gt;    root   410     1  0  Nov 24  ?         0:01 /usr/sbin/syslogd -D&lt;BR /&gt;#&lt;BR /&gt;&lt;BR /&gt;Rgds, Robin</description>
      <pubDate>Wed, 27 Nov 2002 09:31:10 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853056#M826190</guid>
      <dc:creator>Robin Wakefield</dc:creator>
      <dc:date>2002-11-27T09:31:10Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853057#M826191</link>
      <description>you can determine what files the process has open using lsof&lt;BR /&gt;&lt;BR /&gt;check the lsof for 64 bit here&lt;BR /&gt;&lt;BR /&gt;&lt;A href="ftp://coast.cs.purdue.edu/pub/tools/unix/sysutils/lsof/binaries/hpux/" target="_blank"&gt;ftp://coast.cs.purdue.edu/pub/tools/unix/sysutils/lsof/binaries/hpux/&lt;/A&gt; &lt;BR /&gt;&lt;BR /&gt;Thanks</description>
      <pubDate>Wed, 27 Nov 2002 09:33:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853057#M826191</guid>
      <dc:creator>T G Manikandan</dc:creator>
      <dc:date>2002-11-27T09:33:51Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853058#M826192</link>
      <description>Thank you for your reply.&lt;BR /&gt;&lt;BR /&gt;The preview command "fuser" is looking for a file system mounted on this file "PAYXTR.LIS". However, how to know exactly that a file is locked by a user (file in a specific directory).?</description>
      <pubDate>Wed, 27 Nov 2002 09:37:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853058#M826192</guid>
      <dc:creator>Bokoko</dc:creator>
      <dc:date>2002-11-27T09:37:19Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853059#M826193</link>
      <description>I,m still busy to test the "fuser" command and the "ps -fp" one. &lt;BR /&gt;&lt;BR /&gt;For the utility, I can't use it because I'm running the B.11.00 32 bits.&lt;BR /&gt;&lt;BR /&gt;Many thanks.&lt;BR /&gt;</description>
      <pubDate>Wed, 27 Nov 2002 09:59:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853059#M826193</guid>
      <dc:creator>Bokoko</dc:creator>
      <dc:date>2002-11-27T09:59:36Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853060#M826194</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;if you are looking vor 'lsof', please go to following URL:&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.asknet.de" target="_blank"&gt;http://hpux.asknet.de&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;and search for 'lsof', I'm sure you will find a version for HPUX 11.00 (32bit).&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Armin</description>
      <pubDate>Wed, 27 Nov 2002 10:04:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853060#M826194</guid>
      <dc:creator>Armin Feller</dc:creator>
      <dc:date>2002-11-27T10:04:32Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853061#M826195</link>
      <description>for 32 bit its here&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.connect.org.uk/hppd/hpux/Sysadmin/lsof-4.64/" target="_blank"&gt;http://hpux.connect.org.uk/hppd/hpux/Sysadmin/lsof-4.64/&lt;/A&gt;</description>
      <pubDate>Wed, 27 Nov 2002 10:13:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853061#M826195</guid>
      <dc:creator>T G Manikandan</dc:creator>
      <dc:date>2002-11-27T10:13:39Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853062#M826196</link>
      <description>I wrote named "BISLOCK". The purpose is to check if the PAYXTR.LIS file is opened by another User (file in the current directory : /consult/6/users/S.O. )&lt;BR /&gt;&lt;BR /&gt;I'd like to combine the both commands "fuser" and "ps -pf" . would you assist me. This is the contain of the script "BISLOCK" which receives two parameters :&lt;BR /&gt;&lt;BR /&gt;$1 = /consult/6/users/S.O. &lt;BR /&gt;$2 = PAYXTR.LIS&lt;BR /&gt;&lt;BR /&gt;==============================================&lt;BR /&gt;i=0&lt;BR /&gt;directory=$1;export directory&lt;BR /&gt;payxtract=$2;export payxtract&lt;BR /&gt;files=`echo $directory"/"$payxtract`;export files&lt;BR /&gt;&lt;BR /&gt;LOOP=y;   export LOOP&lt;BR /&gt;#&lt;BR /&gt;while [ $LOOP = y ]&lt;BR /&gt;do&lt;BR /&gt;        # -- Verify that $2 is not locked&lt;BR /&gt;             by an Online User --&lt;BR /&gt;        &lt;BR /&gt;        i=`ps -aef |grep $files|wc -l`&lt;BR /&gt;&lt;BR /&gt;        # if the return value is not 0 then&lt;BR /&gt;          the file is in use.&lt;BR /&gt;        &lt;BR /&gt;        if [[ $i != 0 ]]&lt;BR /&gt;        then&lt;BR /&gt;           {echo ERROR CYBMON Problem&lt;BR /&gt;            Accessing File $2&lt;BR /&gt;            sleep 20&lt;BR /&gt;           }&lt;BR /&gt;        else&lt;BR /&gt;            LOOP=n;    export LOOP&lt;BR /&gt;            break&lt;BR /&gt;        fi&lt;BR /&gt;#&lt;BR /&gt;done&lt;BR /&gt;#&lt;BR /&gt;</description>
      <pubDate>Wed, 27 Nov 2002 12:09:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853062#M826196</guid>
      <dc:creator>Bokoko</dc:creator>
      <dc:date>2002-11-27T12:09:44Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853063#M826197</link>
      <description>As already said, fuser -c should be your base. Use it from a mount point, and it'll show all processes that use any file on the mounted file system.&lt;BR /&gt;&lt;BR /&gt;lsof is the perfect tool - no, realy - to dig into problems you face. Both fuser and ps do not offer enough interface options to get to the bones. lsof does. Learn to use lsof. Install it yesterday.</description>
      <pubDate>Wed, 27 Nov 2002 12:18:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853063#M826197</guid>
      <dc:creator>H.Merijn Brand (procura</dc:creator>
      <dc:date>2002-11-27T12:18:04Z</dc:date>
    </item>
    <item>
      <title>Re: Unix Command needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853064#M826198</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;If you want to see the busy files in a directory:&lt;BR /&gt;cd /directory&lt;BR /&gt;fuser * .??*&lt;BR /&gt;&lt;BR /&gt;lsof is much more functional and returns more information than fuser however fuser works fine for simple checks.&lt;BR /&gt;&lt;BR /&gt;Darrell</description>
      <pubDate>Wed, 27 Nov 2002 19:14:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-command-needed/m-p/2853064#M826198</guid>
      <dc:creator>Darrell Allen</dc:creator>
      <dc:date>2002-11-27T19:14:30Z</dc:date>
    </item>
  </channel>
</rss>

