<?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 checking port number in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821603#M86640</link>
    <description>HI,&lt;BR /&gt;&lt;BR /&gt;How do I check if a particular port number is already being used by another process in a client-server communication? &lt;BR /&gt;&lt;BR /&gt;I did:&lt;BR /&gt;# netstat |grep 7412 &lt;BR /&gt;which displays all machines communicating with the local machines on the respective port numbers. I'd have to then check each port numbers used for within the local machine to see if the number which I'm looking for is that list or not.&lt;BR /&gt;&lt;BR /&gt;Are there any other more efficient way of doing this? Or could anyone show me how I could write a script do check if a particular port number is already been used, then generate another number?&lt;BR /&gt;&lt;BR /&gt;Thanks.&lt;BR /&gt;</description>
    <pubDate>Wed, 09 Oct 2002 06:49:21 GMT</pubDate>
    <dc:creator>Chern Jian Leaw</dc:creator>
    <dc:date>2002-10-09T06:49:21Z</dc:date>
    <item>
      <title>checking port number</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821603#M86640</link>
      <description>HI,&lt;BR /&gt;&lt;BR /&gt;How do I check if a particular port number is already being used by another process in a client-server communication? &lt;BR /&gt;&lt;BR /&gt;I did:&lt;BR /&gt;# netstat |grep 7412 &lt;BR /&gt;which displays all machines communicating with the local machines on the respective port numbers. I'd have to then check each port numbers used for within the local machine to see if the number which I'm looking for is that list or not.&lt;BR /&gt;&lt;BR /&gt;Are there any other more efficient way of doing this? Or could anyone show me how I could write a script do check if a particular port number is already been used, then generate another number?&lt;BR /&gt;&lt;BR /&gt;Thanks.&lt;BR /&gt;</description>
      <pubDate>Wed, 09 Oct 2002 06:49:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821603#M86640</guid>
      <dc:creator>Chern Jian Leaw</dc:creator>
      <dc:date>2002-10-09T06:49:21Z</dc:date>
    </item>
    <item>
      <title>Re: checking port number</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821604#M86641</link>
      <description>You could try lsof..&lt;BR /&gt;&lt;A href="http://hpux.cs.utah.edu/" target="_blank"&gt;http://hpux.cs.utah.edu/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Later,&lt;BR /&gt;Bill</description>
      <pubDate>Wed, 09 Oct 2002 06:57:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821604#M86641</guid>
      <dc:creator>Bill McNAMARA_1</dc:creator>
      <dc:date>2002-10-09T06:57:38Z</dc:date>
    </item>
    <item>
      <title>Re: checking port number</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821605#M86642</link>
      <description>You need to download and install 'lsof' from the HP porting centre.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.cs.utah.edu/hppd/hpux/Sysadmin/lsof-4.61/" target="_blank"&gt;http://hpux.cs.utah.edu/hppd/hpux/Sysadmin/lsof-4.61/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;If your after the 64 bit version, this link will help.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x1de9f715edc6d5118ff10090279cd0f9,00.html" target="_blank"&gt;http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x1de9f715edc6d5118ff10090279cd0f9,00.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 09 Oct 2002 06:59:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821605#M86642</guid>
      <dc:creator>Michael Tully</dc:creator>
      <dc:date>2002-10-09T06:59:46Z</dc:date>
    </item>
    <item>
      <title>Re: checking port number</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821606#M86643</link>
      <description>Once you've downloaded and install 'lsof' here is a frew examples of it's usage.&lt;BR /&gt;&lt;BR /&gt;To which files are open for a given process id (pid) &lt;BR /&gt;&lt;BR /&gt;# lsof -p &lt;PID&gt; &lt;BR /&gt;&lt;BR /&gt;To see all the open files associated with a particular command. &lt;BR /&gt;&lt;BR /&gt;# lsof -c midaemon &lt;BR /&gt;&lt;BR /&gt;User name. &lt;BR /&gt;&lt;BR /&gt;# lsof -u &lt;NAME&gt; &lt;BR /&gt;# lsof -u &lt;UID&gt; &lt;BR /&gt;&lt;BR /&gt;processes being used via a socket. &lt;BR /&gt;&lt;BR /&gt;# lsof -i tcp:23 &lt;BR /&gt;# lsof -i udp:123 &lt;BR /&gt;&lt;BR /&gt;&lt;/UID&gt;&lt;/NAME&gt;&lt;/PID&gt;</description>
      <pubDate>Wed, 09 Oct 2002 07:16:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/checking-port-number/m-p/2821606#M86643</guid>
      <dc:creator>Michael Tully</dc:creator>
      <dc:date>2002-10-09T07:16:36Z</dc:date>
    </item>
  </channel>
</rss>

