Tuesday, September 30, 2014

Playing with puppet vol VII - Oracle module

I've found a puppet module used for installation of Oracle database. It can install database software (Single DB, RAC, Grid, ASM), apply patches and create/start DB instances (see link above for complete list of features). I'll use it to install 11.2.0.3 oracle home, upgrade opatch to 11.2.0.3.6 and to apply PSU11 and timezone patch.

TOC

My puppet master is centos 7 machine named puppet and database host named oradb is also centos 7. I'm using puppet environments and therefore I'll install module into production environment:

[root@puppet environments]# pwd
/etc/puppet/environments
[root@puppet environments]# puppet module install biemond-oradb --environment production
Notice: Preparing to install into /etc/puppet/environments/production/modules ...
Notice: Downloading from https://forgeapi.puppetlabs.com ...
Notice: Installing -- do not interrupt ...
/etc/puppet/environments/production/modules
\-- biemond-oradb (v1.0.18)

I need a staging area for installation files on puppet master. I'll use /orainstall directory:

[root@puppet orainstall]# cd /orainstall/
[root@puppet orainstall]# ls -1
p10404530_112030_Linux-x86-64_1of7.zip     # Installation package part 1
p10404530_112030_Linux-x86-64_2of7.zip     # Installation package part 2
p18522512_112030_Linux-x86-64.zip          # PSU 11
p18759211_112030_Linux-x86-64.zip          # Timezone patch
p6880880_112000_Linux-x86-64.zip           # OPatch utility version 11.2.0.3.6
[root@puppet orainstall]#

I need to make these files known to puppet therefore I'll create symlink in oradb module:

[root@puppet oradb]# cd /etc/puppet/environments/production/modules/oradb/
[root@puppet oradb]# ln -s /orainstall files
[root@puppet oradb]# ls -l files
lrwxrwxrwx. 1 root root 11 Sep 30 14:56 files -> /orainstall

I think that this is not correct. Actually it is pretty bad solution because puppet will complain on it during module uninstallation or update. But I couldn't find out better solution.

Install oracle home

Now I can install database software. I'll use site manifest although it is not good idea:

[root@puppet manifests]# pwd
/etc/puppet/environments/production/manifests
[root@puppet manifests]# cat site.pp
node 'oradb.localdomain' {

    $downloadDir = '/u01/app/oracle/install'
    $ohLocation = '/u01/app/oracle/product/11.2/db_test'

    package { ['ksh', 
               'gcc',
               'libaio',
               'libaio-devel',
               'compat-libstdc++-33',
               'elfutils-libelf-devel',
               'glibc-devel',
               'glibc-headers',
               'gcc-c++',
               'libstdc++-devel',
               'sysstat',
               'psmisc']:
        ensure => 'present',
    }

    oradb::installdb{ 'test_oh':
      version                => '11.2.0.3',
      file                   => 'p10404530_112030_Linux-x86-64',
      databaseType           => 'EE',
      eeOptionsSelection     => true,
      eeOptionalComponents   => 'oracle.rdbms.partitioning:11.2.0.3.0',
      oracleBase             => '/u01/app/oracle',
      oracleHome             => $ohLocation,
      createUser             => true,
      bashProfile            => true,
      user                   => 'oracle',
      group                  => 'dba',
      group_install          => 'oinstall',
      group_oper             => 'oper',
      downloadDir            => $downloadDir,
      zipExtract             => true,
      require                => [Package['ksh'],
                                 Package['gcc'],
                                 Package['libaio'],
                                 Package['libaio-devel'],
                                 Package['compat-libstdc++-33'],
                                 Package['elfutils-libelf-devel'],
                                 Package['glibc-devel'],
                                 Package['glibc-headers'],
                                 Package['gcc-c++'],
                                 Package['libstdc++-devel'],
                                 Package['sysstat'],
                                 Package['psmisc'], # contains fuser utility
                                ],
    }
}

I've defined test_oh oracle home which depends on bunch of packages. If you want puppet to setup kernel parameter, you can use fiddyspence-sysctl module. For setting users limits, you can use erwbgy-limits. Now I'll ask puppet to install this oracle home:

ls: cannot access /u01: No such file or directory
[root@oradb ~]$ puppet agent -t --environment production
.
.
.

