<sdp_diaglet platform="linux" product="AS1013" set="A300AS1013_lin" title="Oracle Application Server 10g R3 (10.1.3) Preinstall (Linux)" type="A">
<sdp_meta id="$Id: A300AS1013_lin.xml,v 1.14 2012/07/27 18:50:56 mschenke Exp $"/>
<sdp_meta author="JCR" change="Improve Linux Power PC detection" date="20120727" type="history"/>
<sdp_content set="A300AS1013_lin" title="Oracle Application Server 10g R3 (10.1.3) Preinstall (Linux)" type="check">
<sdp_group>

<sdp_rule id="A00010" mode="RECORD" name="OS Type">
<sdp_command type="RDA"><![CDATA[import $OS_TYP,$OS_NAM,$OS_ARC
$BOOK_x86 = "Oracle Application Server Installation Guide 10g Release 3 \
              (10.1.3.1.0) for Linux x86"
$BOOK_I = "Oracle Application Server Installation Guide 10g Release 3 \
              (10.1.3.1.0) for Linux Itanium"
$BOOK_P = "Oracle Application Server Installation Guide 10g Release 3 \
              (10.1.3.1.0) for Linux on POWER"
$BOOK_Z = "Oracle Application Server Installation Guide 10g Release 3 \
              (10.1.3.1.0) for IBM zSeries Based Linux"
if match($OS_ARC,'Intel|AMD',true)
 var $BOOK = $BOOK_x86
elsif match($OS_ARC,'Itanium',true)
 var $BOOK = $BOOK_I
elsif match($OS_ARC,'Power|pSeries',true)
 var $BOOK = $BOOK_P
elsif match($OS_ARC,'zSeries|IBM/S390',true)
 var $BOOK = $BOOK_Z
else
 var $BOOK = $BOOK_x86
call setHcveVariable('$BOOK')
call setHcveResult(concat($OS_TYP,' ',$OS_NAM))
]]></sdp_command>
<sdp_description><![CDATA[This rule retrieves the OS type.]]></sdp_description>
</sdp_rule>

