<?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 bug in dodisk in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/bug-in-dodisk/m-p/3249517#M175136</link>
    <description>I noticed a bug in the script /usr/sbin/acct/dodisk.&lt;BR /&gt;&lt;BR /&gt;If you get a message like :&lt;BR /&gt;"Syntax error at line 1 : `(' is not expected"&lt;BR /&gt;the error comes from the line :&lt;BR /&gt;"# See fstab(4) and sam(1M) for further details on configuring devices."&lt;BR /&gt;in /etc/fstab which is not treated well by the awk script in dodisk. (cf. note 1)&lt;BR /&gt;&lt;BR /&gt;You can modify the dodisk script :&lt;BR /&gt;replace "if (access(diskusg))" [line 64 on HP 11.11]&lt;BR /&gt;by "if (access(diskusg)==1)"&lt;BR /&gt;&lt;BR /&gt;But there is another BIGGER BUG. This script shouldn't look for commented lines but it does it. And, as a result, if you comment out a line in the middle of /etc/fstab, you can't get the diskusage for file systems under this line (cf. note 2).&lt;BR /&gt;&lt;BR /&gt;So, instead of the correction above, it is better to do this one :&lt;BR /&gt;After the line &lt;BR /&gt;"\$3 !~ /swap/           \" [line 51 on HP 11.11]&lt;BR /&gt;you can add :&lt;BR /&gt;"&amp;amp;&amp;amp; \$1 !~ /^#/    \"&lt;BR /&gt;&lt;BR /&gt;It can help before HP correct it.&lt;BR /&gt;Will HP be inform on the bug through this forum, or should I use another procedure ?&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;Marc.</description>
    <pubDate>Thu, 15 Apr 2004 12:56:16 GMT</pubDate>
    <dc:creator>marc seguin</dc:creator>
    <dc:date>2004-04-15T12:56:16Z</dc:date>
    <item>
      <title>bug in dodisk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bug-in-dodisk/m-p/3249517#M175136</link>
      <description>I noticed a bug in the script /usr/sbin/acct/dodisk.&lt;BR /&gt;&lt;BR /&gt;If you get a message like :&lt;BR /&gt;"Syntax error at line 1 : `(' is not expected"&lt;BR /&gt;the error comes from the line :&lt;BR /&gt;"# See fstab(4) and sam(1M) for further details on configuring devices."&lt;BR /&gt;in /etc/fstab which is not treated well by the awk script in dodisk. (cf. note 1)&lt;BR /&gt;&lt;BR /&gt;You can modify the dodisk script :&lt;BR /&gt;replace "if (access(diskusg))" [line 64 on HP 11.11]&lt;BR /&gt;by "if (access(diskusg)==1)"&lt;BR /&gt;&lt;BR /&gt;But there is another BIGGER BUG. This script shouldn't look for commented lines but it does it. And, as a result, if you comment out a line in the middle of /etc/fstab, you can't get the diskusage for file systems under this line (cf. note 2).&lt;BR /&gt;&lt;BR /&gt;So, instead of the correction above, it is better to do this one :&lt;BR /&gt;After the line &lt;BR /&gt;"\$3 !~ /swap/           \" [line 51 on HP 11.11]&lt;BR /&gt;you can add :&lt;BR /&gt;"&amp;amp;&amp;amp; \$1 !~ /^#/    \"&lt;BR /&gt;&lt;BR /&gt;It can help before HP correct it.&lt;BR /&gt;Will HP be inform on the bug through this forum, or should I use another procedure ?&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;Marc.</description>
      <pubDate>Thu, 15 Apr 2004 12:56:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bug-in-dodisk/m-p/3249517#M175136</guid>
      <dc:creator>marc seguin</dc:creator>
      <dc:date>2004-04-15T12:56:16Z</dc:date>
    </item>
    <item>
      <title>Re: bug in dodisk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bug-in-dodisk/m-p/3249518#M175137</link>
      <description>Note 1 :&lt;BR /&gt;&lt;BR /&gt;The line :&lt;BR /&gt;"# See fstab(4) and sam(1M) for further details on configuring devices."&lt;BR /&gt;leads the awk script to test if the command :&lt;BR /&gt;"/usr/lbin/fs/fstab(4)/diskusg"&lt;BR /&gt;exists, which is not true of course. And it should return a 0 code. But, because of the '(', it returns code 2, which is non null, so the test is OK.&lt;BR /&gt;And the script tries to execute it !!!&lt;BR /&gt;&lt;BR /&gt;CQFD</description>
      <pubDate>Thu, 15 Apr 2004 13:00:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bug-in-dodisk/m-p/3249518#M175137</guid>
      <dc:creator>marc seguin</dc:creator>
      <dc:date>2004-04-15T13:00:52Z</dc:date>
    </item>
    <item>
      <title>Re: bug in dodisk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/bug-in-dodisk/m-p/3249519#M175138</link>
      <description>Note 2 :&lt;BR /&gt;&lt;BR /&gt;If your /etc/fstab looks like :&lt;BR /&gt;&lt;BR /&gt;/dev/vg00/lvol4 /opt vxfs delaylog 0 2&lt;BR /&gt;/dev/vg00/lvol5 /tmp vxfs delaylog 0 2&lt;BR /&gt;#/dev/vg00/lvol6 /usr vxfs delaylog 0 2&lt;BR /&gt;/dev/vg00/lvol7 /var vxfs delaylog 0 2&lt;BR /&gt;&lt;BR /&gt;[it is an exemple, it is not realistic]&lt;BR /&gt;&lt;BR /&gt;So the awk script will try to execute :&lt;BR /&gt;/usr/lbin/fs/vxfs/diskusg /dev/vg00/lvol4 /dev/vg00/lvol5 #/dev/vg00/lvol6 /dev/vg00/lvol7&lt;BR /&gt;And because of the '#', the end of the line won't be concerned, though it should.&lt;BR /&gt;&lt;BR /&gt;And you'll get disk usage of two file systems instead of three available !!!&lt;BR /&gt;&lt;BR /&gt;CQFD</description>
      <pubDate>Thu, 15 Apr 2004 13:07:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/bug-in-dodisk/m-p/3249519#M175138</guid>
      <dc:creator>marc seguin</dc:creator>
      <dc:date>2004-04-15T13:07:29Z</dc:date>
    </item>
  </channel>
</rss>