It will create directory /u01/app/oracle/install and transfer installation zip archives to this directory:

Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dborainst[database orainst 11.2.0.3]/File[/etc/oraInst.loc]/ensure: created
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dbstructure[oracle structure 11.2.0.3]/File[/u01/app/oracle]/owner: owner changed 'root' to 'oracle'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dbstructure[oracle structure 11.2.0.3]/File[/u01/app/oracle]/group: group changed 'root' to 'oinstall'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dbstructure[oracle structure 11.2.0.3]/File[/u01/app/oracle]/mode: mode changed '0755' to '0775'
Notice: /File[/u01/app/oracle]/seluser: seluser changed 'unconfined_u' to 'system_u'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dbstructure[oracle structure 11.2.0.3]/File[/u01/app/oracle/install]/owner: owner changed 'root' to 'oracle'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dbstructure[oracle structure 11.2.0.3]/File[/u01/app/oracle/install]/group: group changed 'root' to 'oinstall'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dbstructure[oracle structure 11.2.0.3]/File[/u01/app/oracle/install]/mode: mode changed '0755' to '0775'
.
.
.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Oradb::Utils::Dbstructure[oracle structure 11.2.0.3]/File[/u01/app/oracle/oraInventory]/ensure: created
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/File[/u01/app/oracle/install/p10404530_112030_Linux-x86-64_1of7.zip]/ensure: defined content as '{md5}bdbf8e263663214dc60b0fdef5a30b0a'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/File[/u01/app/oracle/install/p10404530_112030_Linux-x86-64_2of7.zip]/ensure: defined content as '{md5}e56b3d9c6bc54b7717e14b6c549cef9e'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[extract /u01/app/oracle/install/p10404530_112030_Linux-x86-64_1of7.zip]/returns: executed successfully
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[extract /u01/app/oracle/install/p10404530_112030_Linux-x86-64_2of7.zip]/returns: executed successfully

Then It will prepare response file and run software installation in silent mode:

Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/File[/u01/app/oracle/install/db_install_11.2.0.3.rsp]/ensure: created
.
.
.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: Starting Oracle Universal Installer...
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: 
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: Checking Temp space: must be greater than 120 MB.   Actual 21093 MB    Passed
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: Checking swap space: must be greater than 150 MB.   Actual 3006 MB    Passed
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: Preparing to launch Oracle Universal Installer from /tmp/OraInstall2014-09-30_03-16-31PM. Please wait ...You can find the log of this install session at:
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns:  /u01/app/oracle/oraInventory/logs/installActions2014-09-30_03-16-31PM.log
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: The installation of Oracle Database 11g was successful.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: Please check '/u01/app/oracle/oraInventory/logs/silentInstall2014-09-30_03-16-31PM.log' for more details.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: 
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: As a root user, execute the following script(s):
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns:      1. /u01/app/oracle/product/11.2/db_test/root.sh
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: 
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: 
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: Successfully Setup Software.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[install oracle database test_oh]/returns: executed successfully
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/File[/u01/app/oracle/product/11.2/db_test]/mode: mode changed '0755' to '0775'
Notice: /File[/u01/app/oracle/product/11.2/db_test]/seluser: seluser changed 'unconfined_u' to 'system_u'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[run root.sh script test_oh]/returns: Check /u01/app/oracle/product/11.2/db_test/install/root_oradb.localdomain_2014-09-30_15-18-56.log for the output of root script
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Installdb[test_oh]/Exec[run root.sh script test_oh]/returns: executed successfully

DB software was successfully installed:

-bash-4.2$ /u01/app/oracle/product/11.2/db_test/OPatch/opatch lsinv
Invoking OPatch 11.2.0.1.7

Oracle Interim Patch Installer version 11.2.0.1.7
Copyright (c) 2011, Oracle Corporation.  All rights reserved.


Oracle Home       : /u01/app/oracle/product/11.2/db_test
Central Inventory : /u01/app/oracle/oraInventory
   from           : /etc/oraInst.loc
OPatch version    : 11.2.0.1.7
OUI version       : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-20-15PM.log

Lsinventory Output file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/lsinv/lsinventory2014-09-30_15-20-15PM.txt

--------------------------------------------------------------------------------
Installed Top-level Products (1): 