<sdp_rule id="A00020" mode="VERIFY" name="Processor Type ok?">
<sdp_command type="RDA"><![CDATA[import $OS_ARC
var @CPU = ()
call setHcveVariable('@CPU')
if !testFile('r','/proc/cpuinfo')
 return setHcveResult('Cannot access /proc/cpuinfo')
var @CPU = grepFile('/proc/cpuinfo','.')
var ($CPU) = grep(@CPU,'Itanium','if')
call setHcveResult(cond(\
  grep(@CPU,'model name','if'),\
        field('\s+:\s+',1,grep(@CPU,'model name','if')),\
  $CPU, 'Itanium',\
        'Model name not found'))
]]></sdp_command>
<sdp_description><![CDATA[This rule gets the processor type. The minimum requirement for the processor type is Pentium (32-bit).]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Cannot access" result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Cannot access /proc/cpuinfo|Grant read permissions on ``/proc/cpuinfo`` to the user who is logged in.|]]></sdp_action>
<sdp_action result="PASSED"><![CDATA[No action is required.]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00022" mode="VERIFY" name="Processor Speed ok?">
<sdp_command type="RDA"><![CDATA[import @CPU
if !defined($CPU[0])
 return setHcveResult('Cannot access /proc/cpuinfo')
call setHcveResult(field('\s+:\s+',1,grep(@CPU,'cpu MHz','f')))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks for the processor speed. The minimum requirement for the processor speed is 450 MHz or faster.]]></sdp_description>
<sdp_actions>
<sdp_action condition=">=" minimum="450" result="PASSED"><![CDATA[The minimum requirement for the processor speed is met.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[The minimum requirement for the processor speed is 450 MHz or faster.
|*Return Value*|*Action*|
|Processor speed|Use a processor with a speed of 450 MHz or faster.|
|Cannot access /proc/cpuinfo|Grant read permissions to ``/proc/cpuinfo`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00030" mode="VERIFY" name="Network?">
<sdp_command type="RDA"><![CDATA[call setHcveResult(cond(\
  not(testFile('x','/sbin/ifconfig')),     'Cannot access /sbin/ifconfig',\
  grepCommand('/sbin/ifconfig','eth','f'), 'Connected',\
                                           'Not connected. Check log.'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system is connected to a network. You can install Oracle Application Server 10g on a standalone system that is not connected to a network or on a system that is connected to a network. Although both cases are supported, when the system is not connected to a network, you must configure the system to resolve the host name of the computer to either a static IP address or a loopback IP address. To access Oracle Application Server, you must use a local browser. For more information, refer to the appropriate installation guide..]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Connected|Not connected. Check log." result="PASSED"><![CDATA[The system is connected to a network.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Cannot access /sbin/ifconfig|Grant execute permissions ti ``/sbin/ifconfig`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00040" mode="VERIFY" name="Memory Available?">
<sdp_command type="RDA"><![CDATA[var $MEM = undef
call setHcveVariable('$MEM')
if !testFile('r','/proc/meminfo')
 return setHcveResult('Cannot access /proc/meminfo')
var $MEM = field('\s+',1,grepFile('/proc/meminfo','MemTotal','f'))
call setHcveResult(concat($MEM,' KB'))
]]></sdp_command>
<sdp_description><![CDATA[This rule retrieves the available physical memory in KB.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum=" KB$" result="PASSED"><![CDATA[No action is required.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Cannot access /proc/meminfo|Grant read permissions on ``/proc/meminfo`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00042" mode="VERIFY" name="Memory Adequate?">
<sdp_command type="RDA"><![CDATA[import $MEM
call setHcveResult(cond(\
  not(defined($MEM)),      'Cannot access /proc/meminfo',\
  expr('>=',$MEM,1048576), 'Available',\
                           'Need at least 1 GB'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough memory to install Oracle Application Server 10.1.3.0 or later. The minimum requirement is 1 GB.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough memory to install Oracle Application Server 10.1.3.0 or later.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Need at least 1 GB|Increase the memory to 1 GB or more to install Oracle Application Server 10.1.3.0 or later.|
|Cannot access /proc/meminfo|Grant read permissions on ``/proc/meminfo`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00050" mode="VERIFY" name="Disk Space?">
<sdp_command type="RDA"><![CDATA[var $ORACLE_HOME = getEnv('ORACLE_HOME')
var $DF = cond(\
  not($ORACLE_HOME),              'ORACLE_HOME is not set',\
  not(testDir('d',$ORACLE_HOME)), 'Cannot access ORACLE_HOME',\
                                  get_df($ORACLE_HOME))
call setHcveVariable('$DF')
call setHcveResult(cond(isNumber($DF),concat($DF,' KB'),$DF))
]]></sdp_command>
<sdp_description><![CDATA[This rule retrieves the available disk space.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum=" KB$" result="PASSED"><![CDATA[No action is required.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00052" mode="VERIFY" name="Space for 10.1.3.0?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 716800
 var $MIN_DSK = "700 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 921600
 var $MIN_DSK = "900 MB"
}
elsif match($OS_ARC,'Power|pSeries',true)
{var $min = 686080
 var $MIN_DSK = "670 MB"
}
elsif match($OS_ARC,'zSeries|IBM/S390',true)
{var $min = 1174405
 var $MIN_DSK = "1.12 GB"
}
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the AS 10.1.3.0 install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the AS 10.1.3.0 install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the AS 10.1.3.0 install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00054" mode="VERIFY" name="Space for J2EE/SOA (10.1.3.1)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 1048576
 var $MIN_DSK = "1 GB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 1153434
 var $MIN_DSK = "1.1 GB"
}
elsif match($OS_ARC,'Power|pSeries',true)
{var $min = 1216348
 var $MIN_DSK = "1.16 GB"
}
elsif match($OS_ARC,'zSeries|IBM/S390',true)
{var $min = 1205862
 var $MIN_DSK = "1.15 GB"
}
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the J2EE Server and Oracle SOA Suite install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the J2EE Server and Oracle SOA Suite install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the J2EE Server and Oracle SOA Suite install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00056" mode="VERIFY" name="Space for J2EE/Web/SOA (10.1.3.1)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 1101005
 var $MIN_DSK = "1.05 GB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 1258291
 var $MIN_DSK = "1.2 GB"
}
elsif match($OS_ARC,'Power|pSeries',true)
{var $min = 1237320
 var $MIN_DSK = "1.18 GB"
}
elsif match($OS_ARC,'zSeries|IBM/S390',true)
{var $min = 1258291
 var $MIN_DSK = "1.2 GB"
}
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the J2EE Server, Web Server, and Oracle SOA Suite install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the J2EE Server and Oracle SOA Suite install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the J2EE Server, Web Server, and Oracle SOA Suite install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00058" mode="VERIFY" name="Space for J2EE/Web (10.1.3.1)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 665600
 var $MIN_DSK = "650 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 665600
 var $MIN_DSK = "650 MB"
}
elsif match($OS_ARC,'Power|pSeries',true)
{var $min = 849920
 var $MIN_DSK = "830 MB"
}
elsif match($OS_ARC,'zSeries|IBM/S390',true)
{var $min = 870400
 var $MIN_DSK = "850 MB"
}
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the J2EE Server and Web Server install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the J2EE Server and Web Server install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the 2EE Server and Web Server install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00060" mode="VERIFY" name="Space for J2EE (10.1.3.1)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 640000
 var $MIN_DSK = "625 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 768000
 var $MIN_DSK = "750 MB"
}
elsif match($OS_ARC,'Power|pSeries',true)
{var $min = 819200
 var $MIN_DSK = "800 MB"
}
elsif match($OS_ARC,'zSeries|IBM/S390',true)
{var $min = 803840
 var $MIN_DSK = "785 MB"
}
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the J2EE Server install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the J2EE Server install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the 2EE Server install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00062" mode="VERIFY" name="Space for Web (10.1.3.1)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 512000
 var $MIN_DSK = "500 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 665600
 var $MIN_DSK = "650 MB"
}
elsif match($OS_ARC,'Power|pSeries',true)
{var $min = 686080
 var $MIN_DSK = "670 MB"
}
elsif match($OS_ARC,'zSeries|IBM/S390',true)
{var $min = 665600
 var $MIN_DSK = "650 MB"
}
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the Web Server install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the Web Server install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the Web Server install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00064" mode="VERIFY" name="Space for 10.1.3.2?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 806912
 var $MIN_DSK = "788 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 1101005
 var $MIN_DSK = "1.05 GB"
}
elsif match($OS_ARC,'Power|pSeries',true)
 return setHcveResult('Undetermined')
elsif match($OS_ARC,'zSeries|IBM/S390',true)
 return setHcveResult('Undetermined')
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the 10.1.3.2 basic install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the 10.1.3.2 basic install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action condition="==" minimum="Undetermined" result="SKIPPED"><![CDATA[The amount of disk space required on the operating system type has not been determined.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the 10.1.3.2 basic install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00066" mode="VERIFY" name="Space for WebCenter/HTTP (10.1.3.2)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 773120
 var $MIN_DSK = "755 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 1101005
 var $MIN_DSK = "1.05 GB"
}
elsif match($OS_ARC,'Power|pSeries',true)
 return setHcveResult('Undetermined')
elsif match($OS_ARC,'zSeries|IBM/S390',true)
 return setHcveResult('Undetermined')
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the Oracle WebCenter Framework with Oracle HTTP Server install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the Oracle WebCenter Framework with Oracle HTTP Server install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action condition="==" minimum="Undetermined" result="SKIPPED"><![CDATA[The amount of disk space required on the operating system type has not been determined.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the Oracle WebCenter Framework with Oracle HTTP Server install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00068" mode="VERIFY" name="Space for Content Database (10.1.3.2)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 724992
 var $MIN_DSK = "708 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 1048576
 var $MIN_DSK = "1 GB"
}
elsif match($OS_ARC,'Power|pSeries',true)
 return setHcveResult('Undetermined')
elsif match($OS_ARC,'zSeries|IBM/S390',true)
 return setHcveResult('Undetermined')
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the Oracle Content Database install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the Oracle Content Database install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action condition="==" minimum="Undetermined" result="SKIPPED"><![CDATA[The amount of disk space required on the operating system type has not been determined.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the Oracle Content Database install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00070" mode="VERIFY" name="Space for WebCenter (10.1.3.2)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 629760
 var $MIN_DSK = "615 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 913408
 var $MIN_DSK = "892 MB"
}
elsif match($OS_ARC,'Power|pSeries',true)
 return setHcveResult('Undetermined')
elsif match($OS_ARC,'zSeries|IBM/S390',true)
 return setHcveResult('Undetermined')
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the Oracle WebCenter Framework install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the Oracle WebCenter Framework install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action condition="==" minimum="Undetermined" result="SKIPPED"><![CDATA[The amount of disk space required on the operating system type has not been determined.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the Oracle WebCenter Framework install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00072" mode="VERIFY" name="Space for HTTP (10.1.3.2)?">
<sdp_command type="RDA"><![CDATA[import $DF,$OS_ARC
if match($OS_ARC,'Intel|AMD',true)
{var $min = 485376
 var $MIN_DSK = "474 MB"
}
elsif match($OS_ARC,'Itanium',true)
{var $min = 887808
 var $MIN_DSK = "867 MB"
}
elsif match($OS_ARC,'Power|pSeries',true)
 return setHcveResult('Undetermined')
elsif match($OS_ARC,'zSeries|IBM/S390',true)
 return setHcveResult('Undetermined')
else
 return setHcveResult('OS type unidentified')
call setHcveResult(cond(\
  not(isNumber($DF)),  $DF,\
  expr('>=',$DF,$min), 'Available',\
                       'Insufficient'))
call setHcveVariable('$MIN_DSK')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough disk space to install the Oracle HTTP Server install type.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Available" result="PASSED"><![CDATA[The system has enough disk space to install the Oracle HTTP Server install type.]]></sdp_action>
<sdp_action condition="==" minimum="OS type unidentified" result="SKIPPED"><![CDATA[The operating system type must be known in order to establish the required disk space.]]></sdp_action>
<sdp_action condition="==" minimum="Undetermined" result="SKIPPED"><![CDATA[The amount of disk space required on the operating system type has not been determined.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the available space to ${MIN_DSK} or more to install the Oracle HTTP Server install type.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|
|Cannot access ORACLE_HOME|Set ``ORACLE_HOME`` to a valid directory.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00080" mode="VERIFY" name="Temp Space?">
<sdp_command type="RDA"><![CDATA[
var ($flg,$tmp,@tbl) = (true,{'/tmp','/tmp'})
loop $key ('TMP','TMPDIR')
{if getEnv($key)
  var $tmp->{$key} = last
}
loop $key (keys(%tmp))
{if !testDir('d',$tmp->{$key})
  call push(@tbl,concat($key,' invalidDir'))
 else
 {if !testDir('w',$tmp->{$key})
   call push(@tbl,concat($key,' NoWrite'))
  if and($flg,expr('>=',get_df($tmp->{$key}),409600))
   var $flg = false
 }
}
if $flg
{loop $key (keys(%tmp))
  call push(@tbl,concat($key,' tooSmall'))
}
call setHcveParameter('RULE.A00080',$tmp)
call setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'TempSpaceOK'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough temporary space. Initially Oracle Universal Installer (OUI) checks the ``TMP`` and ``TMPDIR`` environment variables to locate the temporary directory. If these environment variables do not exist, then OUI uses ``/tmp``. The minimum requirement is 400 MB.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="TempSpaceOK" result="PASSED"><![CDATA[There is sufficient temporary disk space available for installing Oracle Database 10g. No action required.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[The temporary space is not configured correctly.
|*Return Value*|*Action*|
|/tmp invalidDir|ALERT - ``/tmp`` is not a valid directory. ``/tmp`` needs to be a directory.|
|/tmp NoWrite|ALERT - The user does not have write permissions to the ``/tmp`` directory.|
|/tmp tooSmall|ALERT - There is less than the needed 400 MB of free space in the ``/tmp`` directory.|
|TMP invalidDir|ALERT - ``TMP`` is set to ${`RULE.A00080.TMP} in the environment; however, ${`RULE.A00080.TMP} is an invalid directory. Take appropriate action.|
|TMP NoWrite|ALERT - ``TMP`` is set to ${`RULE.A00080.TMP} in the environment; however, the user does not have write permissions to ${`RULE.A00080.TMP}.|
|TMP tooSmall|ALERT - ``TMP`` is set to ${`RULE.A00080.TMP} in the environment; however, ${`RULE.A00080.TMP} has less than the required 400 MB of free space. Make sure your temporary space has at least 400 MB of free space.|
|TMPDIR invalidDir|ALERT - ``TMPDIR`` is set to ${`RULE.A00080.TMPDIR} in the environment; however, ${`RULE.A00080.TMPDIR} is an invalid directory. Take appropriate action.|
|TMPDIR NoWrite|ALERT - ``TMPDIR`` is set to ${`RULE.A00080.TMPDIR} in the environment; however, the user does not have write permissions to ${`RULE.A00080.TMPDIR}.|
|TMPDIR tooSmall|ALERT - ``TMPDIR`` is set to ${`RULE.A00080.TMPDIR} in the environment; however, ${`RULE.A00080.TMPDIR} has less than the required 400 MB of free space. Make sure your temporary space has at least 400 MB of free space.|
]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00090" mode="VERIFY" name="Swap Space for 10.1.3.0/10.1.3.1?">
<sdp_command type="RDA"><![CDATA[import $OS_ARC
var $SWAP = undef
if match($OS_ARC,'Itanium',true)
{var $min = 1048576
 var $MIN_SWP = "1024 MB"
}
else
{var $min = 524288
 var $MIN_SWP = "512 MB"
}
call setHcveVariable('$SWAP')
if !testFile('r','/proc/meminfo')
 return setHcveResult('Cannot access /proc/meminfo')
var $SWAP = field('\s+',1,grepFile('/proc/meminfo','SwapTotal','f'))
call setHcveResult(cond(expr('>=',$SWAP,$min),'Available',\
                                              'Insufficient'))
call setHcveVariable('$MIN_SWP')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough swap space for 10.1.3.0 and 10.1.3.1 only.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Available" result="PASSED"><![CDATA[The system has enough swap space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Insufficient|Increase the swap space to ${MIN_SWP} or more.|
|Cannot access /proc/meminfo|Grant read permissions on ``/proc/meminfo`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00092" mode="VERIFY" name="Swap Space for 10.1.3.2?">
<sdp_command type="RDA"><![CDATA[import $SWAP
call setHcveResult(cond(\
  not(defined($SWAP)),      'Cannot access /proc/meminfo',\
  expr('>=',$SWAP,2097152), 'Available',\
                            'Need at least 2 GB'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the system has enough swap space for 10.1.3.2 only. The minimum requirement is 2 GB.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Available" result="PASSED"><![CDATA[The system has enough swap space.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Need at least 2 GB|Increase the swap space to 2 GB or more.|
|Cannot access /proc/meminfo|Grant read permissions on ``/proc/meminfo`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00100" mode="VERIFY" name="Monitor Colors?">
<sdp_command type="RDA"><![CDATA[import $OS_ARC
if match($OS_ARC,'Power|[pz]Series|IBM/S390',true)
 call loadCommand('/usr/bin/X11/xdpyinfo 2>&1')
else
 call loadCommand('/usr/X11R6/bin/xdpyinfo 2>&1')
var @dpt = grepLastFile('depths')
call setHcveResult(cond(\
  grep(@dpt,'8','f'),              'Adequate',\
  not(defined(getEnv('DISPLAY'))), 'DISPLAY is not set',\
  grepLastFile('unable','f'),      'Cannot open DISPLAY',\
                                   'Need at least 256 colors'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the monitor has a minimum of 256 colors.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The monitor has enough colors.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Need at least 256 colors|Use a display with 256 colors.|
|DISPLAY is not set|Set the ``DISPLAY`` environment variable to a valid display.|
|Cannot open DISPLAY|Set the ``DISPLAY`` environment variable to a correct display.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00110" mode="VERIFY" name="OS Certified?">
<sdp_command type="RDA"><![CDATA[import $OS_TYP,$OS_ARC,$OS_NAM,$OS_BIT,$BOOK
macro find_update
{import $OS_NAM
 return first(match($OS_NAM,'Update\s+(\d+)',true))
}
if match($OS_ARC,'intel|amd',true)
{if match($OS_TYP,'asianux',true)
 {if match($OS_NAM,'trinity',true)
  {if expr('==',$OS_BIT,32)
    call setHcveResult('Certified')
   else
    call setHcveResult('Not certified [Asianux 2 64-bit not certified]')
  }
  elsif match($OS_NAM,'quartet',true)
   call setHcveResult('Certified')
  else
   call setHcveResult('Not certified [x86/x86-64 Asianux]')
 }
 elsif match($OS_TYP,'oracle',true)
 {if match($OS_NAM,'october|carthage|^oracle.*release\s5\.\d+$',true)
   call setHcveResult('Certified')
  else
   call setHcveResult('Not certified [x86/x86-64 Oracle]')
 }
 elsif match($OS_TYP,'red hat',true)
 {if match($OS_NAM,'taroon',true)
  {if expr('>=',find_update(),1)
    call setHcveResult('Certified')
   else
    call setHcveResult('Not certified [x86/x86-64 Red Hat 3]')
  }
  elsif match($OS_NAM,'(nahant|tikanga)',true)
   call setHcveResult('Certified')
  else
   call setHcveResult('Not certified [x86/x86-64 Red Hat]')
 }
 elsif match($OS_TYP,'suse',true)
 {if match($OS_NAM,'sles-(9|10)',true)
   call setHcveResult('Certified')
  else
   call setHcveResult('Not certified [x86/x86-64 SuSE]')
 }
 else
  call setHcveResult('Not certified [x86/x86-64]')
}
elsif match($OS_ARC,'itanium',true)
{if match($OS_TYP,'oracle',true)
 {if match($OS_NAM,'october',true)
  {if expr('>=',find_update(),1)
    call setHcveResult('Certified')
   else
    call setHcveResult('Not certified [Itanium Oracle 4]')
  }
  else
   call setHcveResult('Not certified [Itanium Oracle]')
 }
 elsif match($OS_TYP,'red hat',true)
 {if match($OS_NAM,'taroon',true)
  {if expr('>=',find_update(),6)
    call setHcveResult('Certified')
   else
    call setHcveResult('Not certified [Itanium Red Hat 3]')
  }
  elsif match($OS_NAM,'nahant',true)
  {if expr('>=',find_update(),1)
    call setHcveResult('Certified')
   else
    call setHcveResult('Not certified [Itanium Red Hat 4]')
  }
  else
   call setHcveResult('Not certified [Itanium Red Hat]')
 }
 elsif match($OS_TYP,'suse',true)
 {if match($OS_NAM,'sles-9',true)
   call setHcveResult('Certified')
  else
   call setHcveResult('Not certified [Itanium SuSE]')
 }
 else
  call setHcveResult('Not certified [Itanium]')
}
elsif match($OS_ARC,'Power|pSeries',true)
{if match($OS_TYP,'oracle',true)
 {if match($OS_NAM,'october',true)
  {if expr('>=',find_update(),1)
    call setHcveResult('Certified')
   else
    call setHcveResult('Not certified [Power Oracle 4]')
  }
  else
   call setHcveResult('Not certified [Power Oracle]')
 }
 elsif match($OS_TYP,'red hat')
 {if match($OS_NAM,'nahant',true)
  {if expr('>=',find_update(),1)
    call setHcveResult('Certified')
   else
    call setHcveResult('Not certified [Power Red Hat 4]')
  }
  else
   call setHcveResult('Not certified [Power Red Hat]')
 }
 else
  call setHcveResult('Not certified [Power]')
}
elsif match($OS_ARC,'zSeries|IBM/S390')
{if match($OS_TYP,'oracle',true)
 {if match($OS_NAM,'october',true)
   call setHcveResult(cmp_kernel('zSeries Oracle 4','2.6.9,22.EL'))
  elsif match($OS_NAM,'(carthage|^oracle.*release\s5\.\d+$)',true)
   call setHcveResult('Certified')
  else
   call setHcveResult('Not certified [zSeries Oracle]')
 }
 elsif match($OS_TYP,'red hat',true)
 {if match($OS_NAM,'nahant')
   call setHcveResult(cmp_kernel('zSeries RH EL4','2.6.9,22.EL'))
  elsif match($OS_NAM,'tikanga',true)
   call setHcveResult('Certified')
  else
   setHcveResult('Not certified [zSeries Red Hat]')
 }
 elsif match($OS_TYP,'suse',true)
 {if match($OS_NAM,'suse-9',true)
   call setHcveResult(cmp_kernel('zSeries SLES-9','2.6.5,7.191,s390x'))
  else
   call setHcveResult('Not certified [zSeries SuSE]')
 }
 else
  call setHcveResult('Not certified [zSeries]')
}
else
 call setHcveResult('Check certification')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks for a certified operating system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Certified" result="PASSED"><![CDATA[The operating system is certified for Oracle Application Server 10g Release 3.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Not certified ...|You are not using a certified operating system for Oracle Application Server 10g Release 3. Refer to the ${'BOOK} and Certification in My Oracle Support.|
|Check certification|For less common operating systems, it is possible that they may be certified and not verified by this rule. Please verify that your operating system is certified.|
]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00120" mode="VERIFY" name="OL4 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'Oracle')
 call setHcveResult('NotOracle')
elsif !match($OS_NAM,'october',true)
 call setHcveResult('NotOL4')
macro chk_rpm_7x
{var (\@tbl,$rpm,$ref,$arc) = @arg
 if !chk_os_pkg($rpm,$arc)
  return push(@tbl,concat('[',$rpm,\
                         cond($arc,concat('(',$arc,')'),''),'] not installed'))
 while get_os_pkg()
 {var ($ver,$rel) = (last)
  if or(not(match($ver,'7\.x$')),\
        not(compare('VALID',version($rel),$ref)))
   call push(@tbl,concat('[',$rpm,'-',$ver,\
                         cond($rel,concat('-',$rel)),\
                         cond($arc,concat('(',$arc,')'),''),'] found'))
 }
}
var @tbl = ()
elsif match($OS_ARC,'Intel|AMD',true)
{if expr('==',$OS_BIT,32)
 {call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
  call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'])
  call cmp_os_pkg(\@tbl,'compat-glibc','2.3.2.95.30')
  call chk_rpm_7x(\@tbl,'compat-glibc','2.2.4.32.6')
  call chk_rpm_7x(\@tbl,'compat-libstdc++','2.96.128')
  call cmp_os_pkg(\@tbl,'compat-libstdc++-33','3.2.3.47.3')
  call cmp_os_pkg(\@tbl,'compat-libstdc++-296',['2.96','132.7.2'])
  call cmp_os_pkg(\@tbl,'compat-libstdc++-devel',['7.3','2.96.128'])
  call cmp_os_pkg(\@tbl,'control-center',['2.8.0','12'])
  call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'])
  call cmp_os_pkg(\@tbl,'glibc-common',['2.3.4','2.9'])
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.3.4','2.9'])
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','44.1'])
  call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'make',['3.80','5'])
  call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                      '(RH|rh)?(EL|el)\d.*$')
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'])
  call cmp_os_pkg(\@tbl,'setarch',['1.6','1'])
  call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
  call cmp_os_pkg(\@tbl,'xscreensaver',['4.18','5','rhel4'])
  call setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'OL4rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'],'i386')
  call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'],'x86_64')
  call cmp_os_pkg(\@tbl,'control-center',['2.8.0','12'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'],'i686')
  call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-common',['2.3.4','2.9'],'x86_64')
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','44.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'make',['3.80','5'],'x86_64')
  call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                      '(RH|rh)?(EL|el)\d.*$')
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'],'x86_64')
  call cmp_os_pkg(\@tbl,'setarch',['1.6','1'],'x86_64')
  call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'],'x86_64')
  call cmp_os_pkg(\@tbl,'xscreensaver',['4.18','rhel4'],'x86_64')
  call setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'OL4rpmsOK'))
 }
}
elsif match($OS_ARC,'Itanium',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
 call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-296',['2.96','132.7.2'])
 call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc-common',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc-devel',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'make',['3.80','5'])
 call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                     '(RH|rh)?(EL|el)\d.*$')
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
 call setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'OL4rpmsOK'))
}
elsif match($OS_ARC,'Power|pSeries',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-33',['3.2.3','47.3'])
 call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-c++-ppc32',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-ppc32',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'],'x86_64')
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.3','22.1'],'x86_64')
 call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'make',['3.80','5'])
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
 call setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'OL4rpmsOK'))
}
elsif match($OS_ARC,'zSeries|IBM/S390',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
 call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-33',['3.2.3','47.3'])
 call cmp_os_pkg(\@tbl,'db',['4.2.52','7.1'])
 call cmp_os_pkg(\@tbl,'gcc',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'gdbm',['1.8.0','24'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.13'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.13'],'x86_64')
 call cmp_os_pkg(\@tbl,'libaio',['0.3.103','3'])
 call cmp_os_pkg(\@tbl,'libaio',['0.3.103','3'],'x86_64')
 call cmp_os_pkg(\@tbl,'libaio-devel',['0.3.103','3'],'x86_64')
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.4','2'],'x86_64')
 call cmp_os_pkg(\@tbl,'libstdc++',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'make',['3.80','5'])
 call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                     '(RH|rh)?(EL|el)\d.*$')
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30.3'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
 call setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'OL4rpmsOK'))
}
else
 call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on an Oracle Linux 4 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="OL4rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86, x86-64, Itanium, POWER, zSeries), ``compat-db`` (x86, x86-64, Itanium, zSeries), ``compat-glibc`` (x86), ``compat-libstdc++`` (x86), ``compat-libstdc++-33`` (x86, POWER zSeries), ``compat-libstdc++-296`` (x86, Itanium), ``compat-libstdc++-devel`` (x86), ``control-center`` (x86, x86-64), ``db`` (zSeries), ``gcc`` (x86, x86-64, Itanium, POWER, zSeries), ``gcc-c++`` (x86, x86-64, Itanium, POWER, zSeries), ``gdbm`` (zSeries), ``glibc`` (x86, x86-64, Itanium, POWER, zSeries), ``glibc-common`` (x86, x86-64, Itanium), ``glibc-devel`` (x86, Itanium), ``gnome-libs`` (x86, x86-64), ``libaio`` (zSeries), ``libaio-devel`` (zSeries), ``libgcc`` (zSeries), ``libstdc++`` (x86, x86-64, Itanium, POWER, zSeries), ``libstdc++-devel`` (x86, x86-64, Itanium, POWER, zSeries), ``make`` (x86, x86-64, Itanium, POWER, zSeries), ``openmotif21`` (x86, x86-64, Itanium, zSeries), ``pdksh`` (x86, x86-64, Itanium, POWER, zSeries), ``setarch`` (x86, x86-64), ``sysstat`` (x86, x86-64, Itanium, POWER, zSeries), and ``xscreensaver`` (x86, x86-64) packages are installed on your Oracle Linux 4 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="NotOL4|NotOracle|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for Oracle Linux 4 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ``binutils`` (x86, x86-64, Itanium, POWER, zSeries), ``compat-db`` (x86, x86-64, Itanium, zSeries), ``compat-glibc`` (x86), ``compat-libstdc++`` (x86), ``compat-libstdc++-33`` (x86, POWER zSeries), ``compat-libstdc++-296`` (x86, Itanium), ``compat-libstdc++-devel`` (x86), ``control-center`` (x86, x86-64), ``db`` (zSeries), ``gcc`` (x86, x86-64, Itanium, POWER, zSeries), ``gcc-c++`` (x86, x86-64, Itanium, POWER, zSeries), ``gdbm`` (zSeries), ``glibc`` (x86, x86-64, Itanium, POWER, zSeries), ``glibc-common`` (x86, x86-64, Itanium), ``glibc-devel`` (x86, Itanium), ``gnome-libs`` (x86, x86-64), ``libaio`` (zSeries), ``libaio-devel`` (zSeries), ``libgcc`` (zSeries), ``libstdc++`` (x86, x86-64, Itanium, POWER, zSeries), ``libstdc++-devel`` (x86, x86-64, Itanium, POWER, zSeries), ``make`` (x86, x86-64, Itanium, POWER, zSeries), ``openmotif21`` (x86, x86-64, Itanium, zSeries), ``pdksh`` (x86, x86-64, Itanium, POWER, zSeries), ``setarch`` (x86, x86-64), ``sysstat`` (x86, x86-64, Itanium, POWER, zSeries), or ``xscreensaver`` (x86, x86-64) installed on your system. Make sure that the correct versions are installed. For more information about the correct versions, see the ${'BOOK}.%BR%
If ``binutils-2.15.92.0.2-13`` is not installed, you must install that exact version. For more information about where to download the version, see the ${'BOOK}.%BR%
For AS 10.1.3.1, installer checks for the packages with the following versions: ``compat-glibc-7.x-2.2.4.32.6``, ``compat-libstdc++-devel-7.3-2.96.128``, or ``compat-libstdc++-7.3-2.96.128``.%BR%
The correct versions to check are ``compat-glibc-2.3.2-95.30`` or ``compat-libstdc++-33-3.2.3-47.3``. Ignore pre install checks related to these packages if the version is higher.%BR%
For AS 10.1.3.2, ignore failures for packages having at least the following versions: ``binutils-2.14.90.0.4-35``, ``gcc-3.2.3-42``, ``gcc-c++-3.2.3-42``, ``glibc-2.3.2-95.27``, ``glibc-common-2.3.2-95.27``, ``gnome-libs-1.4.1.2.90-34.1``, ``libstdc++-3.2.3-42``, ``libstdc++-devel-3.2.3-42``, ``make-3.79.1-17``, ``openmotif21-2.1.30-8``, ``pdksh-5.2.14-21``, ``setarch-1.3-1``, ``sysstat-4.0.7-4.EL3.3``.]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00121" mode="VERIFY" name="OL5 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'Oracle')
 return setHcveResult('NotOracle')
if !match($OS_NAM,'(carthage|^oracle.*release\s5\.\d+$)',true)
 return setHcveResult('NotOL5')
if match($OS_ARC,'(Intel|AMD)')
{if expr('==',$OS_BIT,32)
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'])
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'])
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'])
  if expr('==',chk_os_pkg('libXp'),0)
   call push(@tbl,'libXp missing')
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'])
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'OL5rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'],'i386')
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4.el5'],'i386')
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4.el5'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'],'x86_64')
  if expr('==',chk_os_pkg('libXp'),0)
   call push(@tbl,'libXp missing')
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'],'x86_64')
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'OL5rpmsOK'))
 }
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on an Oracle Linux 5 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="OL5rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86, x86-64), ``gcc`` (x86, x86-64), ``gcc-c++`` (x86, x86-64), ``glibc-devel`` (x86, x86-64), ``libgcc`` (x86, x86-64), ``libstdc++`` (x86, x86-64), ``libstdc++-devel`` (x86, x86-64), and ``make`` (x86, x86-64) packages are installed on your Oracle Linux 5 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="NotOL5|NotOracle|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for Oracle Linux 5 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ``binutils`` (x86, x86-64), ``gcc`` (x86, x86-64), ``gcc-c++`` (x86, x86-64), ``glibc-devel`` (x86, x86-64), ``libgcc`` (x86, x86-64), ``libstdc++`` (x86, x86-64), ``libstdc++-devel`` (x86, x86-64), or ``make`` (x86, x86-64) installed on your system. Make sure that the correct versions are installed. For more information about the correct versions, see the following document in My Oracle Support: ''Oracle Application Server 10g Release 3 (10.1.3) Install Certifications on Linux Platforms'' (Doc ID 790943.1).]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00130" mode="VERIFY" name="RHEL3 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'Red Hat')
 return setHcveResult('NotRedHat')
if !match($OS_NAM,'taroon',true)
 return setHcveResult('NotRHEL3')
macro chk_rpm_7x
{var (\@tbl,$rpm,$ref,$arc) = @arg
 if !chk_os_pkg($rpm,$arc)
  return push(@tbl,concat('[',$rpm,\
                         cond($arc,concat('(',$arc,')'),''),'] not installed'))
 while get_os_pkg()
 {var ($ver,$rel) = (last)
  if or(not(match($ver,'7\.x$')),\
        not(compare('VALID',version($rel),$ref)))
    call push(@tbl,concat('[',$rpm,'-',$ver,\
                         cond($rel,concat('-',$rel)),\
                         cond($arc,concat('(',$arc,')'),''),'] found'))
 }
}
var @tbl = ()
if match($OS_ARC,'Intel|AMD',true)
{if expr('==',$OS_BIT,32)
 {call cmp_os_pkg(\@tbl,'binutils',['2.14.90.0.4','35'])
  call cmp_os_pkg(\@tbl,'compat-db',['4.0.14','5'])
  call chk_rpm_7x(\@tbl,'compat-glibc','2.2.4.32.6')
  call cmp_os_pkg(\@tbl,'compat-libstdc++',['7.3','2.96.128'])
  call cmp_os_pkg(\@tbl,'compat-libstdc++-devel',['7.3','2.96.128'])
  call cmp_os_pkg(\@tbl,'gcc',['3.2.3','42'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['3.2.3','42'])
  call cmp_os_pkg(\@tbl,'glibc',['2.3.2','95.27'])
  call cmp_os_pkg(\@tbl,'glibc-common',['2.3.2','95.27'])
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','34.1'])
  call cmp_os_pkg(\@tbl,'libstdc++',['3.2.3','42'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.2.3','42'])
  call cmp_os_pkg(\@tbl,'make',['3.79.1','17'])
  call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','8'])
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','21'])
  call cmp_os_pkg(\@tbl,'setarch',['1.3','1'])
  call cmp_os_pkg(\@tbl,'sysstat',['4.0.7','4','EL3'])
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL3rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'compat-db',['4.0.14','5.1'],'i386')
  call cmp_os_pkg(\@tbl,'compat-gcc',['7.3','2.96.122'],'i386')
  call chk_rpm_7x(\@tbl,'compat-glibc','2.2.4.32.5','i386')
  call cmp_os_pkg(\@tbl,'gcc',['3.2.3','20'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc',['3.2.3','95.27'],'i686')
  call cmp_os_pkg(\@tbl,'glibc',['2.3.2','95.27'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-devel',['3.2.3','95.27'],'i386')
  call cmp_os_pkg(\@tbl,'glibc-devel',['3.2.3','95.27'],'x86_64')
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','34.1'],'i386')
  call cmp_os_pkg(\@tbl,'libgcc',['3.2.3','20'],'i386')
  call cmp_os_pkg(\@tbl,'libgcc',['3.2.3','20'],'x86_64')
  call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','8'],'i386')
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','21'],'x86_64')
  call cmp_os_pkg(\@tbl,'setarch',['1.3','1'],'x86_64')
  call cmp_os_pkg(\@tbl,'sysstat',['4.0.7','4'],'x86_64')
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL3rpmsOK'))
 }
}
if match($OS_ARC,'Itanium',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.14.90.0.4','39'])
 call cmp_os_pkg(\@tbl,'compat-db',['4.0.14','5.1'])
 call chk_rpm_7x(\@tbl,'compat-glibc','2.2.4.32.6')
 call cmp_os_pkg(\@tbl,'compat-libstdc++',['7.3','2.96.128'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-devel',['7.3','2.96.128'])
 call cmp_os_pkg(\@tbl,'gcc',['3.2.3','53'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.2.3','53'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.2','95.37'])
 call cmp_os_pkg(\@tbl,'glibc-common',['2.3.2','95.37'])
 call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','34.2'])
 call cmp_os_pkg(\@tbl,'libstdc++',['3.2.3','53'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.2.3','53'])
 call cmp_os_pkg(\@tbl,'make',['3.79.1','17.1'])
 call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','9','RHEL3'])
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','21'])
 call cmp_os_pkg(\@tbl,'setarch',['1.3','1'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','5','rhel3'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL3rpmsOK'))
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on a Red Hat Enterprise Linux 3 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="RHEL3rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86, Itanium), ``compat-db`` (x86, x86-64, Itanium), ``compat-gcc`` (x86-64), ``compat-glibc`` (x86, x86-64, Itanium), ``compat-libstdc++`` (x86, Itanium), ``compat-libstdc++-devel`` (x86, Itanium), ``gcc`` (x86, x86-64, Itanium), ``gcc-c++`` (x86, Itanium), ``glibc`` (x86, x86-64, Itanium), ``glibc-common`` (x86, Itanium), ``glibc-devel`` (x86-64), ``gnome-libs`` (x86, x86-64, Itanium), ``libgcc`` (x86-64), ``libstdc++`` (x86, Itanium), ``libstdc++-devel`` (x86, Itanium), ``make`` (x86, Itanium), ``openmotif21`` (x86, x86-64, Itanium), ``pdksh`` (x86, x86-64, Itanium), ``setarch`` (x86, x86-64, Itanium), and ``sysstat`` (x86, x86-64, Itanium) packages are installed on your RHEL3 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="NotRHEL3|NotRedHat|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for Red Hat Enterprise Linux 3 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ``binutils`` (x86, Itanium), ``compat-db`` (x86, x86-64, Itanium), ``compat-gcc`` (x86-64), ``compat-glibc`` (x86, x86-64, Itanium), ``compat-libstdc++`` (x86, Itanium), ``compat-libstdc++-devel`` (x86, Itanium), ``gcc`` (x86, x86-64, Itanium), ``gcc-c++`` (x86, Itanium), ``glibc`` (x86, x86-64, Itanium), ``glibc-common`` (x86, Itanium), ``glibc-devel`` (x86-64), ``gnome-libs`` (x86, x86-64, Itanium), ``libgcc`` (x86-64), ``libstdc++`` (x86, Itanium), ``libstdc++-devel`` (x86, Itanium), ``make`` (x86, Itanium), ``openmotif21`` (x86, x86-64, Itanium), ``pdksh`` (x86, x86-64, Itanium), ``setarch`` (x86, x86-64, Itanium), or ``sysstat`` (x86, x86-64, Itanium) installed on your system. Make sure that the correct versions are installed. For more information about the correct versions, see the ${'BOOK}.]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00132" mode="VERIFY" name="RHEL4 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'Red Hat')
 return setHcveResult('NotRedHat')
if !match($OS_NAM,'nahant',true)
 return setHcveResult('NotRHEL4')
macro chk_rpm_7x
{var (\@tbl,$rpm,$ref,$arc) = @arg
 if !chk_os_pkg($rpm,$arc)
  return push(@tbl,concat('[',$rpm,\
                         cond($arc,concat('(',$arc,')'),''),'] not installed'))
 while get_os_pkg()
 {var ($ver,$rel) = (last)
  if or(not(match($ver,'7\.x$')),\
        not(compare('VALID',version($rel),$ref)))
    call push(@tbl,concat('[',$rpm,'-',$ver,\
                         cond($rel,concat('-',$rel)),\
                         cond($arc,concat('(',$arc,')'),''),'] found'))
 }
}
if match($OS_ARC,'Intel|AMD',true)
{if expr('==',$OS_BIT,32)
 {call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
  call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'])
  call cmp_os_pkg(\@tbl,'compat-glibc','2.3.2.95.30')
  call chk_rpm_7x(\@tbl,'compat-glibc','2.2.4.32.6')
  call chk_rpm_7x(\@tbl,'compat-libstdc++','2.96.128')
  call cmp_os_pkg(\@tbl,'compat-libstdc++-33','3.2.3.47.3')
  call cmp_os_pkg(\@tbl,'compat-libstdc++-296',['2.96','132.7.2'])
  call cmp_os_pkg(\@tbl,'compat-libstdc++-devel',['7.3','2.96.128'])
  call cmp_os_pkg(\@tbl,'control-center',['2.8.0','12'])
  call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'])
  call cmp_os_pkg(\@tbl,'glibc-common',['2.3.4','2.9'])
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.3.4','2.9'])
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','44.1'])
  call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'])
  call cmp_os_pkg(\@tbl,'make',['3.80','5'])
  call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                      '(RH|rh)?(EL|el)\d.*$')
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'])
  call cmp_os_pkg(\@tbl,'setarch',['1.6','1'])
  call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
  call cmp_os_pkg(\@tbl,'xscreensaver',['4.18','5','rhel4'])
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL4rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'],'i386')
  call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'],'x86_64')
  call cmp_os_pkg(\@tbl,'control-center',['2.8.0','12'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'],'i686')
  call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-common',['2.3.4','2.9'],'x86_64')
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','44.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'make',['3.80','5'],'x86_64')
  call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],'i386',undef,\
                                      '(RH|rh)?(EL|el)\d.*$')
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'],'x86_64')
  call cmp_os_pkg(\@tbl,'setarch',['1.6','1'],'x86_64')
  call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'],'x86_64')
  call cmp_os_pkg(\@tbl,'xscreensaver',['4.18','rhel4'],'x86_64')
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL4rpmsOK'))
 }
}
if match($OS_ARC,'Itanium',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
 call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-296',['2.96','132.7.2'])
 call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc-common',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc-devel',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'make',['3.80','5'])
 call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                     '(RH|rh)?(EL|el)\d.*$')
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL4rpmsOK'))
}
elsif match($OS_ARC,'Power|pSeries',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-33',['3.2.3','47.3'])
 call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-c++-ppc32',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-ppc32',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'],'x86_64')
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.3','22.1'],'x86_64')
 call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'make',['3.80','5'])
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL4rpmsOK'))
}
if match($OS_ARC,'zSeries|IBM/S390',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
 call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-33',['3.2.3','47.3'])
 call cmp_os_pkg(\@tbl,'db',['4.2.52','7.1'])
 call cmp_os_pkg(\@tbl,'gcc',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'gdbm',['1.8.0','24'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.13'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.13'],'x86_64')
 call cmp_os_pkg(\@tbl,'libaio',['0.3.103','3'])
 call cmp_os_pkg(\@tbl,'libaio',['0.3.103','3'],'x86_64')
 call cmp_os_pkg(\@tbl,'libaio-devel',['03.3.103','3'],'x86_64')
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'libgcc',['3.4.4','2'],'x86_64')
 call cmp_os_pkg(\@tbl,'libstdc++',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.4','2'])
 call cmp_os_pkg(\@tbl,'make',['3.80','5'])
 call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                     '(RH|rh)?(EL|el)\d.*$')
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30.3'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL4rpmsOK'))
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on a Red Hat Enterprise Linux 4 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="RHEL4rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86, x86-64, Itanium, POWER, zSeries), ``compat-db`` (x86, x86-64, Itanium, zSeries), ``compat-glibc`` (x86), ``compat-libstdc++`` (x86), ``compat-libstdc++-33`` (x86, POWER zSeries), ``compat-libstdc++-296`` (x86, Itanium), ``compat-libstdc++-devel`` (x86), ``control-center`` (x86, x86-64), ``db`` (zSeries), ``gcc`` (x86, x86-64, Itanium, POWER, zSeries), ``gcc-c++`` (x86, x86-64, Itanium, POWER, zSeries), ``gdbm`` (zSeries), ``glibc`` (x86, x86-64, Itanium, POWER, zSeries), ``glibc-common`` (x86, x86-64, Itanium), ``glibc-devel`` (x86, Itanium), ``gnome-libs`` (x86, x86-64), ``libaio`` (zSeries), ``libaio-devel`` (zSeries), ``libgcc`` (zSeries), ``libstdc++`` (x86, x86-64, Itanium, POWER, zSeries), ``libstdc++-devel`` (x86, x86-64, Itanium, POWER, zSeries), ``make`` (x86, x86-64, Itanium, POWER, zSeries), ``openmotif21`` (x86, x86-64, Itanium, zSeries), ``pdksh`` (x86, x86-64, Itanium, POWER, zSeries), ``setarch`` (x86, x86-64), ``sysstat`` (x86, x86-64, Itanium, POWER, zSeries), and ``xscreensaver`` (x86, x86-64) packages are installed on your Red Hat Enterprise Linux 4 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="NotRHEL4|NotRedHat|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for Red Hat Enterprise Linux 4 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ``binutils`` (x86, x86-64, Itanium, POWER, zSeries), ``compat-db`` (x86, x86-64, Itanium, zSeries), ``compat-glibc`` (x86), ``compat-libstdc++`` (x86), ``compat-libstdc++-33`` (x86, POWER zSeries), ``compat-libstdc++-296`` (x86, Itanium), ``compat-libstdc++-devel`` (x86), ``control-center`` (x86, x86-64), ``db`` (zSeries), ``gcc`` (x86, x86-64, Itanium, POWER, zSeries), ``gcc-c++`` (x86, x86-64, Itanium, POWER, zSeries), ``gdbm`` (zSeries), ``glibc`` (x86, x86-64, Itanium, POWER, zSeries), ``glibc-common`` (x86, x86-64, Itanium), ``glibc-devel`` (x86, Itanium), ``gnome-libs`` (x86, x86-64), ``libaio`` (zSeries), ``libaio-devel`` (zSeries), ``libgcc`` (zSeries), ``libstdc++`` (x86, x86-64, Itanium, POWER, zSeries), ``libstdc++-devel`` (x86, x86-64, Itanium, POWER, zSeries), ``make`` (x86, x86-64, Itanium, POWER, zSeries), ``openmotif21`` (x86, x86-64, Itanium, zSeries), ``pdksh`` (x86, x86-64, Itanium, POWER, zSeries), ``setarch`` (x86, x86-64), ``sysstat`` (x86, x86-64, Itanium, POWER, zSeries), or ``xscreensaver`` (x86, x86-64) installed on your system. Make sure that the correct versions are installed. For more information about the correct versions, see the ${'BOOK}.%BR%
If ``binutils-2.15.92.0.2-13`` is not installed, you must install that exact version. For more information about where to download the version, see the ${'BOOK}.%BR%
For AS 10.1.3.1, installer checks for the packages with the following versions: ``compat-glibc-7.x-2.2.4.32.6``, ``compat-libstdc++-devel-7.3-2.96.128``, or ``compat-libstdc++-7.3-2.96.128``.%BR%
The correct versions to check are ``compat-glibc-2.3.2-95.30`` or ``compat-libstdc++-33-3.2.3-47.3``. Ignore pre install checks related to these packages if the version is higher.%BR%
For AS 10.1.3.2, ignore failures for packages having at least the following versions: ``binutils-2.14.90.0.4-35``, ``gcc-3.2.3-42``, ``gcc-c++-3.2.3-42``, ``glibc-2.3.2-95.27``, ``glibc-common-2.3.2-95.27``, ``gnome-libs-1.4.1.2.90-34.1``, ``libstdc++-3.2.3-42``, ``libstdc++-devel-3.2.3-42``, ``make-3.79.1-17``, ``openmotif21-2.1.30-8``, ``pdksh-5.2.14-21``, ``setarch-1.3-1``, ``sysstat-4.0.7-4.EL3.3``.]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00133" mode="VERIFY" name="RHEL5 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'Red Hat')
 return setHcveResult('NotRedHat')
if !match($OS_NAM,'tikanga',true)
 return setHcveResult('NotRHEL5')
if match($OS_ARC,'(Intel|AMD)')
{if expr('==',$OS_BIT,32)
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'])
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'])
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'])
  if expr('==',chk_os_pkg('libXp'),0)
   call push(@tbl,'libXp missing')
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'])
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL5rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'],'i386')
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4.el5'],'i386')
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4.el5'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'],'x86_64')
  if expr('==',chk_os_pkg('libXp'),0)
   call push(@tbl,'libXp missing')
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'],'x86_64')
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL5rpmsOK'))
 }
}
if match($OS_ARC,'Power|pSeries',true)
{call cmp_os_pkg('binutils',['2.17.50.0.6','9.el5'])
 call cmp_os_pkg('gcc',['4.1.2','44.el5'])
 call cmp_os_pkg('gcc-c++',['4.1.2','44.el5'])
 call cmp_os_pkg('glibc-devel',['2.5','34'])
 call cmp_os_pkg('libgcc',['4.1.2','44.el5'])
 call cmp_os_pkg('libstdc++',['4.1.2','44.el5'])
 call cmp_os_pkg('libstdc++-devel',['4.1.2','44.el5'])
 if expr('==',chk_os_pkg('libXp'),0)
  call push(@tbl,'libXp missing')
 call cmp_os_pkg('make',['3.81','3.el5'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL5rpmsOK'))
}
if match($OS_ARC,'zSeries|IBM/S390',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'])
 call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'])
 call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'])
 call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4'])
 call cmp_os_pkg('libstdc++',['4.1.0','28.4'])
 call cmp_os_pkg('libstdc++-devel',['4.1.0','28.4'])
 call cmp_os_pkg('libXp',['1.0.0','8.1.el5'])
 call cmp_os_pkg('make',['3.80','202.2'])
 call cmp_os_pkg('openmotif',['2.3.0','0.3.el5'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'RHEL5rpmsOK'))
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on an Red Hat Enterprise Linux 5 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="RHEL5rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86, x86-64, POWER, zSeries), ``gcc`` (x86, x86-64, POWER, zSeries), ``gcc-c++`` (x86, x86-64, POWER, zSeries), ``glibc-devel`` (x86, x86-64, POWER, zSeries), ``libgcc`` (x86, x86-64, POWER, zSeries), ``libstdc++`` (x86, x86-64, POWER, zSeries), ``libstdc++-devel`` (x86, x86-64, POWER, zSeries), ``libXp`` (zSeries), ``make`` (x86, x86-64, POWER, zSeries), and ``openmotif`` (zSeries)  packages are installed on your Red Hat Enterprise Linux 5 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="NotRHEL5|NotRedHat|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for Red Hat Enterprise Linux 5 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect
 versions of ``binutils`` (x86, x86-64, POWER, zSeries), ``gcc`` (x86, x86-64, POWER, zSeries), ``gcc-c++`` (x86, x86-64, POWER, zSeries), ``glibc-devel`` (x86, x86-64, POWER, zSeries), ``libgcc`` (x86, x86-64, POWER, zSeries), ``libstdc++`` (x86, x86-64, POWER, zSeries), ``libstdc++-devel`` (x86, x86-64, POWER, zSeries), ``libXp`` (zSeries), ``make`` (x86, x86-64, POWER, zSeries), and ``openmotif`` (zSeries) installed on your system. Make sure that the correct versions are installed. For more information about the correct versions, see the following document in My Oracle Support: ''Oracle Application Server 10g Release 3 (10.1.3) Install Certifications on Linux Platforms'' (Doc ID 790943.1).]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00140" mode="VERIFY" name="SLES9 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'SuSE')
 return setHcveResult('NotSuSE')
elsif !match($OS_NAM,'SLES-9')
 return setHcveResult('NotSLES9')
var @tbl = ()
if match($OS_ARC,'Intel|AMD',true)
{if match(expr('==',$OS_BIT,32))
 {call cmp_os_pkg(\@tbl,'binutils',['2.15.90.0.1.1','32.5'])
  call cmp_os_pkg(\@tbl,'gcc',['3.3.3','43.24'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['3.3.3','43.24'])
  call cmp_os_pkg(\@tbl,'glibc',['2.3.3','98.28'])
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.7','671.1'])
  call cmp_os_pkg(\@tbl,'gnome-libs-devel',['1.4.1.7','671.1'])
  call cmp_os_pkg(\@tbl,'libstdc++',['3.3.3','43.24'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.3.3','43.24'])
  call cmp_os_pkg(\@tbl,'make',['3.80','184.1'])
  call cmp_os_pkg(\@tbl,'openmotif21-libs',['2.1.30','MLI4'])
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','780.1'])
  call cmp_os_pkg(\@tbl,'sysstat',['5.0.1','35.1'])
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'SLES9rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'binutils',['2.15.90.0.1.1','32.5'],'x86_64')
  call cmp_os_pkg(\@tbl,'binutils-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat',['2004.7.1','1.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat-sles8',['1.3','93.3'],'x86_64')
  call cmp_os_pkg(\@tbl,'db1-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'db-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc',['3.3.3','43.24'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc-c++',['3.3.3','43.24'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc',['2.3.3','98.28'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-32bit',['9','200407011223'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-devel-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.7','671.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'gnome-libs-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'gnome-libs-devel',['1.4.1.7','671.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'libaio-devel-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'libgcc',['3.2.3','20'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++',['3.3.3','43.24'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.3.3','43.24'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'linux32',['1.0','341.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'make',['3.80','184.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','780.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'perl-32bit',['9','200407011229'],'x86_64')
  call cmp_os_pkg(\@tbl,'sysstat',['5.0.1','35.1'],'x86_64')
  call cmp_os_pkg(\@tbl,'XFree86-devel-32bit',['9','200407011229'],'x86_64')
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'SLES9rpmsOK'))
 }
}
if match($OS_ARC,'Itanium',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.90.0.1.1','32.10'])
 call cmp_os_pkg(\@tbl,'gcc',['3.3.3','43.41'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.3.3','43.41'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.3','98.61'])
 call cmp_os_pkg(\@tbl,'glibc-devel',['2.3.3','98.61'])
 call cmp_os_pkg(\@tbl,'libstdc++',['3.3.3','43.41'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.3.3','43.41'])
 call cmp_os_pkg(\@tbl,'make',['3.80','184.1'])
 call cmp_os_pkg(\@tbl,'openmotif-libs',['2.2.2','519.4'])
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','780.7'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.1','35.7'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'SLES9rpmsOK'))
}
if match($OS_ARC,'zSeries|IBM/S390',true)
{call cmp_os_pkg(\@tbl,'binutils',['2.15.90.0.1.1','32.10'],'x86_64')
 call cmp_os_pkg(\@tbl,'binutils-32bit',['9','200505240249'])
 call cmp_os_pkg(\@tbl,'db',['4.2.52','86.3'])
 call cmp_os_pkg(\@tbl,'db1',['1.85','85.1'])
 call cmp_os_pkg(\@tbl,'gcc',['3.3.3','43.34'],'x86_64')
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.3.3','43.34'],'x86_64')
 call cmp_os_pkg(\@tbl,'gdbm',['1.85','1.85'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.3','98.47'],'x86_64')
 call cmp_os_pkg(\@tbl,'glibc-32bit',['9','200506070135'])
 call cmp_os_pkg(\@tbl,'libaio',['0.3.102','1.2'],'x86_64')
 call cmp_os_pkg(\@tbl,'libaio-32bit',['9','200502241147'])
 call cmp_os_pkg(\@tbl,'libaio-devel',['0.3.102','1.2'],'x86_64')
 call cmp_os_pkg(\@tbl,'libaio-devel-32bit',['9','200502241147'])
 call cmp_os_pkg(\@tbl,'libgcc',['3.3.3','43.34'],'x86_64')
 call cmp_os_pkg(\@tbl,'libgcc-32bit',['9','200505240249'])
 call cmp_os_pkg(\@tbl,'libstdc++',['3.3.3','43.34'],'x86_64')
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.3.3','43.34'],'x86_64')
 call cmp_os_pkg(\@tbl,'libstdc++-devel-32bit',['9','20407011411'])
 call cmp_os_pkg(\@tbl,'make',['3.80','184.1'])
 call cmp_os_pkg(\@tbl,'openmotif21-libs',['2.1.30','MIL4'])
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','780.7'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.1','35.4'])
 return setHcveResult(cond(@tbl),join("\012",@tbl),'SLES9rpmsOK')
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on a SuSE Linux Enterprise Server 9 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="SLES9rpmsOK" result="PASSED"><![CDATA[The correct ``binuils`` (x86, x86-64, Itanium, zSeries), ``binutils-32bit`` (x86-64, zSeries), ``compat`` (x86-64), ``compat-32bit`` (x86-64), ``compat-sles8`` (x86-64), ``db`` (x86-64, zSeries), ``db1`` (x86-64, zSeries), ``gcc`` (x86, x86-64, Itanium, zSeries), ``gcc-c++`` (x86, x86-64, Itanium, zSeries), ``gdbm`` (zSeries), ``glibc`` (x86, x86-64, Itanium, zSeries), ``glibc-32bit`` (x86-64, zSeries), ``glibc-devel`` (Itanium), ``glibc-devel-32bit`` (x86-64), ``gnome-libs`` (x86, x86-64), ``gnome-libs-32bit`` (x86-64), ``gnome-libs-devel`` (x86, x86-64), ``libaio`` (zSeries), ``libaio-32bit`` (zSeries), ``libaio-devel`` (zSeries), ``libaio-devel-32bit`` (x86-64, zSeries), ``libgcc`` (x86-64, zSeries), ``libgcc-32bit`` (zSeries), ``libstdc++`` (x86, x86-64, Itanium, zSeries), ``libstdc++-devel`` (x86, x86-64, Itanium, zSeries), ``libstdc++-devel-32bit`` (x86-64, zSeries), ``linux32`` (zSeries), ``make`` (x86, x86-64, Itanium, zSeries), ``openmotif21-libs`` (x86, Itanium, zSeries), ``pdksh`` (x86, x86-64, Itanium, zSeries), ``perl-32bit`` (x86-64), ``sysstat`` (x86, x86-64, Itanium, zSeries), and ``XFree86-devel-32bit`` (x86-64) packages are installed on your SuSE Linux Enterprise Server 9 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="NotSLES9|NotSuSE|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for SuSE Linux Enterprise Server 9 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ```binuils`` (x86, x86-64, Itanium, zSeries), ``binutils-32bit`` (x86-64, zSeries), ``compat`` (x86-64), ``compat-32bit`` (x86-64), ``compat-sles8`` (x86-64), ``db`` (x86-64, zSeries), ``db1`` (x86-64, zSeries), ``gcc`` (x86, x86-64, Itanium, zSeries), ``gcc-c++`` (x86, x86-64, Itanium, zSeries), ``gdbm`` (zSeries), ``glibc`` (x86, x86-64, Itanium, zSeries), ``glibc-32bit`` (x86-64, zSeries), ``glibc-devel`` (Itanium), ``glibc-devel-32bit`` (x86-64), ``gnome-libs`` (x86, x86-64), ``gnome-libs-32bit`` (x86-64), ``gnome-libs-devel`` (x86, x86-64), ``libaio`` (zSeries), ``libaio-32bit`` (zSeries), ``libaio-devel`` (zSeries), ``libaio-devel-32bit`` (x86-64, zSeries), ``libgcc`` (x86-64, zSeries), ``libgcc-32bit`` (zSeries), ``libstdc++`` (x86, x86-64, Itanium, zSeries), ``libstdc++-devel`` (x86, x86-64, Itanium, zSeries), ``libstdc++-devel-32bit`` (x86-64, zSeries), ``linux32`` (zSeries), ``make`` (x86, x86-64, Itanium, zSeries), ``openmotif21-libs`` (x86, Itanium, zSeries), ``pdksh`` (x86, x86-64, Itanium, zSeries), ``perl-32bit`` (x86-64), ``sysstat`` (x86, x86-64, Itanium, zSeries), or ``XFree86-devel-32bit`` (x86-64) packages installed on your SuSE Linux Enterprise Server 9 system. Make sure that the correct version is installed. For more information about the correct versions, see the ${'BOOK}.]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00141" mode="VERIFY" name="SLES10 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'SuSE')
 return setHcveResult('NotSuSE')
if !match($OS_NAM,'SLES-10')
 return setHcveResult('NotSLES10')
var @tbl = ()
if match($OS_ARC,'Intel|AMD',true)
{if expr('==',$OS_BIT,32)
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'])
  call cmp_os_pkg(\@tbl,'compat',['2006.1.25','11.2'])
  call cmp_os_pkg(\@tbl,'compat-libstdc++',['5.0.7','22.2'])
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'])
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'])
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'SLES10rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'binutils-32bit',['2.16.91.0.5','23.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat',['2006.1.25','11.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat-32bit',['2006.1.25','11.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat-libstdc++',['5.0.7','22.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'compat-old',['2004.7.1','1.2.1'],'i386')
  call cmp_os_pkg(\@tbl,'db1-32bit',['1.85-101.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc',['2.4','31.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-32bit',['2.4','31.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-devel-32bit',['2.4','31.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'linux32',['1.0','349.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'],'x86_64')
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'SLES10rpmsOK'))
 }
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on a SuSE Linux Enterprise Server 10 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="SLES10rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86, x86-64), ``binutils-32bit`` (x86-64), ``compat`` (x86, x86-64), ``compat-32bit`` (x86-64), ``compat-libstdc++`` (x86, x86-64), ``compat-old`` (x86-64), ``db1-32bit`` (x86-64), ``gcc`` (x86, x86-64), ``gcc-c++`` (x86, x86-64), ``glibc`` (x86-64), ``glibc-32bit`` (x86-64), ``glibc-devel`` (x86, x86-64), ``glibc-devel-32bit`` (x86-64), ``libgcc`` (x86, x86-64), ``libstdc++`` (x86, x86-64), ``libstdc++-devel`` (x86, x86-64), ``linux32`` (x86-64), and ``make`` (x86, x86-64) packages are installed on your SuSE Linux Enterprise Server 10 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="NotSLES10|NotSuSE|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for SuSE Linux Enterprise Server 10 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ``binutils`` (x86, x86-64), ``binutils-32bit`` (x86-64), ``compat`` (x86, x86-64), ``compat-32bit`` (x86-64), ``compat-libstdc++`` (x86, x86-64), ``compat-old`` (x86-64), ``db1-32bit`` (x86-64), ``gcc`` (x86, x86-64), ``gcc-c++`` (x86, x86-64), ``glibc`` (x86-64), ``glibc-32bit`` (x86-64), ``glibc-devel`` (x86, x86-64), ``glibc-devel-32bit`` (x86-64), ``libgcc`` (x86, x86-64), ``libstdc++`` (x86, x86-64), ``libstdc++-devel`` (x86, x86-64), ``linux32`` (x86-64), or ``make`` (x86, x86-64) packages installed on your SuSE Linux Enterprise Server 10 system. Make sure that the correct version is installed. For more information about the correct versions, see the following document in My Oracle Support: ''Oracle Application Server 10g Release 3 (10.1.3) Install Certifications on Linux Platforms'' (Doc ID 790943.1).]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00145" mode="VERIFY" name="Asianux 2 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'Asianux',true)
 return setHcveResult('NotAsianux')
if !match($OS_NAM,'trinity',true)
 return setHcveResult('NotAsianux2')
if expr('==',$OS_BIT,64)
 return setHcveResult('NotAsianux2-32bit')
macro chk_rpm_7x
{var (\@tbl,$rpm,$ref,$arc) = @arg
 if !chk_os_pkg($rpm,$arc)
  return push(@tbl,concat('[',$rpm,\
                         cond($arc,concat('(',$arc,')'),''),'] not installed'))
 while get_os_pkg()
 {var ($ver,$rel) = (last)
  if or(not(match($ver,'7\.x$')),\
        not(compare('VALID',version($rel),$ref)))
    call push(@tbl,concat('[',$rpm,'-',$ver,\
                         cond($rel,concat('-',$rel)),\
                         cond($arc,concat('(',$arc,')'),''),'] found'))
 }
}
var @tbl = ()
if and(match($OS_ARC,'Intel|AMD',true),expr('==',$OS_BIT,32))
{call cmp_os_pkg(\@tbl,'binutils',['2.15.92.0.2','13'])
 call cmp_os_pkg(\@tbl,'compat-db',['4.1.25','9'])
 call cmp_os_pkg(\@tbl,'compat-glibc','2.3.2.95.30')
 call chk_rpm_7x(\@tbl,'compat-glibc','2.2.4.32.6')
 call chk_rpm_7x(\@tbl,'compat-libstdc++','2.96.128')
 call cmp_os_pkg(\@tbl,'compat-libstdc++-33','3.2.3.47.3')
 call cmp_os_pkg(\@tbl,'compat-libstdc++-296',['2.96','132.7.2'])
 call cmp_os_pkg(\@tbl,'compat-libstdc++-devel',['7.3','2.96.128'])
 call cmp_os_pkg(\@tbl,'control-center',['2.8.0','12'])
 call cmp_os_pkg(\@tbl,'gcc',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'gcc-c++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'glibc',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc-common',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'glibc-devel',['2.3.4','2.9'])
 call cmp_os_pkg(\@tbl,'gnome-libs',['1.4.1.2.90','44.1'])
 call cmp_os_pkg(\@tbl,'libstdc++',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'libstdc++-devel',['3.4.3','22.1'])
 call cmp_os_pkg(\@tbl,'make',['3.80','5'])
 call cmp_os_pkg(\@tbl,'openmotif21',['2.1.30','11'],undef,undef,\
                                     '(RH|rh)?(EL|el)\d.*$')
 call cmp_os_pkg(\@tbl,'pdksh',['5.2.14','30'])
 call cmp_os_pkg(\@tbl,'setarch',['1.6','1'])
 call cmp_os_pkg(\@tbl,'sysstat',['5.0.5','1'])
 call cmp_os_pkg(\@tbl,'xscreensaver',['4.18','5','rhel4'])
 return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'Asianux2rpmsOK'))
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on an Asianux 2 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Asianux2rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86), ``compat-db`` (x86), ``compat-glibc`` (x86), ``compat-libstdc++`` (x86), ``compat-libstdc++-33`` (x86), ``compat-libstdc++-296`` (x86), ``compat-libstdc++-devel`` (x86), ``control-center`` (x86), ```gcc`` (x86), ``gcc-c++`` (x86), ```glibc`` (x86), ``glibc-common`` (x86), ``glibc-devel`` (x86), ``gnome-libs`` (x86), ``libstdc++`` (x86), ``libstdc++-devel`` (x86), ``make`` (x86), ``openmotif21`` (x86), ``pdksh`` (x86), ``setarch`` (x86), ``sysstat`` (x86), and ``xscreensaver`` (x86) packages are installed on your Red Hat Enterprise Linux 4 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="^NotAsianux|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for Asianux 2 32-bit only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ```binutils`` (x86), ``compat-db`` (x86), ``compat-glibc`` (x86), ``compat-libstdc++`` (x86), ``compat-libstdc++-33`` (x86), ``compat-libstdc++-296`` (x86), ``compat-libstdc++-devel`` (x86), ``control-center`` (x86), ```gcc`` (x86), ``gcc-c++`` (x86), ```glibc`` (x86), ``glibc-common`` (x86), ``glibc-devel`` (x86), ``gnome-libs`` (x86), ``libstdc++`` (x86), ``libstdc++-devel`` (x86), ``make`` (x86), ``openmotif21`` (x86), ``pdksh`` (x86), ``setarch`` (x86), ``sysstat`` (x86), or ``xscreensaver`` (x86) installed on your system. Make sure that the correct versions are installed. For more information about the correct versions, see the ${'BOOK}.%BR%
If ``binutils-2.15.92.0.2-13`` is not installed, you must install that exact version. For more information about where to download the version, see the ${'BOOK}.%BR%
For AS 10.1.3.1, installer checks for the packages with the following versions: ``compat-glibc-7.x-2.2.4.32.6``, ``compat-libstdc++-devel-7.3-2.96.128``, or ``compat-libstdc++-7.3-2.96.128``.%BR%
The correct versions to check are ``compat-glibc-2.3.2-95.30`` or ``compat-libstdc++-33-3.2.3-47.3``. Ignore pre install checks related to these packages if the version is higher.%BR%
For AS 10.1.3.2, ignore failures for packages having at least the following versions: ``binutils-2.14.90.0.4-35``, ``gcc-3.2.3-42``, ``gcc-c++-3.2.3-42``, ``glibc-2.3.2-95.27``, ``glibc-common-2.3.2-95.27``, ``gnome-libs-1.4.1.2.90-34.1``, ``libstdc++-3.2.3-42``, ``libstdc++-devel-3.2.3-42``, ``make-3.79.1-17``, ``openmotif21-2.1.30-8``, ``pdksh-5.2.14-21``, ``setarch-1.3-1``, ``sysstat-4.0.7-4.EL3.3``.]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00146" mode="VERIFY" name="Asianux 3 RPMs ok?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_TYP,$OS_ARC,$OS_BIT,$BOOK
if !match($OS_TYP,'Asianux',true)
 return setHcveResult('NotAsianux')
if !match($OS_NAM,'quartet',true)
 return setHcveResult('NotAsianux3')
var @tbl = ()
if match($OS_ARC,'Intel|AMD',true)
{if expr('==',$OS_BIT,32)
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'])
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'])
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'])
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'])
  if expr('==',chk_os_pkg('libXp'),0)
   call push(@tbl,'libXp missing')
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'])
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'Asianux3rpmsOK'))
 }
 else
 {call cmp_os_pkg(\@tbl,'binutils',['2.16.91.0.5','23.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'gcc-c++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'],'i386')
  call cmp_os_pkg(\@tbl,'glibc-devel',['2.4','31.2'],'x86_64')
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4.el5'],'i386')
  call cmp_os_pkg(\@tbl,'libgcc',['4.1.0','28.4.el5'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++',['4.1.0','28.4'],'x86_64')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'],'i386')
  call cmp_os_pkg(\@tbl,'libstdc++-devel',['4.1.0','28.4'],'x86_64')
  if expr('==',chk_os_pkg('libXp'),0)
   call push(@tbl,'libXp missing')
  call cmp_os_pkg(\@tbl,'make',['3.80','202.2'],'x86_64')
  return setHcveResult(cond(scalar(@tbl),join("\012",@tbl),'Asianux3rpmsOK'))
 }
}
call setHcveResult('PlatformUnidentified')
]]></sdp_command>
<sdp_description><![CDATA[This rule verifies that the correct versions of the required RPMs are installed on an Asianux 3 system.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Asianux3rpmsOK" result="PASSED"><![CDATA[The correct ``binutils`` (x86, x86-64), ``gcc`` (x86, x86-64), ``gcc-c++`` (x86, x86-64), ``glibc-devel`` (x86, x86-64), ``libgcc`` (x86, x86-64), ``libstdc++`` (x86, x86-64), ``libstdc++-devel`` (x86, x86-64), and ``make`` (x86, x86-64) packages are installed on your Asianux 3 system. No action required.]]></sdp_action>
<sdp_action condition="=~" minimum="^NotAsianux|PlatformUnidentified" result="SKIPPED"><![CDATA[This rule is for Asianux 3 only.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[You have incorrect versions of ``binutils`` (x86, x86-64), ``gcc`` (x86, x86-64), ``gcc-c++`` (x86, x86-64), ``glibc-devel`` (x86, x86-64), ``libgcc`` (x86, x86-64), ``libstdc++`` (x86, x86-64), ``libstdc++-devel`` (x86, x86-64), or ``make`` (x86, x86-64) installed on your system. Make sure that the correct versions are installed. For more information about the correct versions, see the following document in My Oracle Support: ''Oracle Application Server 10g Release 3 (10.1.3) Install Certifications on Linux Platforms'' (Doc ID 790943.1).]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00150" mode="VERIFY" name="hugemem Kernel?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$OS_ARC
if !match($OS_ARC,'Intel|AMD',true)
 return setHcveResult('Not required')
return setHcveResult(cond(\
   not(match($OS_NAM,'(taroon|nahant)',true)),\
     'Not required',\
   and(match(uname('r'),'hugemem',true),not(match(uname('m'),'i386',true))),\
     'hugemem kernel is used',\
     'Adequate'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the hugemem kernel is used. This is only required for RedHat AS/ES 3.0 or 4.0. If the hugemem kernel is used, then the setarch i386 command must be run.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The hugemem kernel is not used or else it is used and the setarch i386 command has been run.]]></sdp_action>
<sdp_action condition="==" minimum="Not required" result="SKIPPED"><![CDATA[This rule only applies to x86 and x86-64-based Red Hat 3 or 4 operating systems.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|hugemem kernel is used|Run the setarch i386 command.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00160" mode="VERIFY" name="Perl Link?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM
var $LS = findCommand('ls')
call setHcveVariable('$LS')
call setHcveResult(cond(\
  not(match($OS_NAM,'(SLES-9|SuSE Linux 9|SuSE Linux Enterprise Server 9)',\
            true)),\
    'Not required',\
  grepCommand(concat($LS,' -l /usr/local/bin/perl'),\
              quote('/usr/bin/perl'),\
              'f'),\
    'Exists',\
    'Missing'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the following symbolic link exists: ``/usr/local/bin/perl`` -> ``/usr/bin/perl``.
This is required for SuSE 9.0.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Exists" result="PASSED"><![CDATA[The Perl link exists.]]></sdp_action>
<sdp_action condition="==" minimum="Not required" result="SKIPPED"><![CDATA[This rule only applies to SuSE Linux Enterprise Server 9.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Missing|Log in as root and create a Perl symbolic link:%BR%``ln -sf /usr/bin/perl /usr/local/bin/perl``|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00162" mode="VERIFY" name="fuser Link?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM,$LS
call setHcveResult(cond(\
  not(match($OS_NAM,'(SLES-9|SuSE Linux 9|SuSE Linux Enterprise Server 9)',\
            true)),\
    'Not required',\
  grepCommand(concat($LS,' -l /sbin/fuser'),quote('/bin/fuser'),'f'),\
    'Exists',\
    'Missing'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the fuser symbolic link ``/sbin/fuser`` -> ``/bin/fuser`` exists. This is required for SuSE 9.0.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Exists" result="PASSED"><![CDATA[The fuser link exists.]]></sdp_action>
<sdp_action condition="==" minimum="Not required" result="SKIPPED"><![CDATA[This rule only applies to SuSE Linux Enterprise Server 9.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Missing|Log in as root and create an fuser symbolic link:%BR%``ln -sf /bin/fuser /sbin/fuser``|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00170" mode="VERIFY" name="orarun Package?">
<sdp_command type="RDA"><![CDATA[import $OS_NAM
call setHcveResult(cond(\
  not(match($OS_NAM,'(SLES-9|SuSE Linux 9|SuSE Linux Enterprise Server 9)',\
            true)),\
    'Not applicable',\
  not(chk_os_pkg('orarun')),\
    'Not installed',\
  not(testFile('r',catFile(getEnv('HOME'),'.profile'))),\
    'Environment reset not required.',\
  not(($prf) = grepFile(catFile(getEnv('HOME'),'.profile'),\
                           quote('. ./.oracle'),\
                           'if')),\
    'Installed correctly',\
  compare('eq',substr($prf,0,1),'#'),\
    'Installed correctly',\
    'Reset oracle environment.'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the orarun package is installed and if the oracle user environment must be reset. This is required for SuSE 9.0 only.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="Not installed|Installed correctly|Environment reset not required" result="PASSED"><![CDATA[``orarun`` is not installed or else it is installed correctly.]]></sdp_action>
<sdp_action condition="==" minimum="Not applicable" result="SKIPPED"><![CDATA[This rule only applies to SuSE Linux Enterprise Server 9.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Reset oracle environment.|For SuSE 9.0, follow these steps to reset the environment:%BR%a. Enter the following commands:%BR%``cd /etc/profile.d``%BR%``mv oracle.csh oracle.csh.bak``%BR%``mv oracle.sh oracle.sh.bak``%BR%``mv alljava.sh alljava.sh.bak``%BR%``mv alljava.csh alljava.csh.bak``%BR%b. Use any text editor to comment out%BR%the following line from the%BR%``$HOME/.profile`` file:%BR%``. ./.oracle%BR``%BR%c. Log out of the oracle user account.%BR%d. Log in to the oracle user account for the changes to take effect.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00180" mode="VERIFY" name="semmsl ok?">
<sdp_command type="RDA"><![CDATA[import $BOOK
var ($KER,@KER) = (undef)
call setHcveVariable('$KER','@KER')
if !testFile('x','/sbin/sysctl')
 return setHcveResult('Cannot access /sbin/sysctl')
var @KER = command('/sbin/sysctl -a')
var ($KER) = grep(@KER,'sem','f')
call setHcveResult(cond(\
  expr('>=',field('\s+',2,$KER),256), 'Adequate',\
                                      'Less than 256'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the semmsl kernel parameter is 256 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The semmsl kernel parameter is 256 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 256|Increase semmsl to 256 or higher.  For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in.  For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00182" mode="VERIFY" name="semmns ok?">
<sdp_command type="RDA"><![CDATA[import $KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER)),                   'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',3,$KER),32000), 'Adequate',\
                                        'Less than 32000'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the semmns kernel parameter is 32000 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The semmns kernel parameter is 32000 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 32000|Increase semmns to 32000 or higher.  For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in.  For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00184" mode="VERIFY" name="semopm ok?">
<sdp_command type="RDA"><![CDATA[import $KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER)),                 'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',4,$KER),100), 'Adequate',\
                                      'Less than 100'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the semopm kernel parameter is 100 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The semopm kernel parameter is 100 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 100|Increase semopm to 100 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00186" mode="VERIFY" name="semmni ok?">
<sdp_command type="RDA"><![CDATA[import $KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER)),                 'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',5,$KER),142), 'Adequate',\
                                      'Less than 142'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the semmni kernel parameter is 142 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The semmni kernel parameter is 142 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 142|Increase semmni to 142 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00188" mode="VERIFY" name="shmall ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER[0])),\
    'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',2,grep(@KER,'kernel\.shmall','f')),2097152),\
    'Adequate',\
    'Less than 2097152'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the shmall kernel parameter is 2097152 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The shmall kernel parameter is 2097152 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 2097152|Increase shmall to 2097152 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00190" mode="VERIFY" name="shmmax ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER[0])),\
    'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',2,grep(@KER,'kernel\.shmmax','f')),2147483648),\
    'Adequate',\
    'Less than 2147483648'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the shmmax kernel parameter is 2147483648 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The shmmax kernel parameter is 2147483648 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 2147483648|Increase shmmax to 2147483648 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00192" mode="VERIFY" name="shmmni ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER[0])),\
    'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',2,grep(@KER,'kernel\.shmmni','f')),4096),\
    'Adequate',\
    'Less than 4096'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the shmmni kernel parameter is 4096 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The shmmni kernel parameter is 4096 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 4096|Increase shmmni to 4096 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00194" mode="VERIFY" name="msgmax ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER[0])),\
    'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',2,grep(@KER,'kernel\.msgmax','f')),8192),\
    'Adequate',\
    'Less than 8192'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the msgmax kernel parameter is 8192 or higher. ]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The msgmax kernel parameter is 8192 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 8192|Increase msgmax to 8192 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00196" mode="VERIFY" name="msgmnb ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER[0])),\
    'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',2,grep(@KER,'kernel\.msgmnb','f')),65535),\
    'Adequate',\
    'Less than 65535'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the msgmnb kernel parameter is 65535 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The msgmnb kernel parameter is 65535 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 65535|Increase msgmnb to 65535 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00198" mode="VERIFY" name="msgmni ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER[0])),\
    'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',2,grep(@KER,'kernel\.msgmni','f')),2878),\
    'Adequate',\
    'Less than 2878'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the msgmni kernel parameter is 2878 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The msgmni kernel parameter is 2878 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 2878|Increase msgmni to 2878 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00200" mode="VERIFY" name="file-max ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
call setHcveResult(cond(\
  not(defined($KER[0])),\
    'Cannot access /sbin/sysctl',\
  expr('>=',field('\s+',2,grep(@KER,'file\-max','f')),131072),\
    'Adequate',\
    'Less than 131072'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the file-max kernel parameter is 131072 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The file-max kernel parameter is 131072 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 131072|Increase file-max to 131072 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00202" mode="VERIFY" name="ip_local_port_range ok?">
<sdp_command type="RDA"><![CDATA[import @KER,$BOOK
if !defined($KER[0])
 return setHcveResult('Cannot access /sbin/sysctl')
var (undef,undef,$low,$hig) = split('\s+',grep(\
 @KER,'ip_local_port_range','f'),4)
call setHcveResult(cond(\
  and(expr('<=',$low,10000),expr('>=',$hig,65000)),\
    'Adequate',\
    'Less than 10000 and 65000'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the ``ip_local_port_range`` kernel parameter is between 10000 and 65000 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The ``ip_local_port_range`` kernel parameter is between 10000 and 65000 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 10000 and 65000|Increase ``ip_local_port_range`` to 10000 and 65000 or higher. For information about configuring this parameter, see the ${'BOOK}.|
|Cannot access /sbin/sysctl|Grant execute permissions on ``/sbin/sysctl`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00204" mode="VERIFY" name="Default Ports for 10.1.3.3 ok?">
<sdp_command type="RDA"><![CDATA[import $BOOK
var @tbl = ()
macro chk_prt
{var (\@tbl,$prt) = @arg
 if grepLastFile(concat(':',$prt),'f')
  call push(@tbl,$prt)
}
call loadCommand('netstat -an')
call chk_prt(\@tbl,'5060')
call chk_prt(\@tbl,'5070')
call chk_prt(\@tbl,'5071')
call chk_prt(\@tbl,'5081')
call setHcveResult(cond(\
  scalar(@tbl),concat('[',join(', ',@tbl),'] port(s) is/are already in use.'),\
               'Adequate'))
]]></sdp_command>
<sdp_description><![CDATA[Oracle Cluster Management Software (OCMS) requires the use of ports for TCP and UDP communications for the SIP Container, Presence server, and the Edge Proxy (if installed). You can enable the InstallShield Wizard for OCMS to assign default port numbers for the SIP Container and Edge Proxy ports, or use specified port numbers.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[Default ports are not in use. No action required.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|... port(s) is/are already in use.|For information about how to reconfigure port numbers following installation, see the ''Oracle Communication and Mobility Server Administrator's Guide Release 10.1.3''|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00210" mode="VERIFY" name="Limit Processes ok?">
<sdp_command type="RDA"><![CDATA[import $BOOK
var $shl = getEnv('SHELL')
macro proc_lmt
{var ($cmd,$flg) = @arg
 var ($val) = command($cmd)
 if $flg
  var $val = field('\s+',1,$val)
 if compare('eq',$val,'unlimited')
  return 'Adequate'
 return cond(and(isNumber($val),expr('>=',$val,16384)),\
             'Adequate',\
             'Less than 16384')
}
macro proc_lmt_ksh
{var ($cmd) = @arg
 var $val = field('\s',-1,\
   grepCommand($cmd,'^(max user processes|processes|nproc)','if'))
 if compare('eq',$val,'unlimited')
  return 'Adequate'
 return cond(and(isNumber($val),expr('>=',$val,16384)),\
             'Adequate',\
             'Less than 16384')
}
call setHcveResult(check(\
  $shl,'csh',proc_lmt(concat($shl,' -f -c "limit maxproc"'),true),\
       'ksh',proc_lmt_ksh(concat($shl,' -c "ulimit -a"')),\
             proc_lmt(concat($shl,' -c "ulimit -u"'),false)))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the limit of maximum processes is set to 16384 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The limit of maximum processes is set to 16384 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 16384|Increase the limit for maximum processes to 16384 or higher. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00220" mode="VERIFY" name="Limit Descriptors ok?">
<sdp_command type="RDA"><![CDATA[import $BOOK
var $shl = getEnv('SHELL')
macro proc_lmt
{var ($cmd,$flg) = @arg
 var ($val) = command($cmd)
 if $flg
  var $val = field('\s+',1,$val)
 if compare('eq',$val,'unlimited')
  return 'Adequate'
 return cond(and(isNumber($val),expr('>=',$val,65536)),\
             'Adequate',\
             'Less than 65536')
}
call setHcveResult(check(\
  $shl,'csh',proc_lmt(concat($shl,' -f -c "limit descriptors"'),true),\
             proc_lmt(concat($shl,' -c "ulimit -n"'),false)))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the limit of file descriptors is set to 65536 or higher.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Adequate" result="PASSED"><![CDATA[The limit of descriptors is set to 65536 or higher.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Less than 65536|Increase the limit for file descriptors to 65536 or higher. For information about configuring this parameter, see the ${'BOOK}.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00230" mode="VERIFY" name="Environment Variables ok?">
<sdp_command type="RDA"><![CDATA[if grepEnv('^(TNS_ADMIN|ORA_NLS|LD_BIND_NOW|ANT_HOME)$')
 return setHcveResult('Some variables are set')
if testFile('e','/etc/oratab')
{if !testFile('r','/etc/oratab')
  return setHcveResult('Cannot access /etc/oratab')
 var @pth = (split(':',join(':',getEnv('PATH'),\
                                getEnv('CLASSPATH'),\
                                getEnv('LD_LIBRARY_PATH'))))
 loop $lin (grepFile('/etc/oratab','#|^$','v'))
 {var $pat = concat('^',quote(replace(field(':',1,$lin),'\/+$')),'(\/.*)?$')
  if grep(@pth,$pat)
   return setHcveResult('Variables containing reference to existing \
                         Oracle homes')
 }
}
return setHcveResult('Properly defined')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the following environment variables are not set: ``TNS_ADMIN``, ``ORA_NLS``, ``ANT_HOME``, and ``LD_BIND_NOW``. In addition, the following environment variables must not reference to any existing Oracle home, ``PATH``, ``CLASSPATH``, and ``LD_LIBRARY_PATH``.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Properly defined" result="PASSED"><![CDATA[Environment variables do not have references to existing Oracle home directories.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Variables containing reference to existing Oracle homes|Remove any reference to existing Oracle home directories from ``PATH``, ``CLASSPATH``, and ``LD_LIBRARY_PATH``.|
|Some variables are set|Unset ``TNS_ADMIN``, ``ORA_NLS``, ``ANT_HOME``, and ``LD_BIND_NOW``.|
|Cannot access /etc/oratab|Grant read permissions on ``/etc/oratab`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00240" mode="RECORD" name="IP Address">
<sdp_command type="RDA"><![CDATA[var $hst = field('\.',0,command('hostname'))
var ($lin) = grepFile('/etc/hosts',\
 concat('^[^#]+\s\<?',quote($hst),'\>?($|\.|\s)'),'f')
call setHcveResult(field('\s+',0,$lin))
]]></sdp_command>
<sdp_description><![CDATA[This rule gets the host IP address.]]></sdp_description>
</sdp_rule>

<sdp_rule id="A00250" mode="RECORD" name="Domain Name">
<sdp_dependencies>
<sdp_dependency condition="IS" id="A00240" minimum="RECORD" result="FAILED"><![CDATA[Requires the IP address.]]></sdp_dependency>
</sdp_dependencies>
<sdp_command type="RDA"><![CDATA[var $ip = "%A00240%"
var ($hst) = command('hostname')
var ($nam,$dom) = split('\.',$hst,2)
if testFile('x','/bin/domainname')
 var ($nis) = command('/bin/domainname')
if testFile('r','/etc/resolv.conf')
 var $dns = field('\s+',1,grepFile('/etc/resolv.conf','domain'))
if testFile('x','/usr/bin/nslookup')
{if $nam
 {var $nsl = field(concat(quote($nam),'\.'),1,\
                   grepCommand(concat('/usr/bin/nslookup ',$hst),'Name','f'))
 }
 else
 {var $nsl = field(concat(quote($hst),'\.'),1,\
                   grepCommand(concat('/usr/bin/nslookup ',$hst),'Name','f'))
 }
}
if $ip
{if !$nam
  var $ipn = trim(field(concat($hst,'\.'),1,\
             grepCommand(concat('/usr/bin/nslookup -sil ',$ip),'Name','f')),'.')
}
call setHcveResult(cond($dom,$dom,\
                        and(length($nis),compare('ne',$nis,'(none)')),$nis,\
                        $dns,$dns,\
                        $nsl,$nsl,\
                        $ipn,$ipn,\
                             'Not configured'))
]]></sdp_command>
<sdp_description><![CDATA[This rule gets the host domain name.]]></sdp_description>
</sdp_rule>

<sdp_rule id="A00260" mode="VERIFY" name="DNS Lookup ok?">
<sdp_dependencies>
<sdp_dependency condition="IS" id="A00250" minimum="RECORD" result="FAILED"><![CDATA[Requires host domain name.]]></sdp_dependency>
<sdp_dependency condition="IS" id="A00240" minimum="RECORD" result="FAILED"><![CDATA[Requires IP address.]]></sdp_dependency>
</sdp_dependencies>
<sdp_command type="RDA"><![CDATA[var $dom = "%A00250%"
var $ip  = "%A00240%"
var $hst = field('\.',0,command('hostname'))
if !length($hst)
{if and(compare('ne',$dom,'Not configured'),length($dom))
  var $hst = concat($hst,'.',$dom)
}
call setHcveResult(cond(\
  not(length($ip)),\
    'Cannot determine IP address',\
  not(testFile('x','/usr/bin/nslookup')),\
    'Cannot access /usr/bin/nslookup',\
  not(grepCommand(concat('/usr/bin/nslookup -sil ',$hst),quote($ip),'f')),\
    'nslookup host.domain',\
  not(grepCommand(concat('/usr/bin/nslookup -sil ',$ip),quote($hst),'f')),\
    'nslookup IP_address',\
    'Host correctly registered in DNS'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the host is registered correctly in the DNS.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Host correctly registered in DNS" result="PASSED"><![CDATA[The host is registered correctly in the DNS.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|nslookup host.domain|The DNS server failed to resolve the nslookup using host.domain.|
|nslookup IP_address|The DNS server failed to resolve the nslookup using IP address.|
|Cannot determine IP address|Fix any problem with the host IP address.|
|Cannot access /usr/bin/nslookup|Grant execute permissions on ``/usr/bin/nslookup`` to the user who is logged in.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00270" mode="VERIFY" name="/etc/hosts Format?">
<sdp_dependencies>
<sdp_dependency condition="IS" id="A00250" minimum="PASSED|RECORD" result="FAILED"><![CDATA[Requires domain name.]]></sdp_dependency>
</sdp_dependencies>
<sdp_command type="RDA"><![CDATA[
if !testFile('r','/etc/hosts')
 return setHcveResult('Cannot access /etc/hosts')
if !@tbl = grepFile('/etc/hosts',\
  concat('^([^\s\#]+\s+)+',quote(${RDA.HOST}),\
         '\s+([^\s\#]+\s+)*',quote(${RDA.NODE}),'(\s|\z|\#)'))
 return setHcveResult('no entry found')

# Test that line begins with IPv4 IP address
if grep(@tbl,'^(\d{1,3}\.){3}\d{1,3}\s','f')
 return setHcveResult('Adequate IPv4 entry')

# Tests that line begins with IPv6 IP address, first that all eight groups are populated, then situations where groups that are all zero are omitted (two colons together).
if grep(@tbl,'^([A-F\d]{1,4}(:[A-F\d]{1,4}){7}\s|\
                :(:[A-F\d]{1,4}){1,6}\s|\
                ([A-F\d]{1,4}:){1,5}(:[A-F\d]{1,4}){1,5}\s|\
                ([A-F\d]{1,4}:){1,6}:\s)','f')
 return setHcveResult('Adequate IPv6 entry')
return setHcveResult('no correct entry found')
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the ``/etc/hosts`` file contains a line with ``ip_address fully_qualified_domainname short_hostname``.]]></sdp_description>
<sdp_actions>
<sdp_action condition="=~" minimum="^Adequate" result="PASSED"><![CDATA[The ``/etc/hosts`` entry for the fully qualified domain name and host name is adequate.]]></sdp_action>
<sdp_action condition="==" minimum="Cannot access /etc/hosts" result="FAILED"><![CDATA[Grant read permissions on ``/etc/hosts`` to the current user.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[The fully qualified host name and host name are not configured correctly. Ensure that there is an IP address entry for the fully qualified domain name with the host name as one of the aliases.
|*Return Value*|*Action"|
|no entry found|No entry with the fully qualified domain name followed by the host name was found.|
|no correct entry found|No entry beginning with an IP address with the fully qualified domain name followed by the host name was found.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00280" mode="VERIFY" name="Host Name Length?">
<sdp_command type="RDA"><![CDATA[var $hst = uname('n')
call setHcveResult(cond(\
  expr('>',length($hst),255), 'Host name is greater than 255 characters',\
                              'Host name is less than 255 characters'))
]]></sdp_command>
<sdp_description><![CDATA[This rule ensures that your fully qualified host name is not longer than 255 characters.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Host name is less than 255 characters" result="PASSED"><![CDATA[The host name is less than 255 characters. No action required.]]></sdp_action>
<sdp_action result="FAILED"><![CDATA[Modify your fully qualified host name to less than 255 characters.]]></sdp_action>
</sdp_actions>
</sdp_rule>

<sdp_rule id="A00290" mode="VERIFY" name="Oracle Home Length?">
<sdp_command type="RDA"><![CDATA[var $ORACLE_HOME = getEnv('ORACLE_HOME')
call setHcveResult(cond(\
  not(defined($ORACLE_HOME)),\
    'ORACLE_HOME is not set',\
  expr('<=',length($ORACLE_HOME),127),\
    'Less than 127 char',\
    'Longer than 127 characters'))
]]></sdp_command>
<sdp_description><![CDATA[This rule checks that the path to the Oracle home directory is not longer than 127 characters.]]></sdp_description>
<sdp_actions>
<sdp_action condition="==" minimum="Less than 127 char" result="PASSED"><![CDATA[The Oracle home directory is not longer than 127 characters.]]></sdp_action>
<sdp_action result="FAILED" syntax="wiki"><![CDATA[|*Return Value*|*Action*|
|Longer than 127 characters|Change ``ORACLE_HOME`` to a directory not longer than 127 characters.|
|ORACLE_HOME is not set|Set the ``ORACLE_HOME`` environment variable.|]]></sdp_action>
</sdp_actions>
</sdp_rule>

</sdp_group>
</sdp_content>
</sdp_diaglet>