Oracle Database 11g                                                  11.2.0.3.0
There are 1 products installed in this Oracle Home.


There are no Interim patches installed in this Oracle Home.


--------------------------------------------------------------------------------

OPatch succeeded.

Upgrade opatch

Now I'll upgrade opatch from 11.2.0.1.7 to 11.2.0.3.6. Here is the puppet code:

   oradb::opatchupgrade{'11.2.0.3_OPatchUpgrade':
     oracleHome        =>  $ohLocation,
     patchFile         => 'p6880880_112000_Linux-x86-64.zip',
     opversion         => '11.2.0.3.6',
     user              => 'oracle',
     group             => 'dba',
     downloadDir       => $downloadDir,
     require           => Oradb::Installdb['test_oh'],
   }

It will transfer patch, extract it to oracle home and create OCM response file:

Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/File[/u01/app/oracle/install/p6880880_112000_Linux-x86-64.zip]/ensure: defined content as '{md5}2ab78cb17174c3a49df560f05e3352c6'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/File[remove_old]/ensure: removed
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/File[/u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/ensure: created
Notice: oradb::opatchupgrade 11.2.0.1.7 installed - performing upgrade
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Notify[oradb::opatchupgrade 11.2.0.1.7 installed - performing upgrade]/message: defined 'message' as 'oradb::opatchupgrade 11.2.0.1.7 installed - performing upgrade'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[extract opatch p6880880_112000_Linux-x86-64.zip]/returns: executed successfully
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: spawn /u01/app/oracle/product/11.2/db_test/OPatch/ocm/bin/emocmrsp -no_banner
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: Provide your email address to be informed of security issues, install and
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: initiate Oracle Configuration Manager. Easier for you if you use your My
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: Oracle Support Email address/User Name.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: Visit http://www.oracle.com/support/policies.html for details.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: Email address/User Name: 
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: 
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: You have not provided an email address for notification of security issues.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]:  Y
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: The OCM configuration response file (ocm.rsp) was successfully created.
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatchupgrade[11.2.0.3_OPatchUpgrade]/Exec[ksh /u01/app/oracle/install/opatch_upgrade_11.2.0.3.6.ksh]/returns: executed successfully

I can verify OPatch version:

-bash-4.2$ /u01/app/oracle/product/11.2/db_test/OPatch/opatch lsinv
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation.  All rights reserved.


Oracle Home       : /u01/app/oracle/product/11.2/db_test
Central Inventory : /u01/app/oracle/oraInventory
   from           : /u01/app/oracle/product/11.2/db_test/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-24-28PM_1.log

Lsinventory Output file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/lsinv/lsinventory2014-09-30_15-24-28PM.txt

--------------------------------------------------------------------------------
Installed Top-level Products (1): 

Oracle Database 11g                                                  11.2.0.3.0
There are 1 product(s) installed in this Oracle Home.


There are no Interim patches installed in this Oracle Home.


--------------------------------------------------------------------------------

OPatch succeeded.

Apply timezone patch

Now I want puppet to apply timezone patch:

  oradb::opatch{'11.2.0.3_TZPatch':
    oracleProductHome => $ohLocation,
    patchId           => '18759211',
    patchFile         => 'p18759211_112030_Linux-x86-64.zip',
    ocmrf             => true,
    user              => 'oracle',
    group             => 'dba',
    downloadDir       => $downloadDir,
    require           => [Oradb::Installdb['test_oh'], Oradb::Opatchupgrade['11.2.0.3_OPatchUpgrade'],],
  }

It will transfer patch, extract patch and apply patch with OPatch:

Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatch[11.2.0.3_TZPatch]/File[/u01/app/oracle/install/p18759211_112030_Linux-x86-64.zip]/ensure: defined content as '{md5}d07cf5d71a888be68ae343fa41a878c0'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatch[11.2.0.3_TZPatch]/Exec[extract opatch p18759211_112030_Linux-x86-64.zip 11.2.0.3_TZPatch]/returns: executed successfully
Info: opatch result: Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation.  All rights reserved.


Oracle Home       : /u01/app/oracle/product/11.2/db_test
Central Inventory : /u01/app/oracle/oraInventory
   from           : /u01/app/oracle/product/11.2/db_test/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-27-01PM_1.log

Applying interim patch '18759211' to OH '/u01/app/oracle/product/11.2/db_test'
Verifying environment and performing prerequisite checks...
All checks passed.
Backing up files...

Patching component oracle.oracore.rsf, 11.2.0.3.0...

Verifying the update...
Patch 18759211 successfully applied
Log file location: /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-27-01PM_1.log

OPatch succeeded.

Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatch[11.2.0.3_TZPatch]/Db_opatch[18759211]/ensure: defined 'ensure' as 'present'

Verification:

-bash-4.2$ /u01/app/oracle/product/11.2/db_test/OPatch/opatch lsinv
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation.  All rights reserved.


Oracle Home       : /u01/app/oracle/product/11.2/db_test
Central Inventory : /u01/app/oracle/oraInventory
   from           : /u01/app/oracle/product/11.2/db_test/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-28-02PM_1.log

Lsinventory Output file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/lsinv/lsinventory2014-09-30_15-28-02PM.txt

--------------------------------------------------------------------------------
Installed Top-level Products (1): 

Oracle Database 11g                                                  11.2.0.3.0
There are 1 product(s) installed in this Oracle Home.


Interim patches (1) :

Patch  18759211     : applied on Tue Sep 30 15:27:07 CEST 2014
Unique Patch ID:  17687868
   Created on 29 May 2014, 15:41:43 hrs PST8PDT
   Bugs fixed:
     18759211



--------------------------------------------------------------------------------

OPatch succeeded.

Apply PSU

And finally I'll apply PSU:

      oradb::opatch{'11.2.0.3_PSU11':
        oracleProductHome => $ohLocation,
        patchId           => '18522512',
        patchFile         => 'p18522512_112030_Linux-x86-64.zip',
        ocmrf             => true,
        user              => 'oracle',
        group             => 'dba',
        downloadDir       => $downloadDir,
        require           => [Oradb::Installdb['test_oh'],
                              Oradb::Opatchupgrade['11.2.0.3_OPatchUpgrade'],
                              Oradb::Opatch['11.2.0.3_TZPatch'],],
      }

Workflow is basically the same as applying timezone patch. Puppet apply output:

Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatch[11.2.0.3_PSU11]/File[/u01/app/oracle/install/p18522512_112030_Linux-x86-64.zip]/ensure: defined content as '{md5}f95192605d63690022bc8835549f9450'
Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatch[11.2.0.3_PSU11]/Exec[extract opatch p18522512_112030_Linux-x86-64.zip 11.2.0.3_PSU11]/returns: executed successfully
OPatch Session completed with warnings.
Info: opatch result: Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation.  All rights reserved.


Oracle Home       : /u01/app/oracle/product/11.2/db_test
Central Inventory : /u01/app/oracle/oraInventory
   from           : /u01/app/oracle/product/11.2/db_test/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-31-08PM_1.log

Verifying environment and performing prerequisite checks...
OPatch continues with these patches:   13343438  13696216  13923374  14275605  14727310  16056266  16619892  16902043  17540582  18031683  18522512  

Do you want to proceed? [y|n]
Y (auto-answered by -silent)
User Responded with: Y
All checks passed.

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/u01/app/oracle/product/11.2/db_test')


Is the local system ready for patching? [y|n]
Y (auto-answered by -silent)
User Responded with: Y
Backing up files...
Applying sub-patch '13343438' to OH '/u01/app/oracle/product/11.2/db_test'

Patching component oracle.rdbms.rsf, 11.2.0.3.0...

Patching component oracle.rdbms, 11.2.0.3.0...
.
.
.
Patching component oracle.rdbms.rman, 11.2.0.3.0...

Patching component oracle.rdbms.dbscripts, 11.2.0.3.0...

Verifying the update...

OPatch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ins_precomp.mk:19: warning: overriding recipe for target `pcscfg.cfg'
/u01/app/oracle/product/11.2/db_test/precomp/lib/env_precomp.mk:2160: warning: ignoring old recipe for target `pcscfg.cfg'
/u01/app/oracle/product/11.2/db_test/precomp/lib/ins_precomp.mk:19: warning: overriding recipe for target `pcscfg.cfg'
/u01/app/oracle/product/11.2/db_test/precomp/lib/env_precomp.mk:2160: warning: ignoring old recipe for target `pcscfg.cfg'



OPatch found the word "warning" in the stderr of the make command.
Please look at this stderr. You can re-run this make command.
Stderr output:
ins_emagent.mk:113: warning: overriding recipe for target `nmosudo'
ins_emagent.mk:52: warning: ignoring old recipe for target `nmosudo'
/u01/app/oracle/product/11.2/db_test/sysman/lib/ins_emagent.mk:113: warning: overriding recipe for target `nmosudo'
/u01/app/oracle/product/11.2/db_test/sysman/lib/ins_emagent.mk:52: warning: ignoring old recipe for target `nmosudo'


Composite patch 18522512 successfully applied.
Log file location: /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-31-08PM_1.log

OPatch completed with warnings.

Notice: /Stage[main]/Main/Node[oradb.localdomain]/Oradb::Opatch[11.2.0.3_PSU11]/Db_opatch[18522512]/ensure: defined 'ensure' as 'present'

And verification with OPatch:

-bash-4.2$ /u01/app/oracle/product/11.2/db_test/OPatch/opatch lsinv
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation.  All rights reserved.


Oracle Home       : /u01/app/oracle/product/11.2/db_test
Central Inventory : /u01/app/oracle/oraInventory
   from           : /u01/app/oracle/product/11.2/db_test/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/opatch2014-09-30_15-36-28PM_1.log

Lsinventory Output file location : /u01/app/oracle/product/11.2/db_test/cfgtoollogs/opatch/lsinv/lsinventory2014-09-30_15-36-28PM.txt

--------------------------------------------------------------------------------
Installed Top-level Products (1):

Oracle Database 11g                                                  11.2.0.3.0
There are 1 product(s) installed in this Oracle Home.


Interim patches (2) :

Patch  18522512     : applied on Tue Sep 30 15:34:18 CEST 2014
Unique Patch ID:  17629436
Patch description:  "Database Patch Set Update : 11.2.0.3.11 (18522512)"
   Created on 11 Jun 2014, 05:48:32 hrs PST8PDT
Sub-patch  18031683; "Database Patch Set Update : 11.2.0.3.10 (18031683)"
Sub-patch  17540582; "Database Patch Set Update : 11.2.0.3.9 (17540582)"
Sub-patch  16902043; "Database Patch Set Update : 11.2.0.3.8 (16902043)"
Sub-patch  16619892; "Database Patch Set Update : 11.2.0.3.7 (16619892)"
Sub-patch  16056266; "Database Patch Set Update : 11.2.0.3.6 (16056266)"
Sub-patch  14727310; "Database Patch Set Update : 11.2.0.3.5 (14727310)"
Sub-patch  14275605; "Database Patch Set Update : 11.2.0.3.4 (14275605)"
Sub-patch  13923374; "Database Patch Set Update : 11.2.0.3.3 (13923374)"
Sub-patch  13696216; "Database Patch Set Update : 11.2.0.3.2 (13696216)"
Sub-patch  13343438; "Database Patch Set Update : 11.2.0.3.1 (13343438)"
   Bugs fixed:
     13593999, 10350832, 14138130, 12919564, 14198511, 13561951, 13588248
     13080778, 13804294, 16710324, 18031683, 12873183, 14193240, 16992075
.
.
.

5 comments:

  1. You did not run root.sh after software installation:

    /u01/app/oracle/product/11.2/db_test/sysman/lib/ins_emagent.mk:113: warning: overriding recipe for target `nmosudo'
    /u01/app/oracle/product/11.2/db_test/sysman/lib/ins_emagent.mk:52: warning: ignoring old recipe for target `nmosudo'

    ReplyDelete
  2. Hello

    How do you run the post patch steps when applying patch using opatch?
    ./datapatch -verbose

    Regards

    ReplyDelete
  3. Replies
    1. I'm getting below error not sure why! please help..
      Error: /Stage[main]/Main/Node[puppetclient]/Oradb::Installdb[112030_Linux-x86-64]/File[/u01/app/oracle/install/p10404530_112030_Linux-x86-64_1of7.zip]: Could not evaluate: Could not retrieve information from environment production source(s) file:/orainstall/p10404530_112030_Linux-x86-64_1of7.zip

      Delete