Sun Microsystems, Inc.  Oracle System Handbook - ISO 7.0 May 2018 Internal/Partner Edition
   Home | Current Systems | Former STK Products | EOL Systems | Components | General Info | Search | Feedback

Asset ID: 1-71-1675774.1
Update Date:2014-05-27
Keywords:

Solution Type  Technical Instruction Sure

Solution  1675774.1 :   Case Studies - dbnodeupdate.sh incomplete execution  


Related Items
  • Exadata Database Machine V2
  •  
Related Categories
  • PLA-Support>Eng Systems>Exadata/ODA/SSC>Oracle Exadata>DB: Exadata_EST
  •  




In this Document
Goal
Solution


Applies to:

Exadata Database Machine V2 - Version All Versions to All Versions [Release All Releases]
Information in this document applies to any platform.

Goal

 There is an increase number of cases related to failures of dbnodeupdate.sh and all related to similar characteristics.
This document contains some details and hints to diagnose the problem and hopefully lead to a faster resolution.

Solution


First, let's describe a simple workflow of dbnodeupdate.

1. When the current version of the Exadata Software image is 11.2.2.4.2 (this is the minimum version that dbnodeupdate.sh works with), there are two simple steps:

    * dbnodeupdate.sh will execute the bootstrap.sh phase 1 when executing dbnodeupdate.sh -u -l /u01/p16432033_112321_Linux-x86-64.zip
    * After machine reboots, phase 2 is executed via ./dbnodeupdate.sh -u -p 2

2. When the current version of the Exadata image is 11.2.3.2.X, also two steps are executed:
    *  ./dbnodeupdate.sh -u -l /u01/p16432033_112321_Linux-x86-64.zip
    * After machine reboots, dbnodeupdate.sh -c is required to complete the installation.

There are specific differences on the procedure based on the current Exadata Software image, but at some point, the following workflow will be the same when applying the new Exadata  Software image.

  • Installation of the exadata-sun-computenode via yum -y install command:

 

[1400789725][2014-05-22 16:22:06 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrepYumStmnt112330][]  Command constructed is: yum -y install --nogpgcheck exadata-sun-computenode-exact-11.2.3.3.0.131014.1-1 exadata-sun-computenode-minimum-11.2.3.3.0.131014.1-1 --disableplugin=aliases,changelog,fastestmirror,filter-data,keys,kmod,list-data,priorities,protect-packages,protectbase,ulninfo,rhnplugin,security,tmprepo,verify,versionlock  --disablerepo=* --enablerepo=exadata_generated_220514161522

  


Some important data reported in the log file:

 

[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Entering PrintConfirmation
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Active Image version   : 11.2.3.2.1.130302
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Active Kernel version  : 2.6.32-400.21.1.el5uek
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Active LVM Name        : /dev/mapper/VGExaDb-LVDbSys1
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Inactive Image version : 11.2.3.1.1.120607
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Inactive LVM Name      : /dev/mapper/VGExaDb-LVDbSys2
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Current user id        : root
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Action                 : ^[[1mupgrade ^[(B^[[m
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Upgrading to           : ^[[1m11.2.3.3.0.131014.1 (to exadata-sun-computenode-exact)^[(B^[[m
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Baseurl                : file:///var/www/html/yum/unknown/EXADATA/dbserver/220514160423/x86_64/ (iso)
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Iso file               : /u01/app/oracle/stage.220514160423/repoimage.iso
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Create a backup        : Yes
[1400789065][2014-05-22 16:05:02 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintConfirmation][]  Shutdown stack         : No (Currently stack is up)

  

 

As part of the installation of the exadata-sun-computenode* rpms, the log file will display the progress of differenct activities like:

 

    • Resolve Dependencies


 

Setting up Install Process
    Resolving Dependencies
    --> Running transaction check
    ---> Package exadata-sun-computenode-exact.x86_64 0:11.2.3.3.0.131014.1-1 set to be updated
    --> Processing Dependency: symlinks = 1.2-26.el5 for package: exadata-sun-computenode-exact

  

 



    • Transaction summary and indication that rpms have been installed

     


 

Transaction Summary
    ================================================================================
    Install      37 Package(s)
    Upgrade     174 Package(s)

    Total download size: 832 M
    Downloading Packages:
    --------------------------------------------------------------------------------
    Total                                            16 GB/s | 832 MB     00:00
    Running rpm_check_debug
    Running Transaction Test
    Finished Transaction Test
    Transaction Test Succeeded
    Running Transaction
    ^M  Updating       : libgcc                                                 1/387
    ^M  Updating       : oraclelinux-release                                    2/387
……

    ^M  Cleanup        : perftest                                             378/387
    ^M  Cleanup        : openssl                                              379/387
    ^M  Cleanup        : glibc-headers                                        380/387
    ^M  Cleanup        : sysstat                                              381/387
    ^M  Cleanup        : numactl-devel                                        382/387
    ^M  Cleanup        : ksh                                                  383/387
    ^M  Cleanup        : logrotate                                            384/387
    ^M  Cleanup        : libgcc                                               385/387
    ^M  Cleanup        : sudo                                                 386/387
    ^M  Cleanup        : ibsim                                                387/387

    Installed:
      exadata-sun-computenode-exact.x86_64 0:11.2.3.3.0.131014.1-1
      exadata-sun-computenode-minimum.x86_64 0:11.2.3.3.0.131014.1-1
      mstflint.x86_64 0:1.4-9.mlnx1.5.5r2.el5

    Dependency Installed:
      acpid.x86_64 0:1.0.4-12.el5
      aic94xx-firmware.noarch 0:30-2.el5

  


    We can see that all the 387 files were installed, also the exadata-sun-computenode* was installed.

 



    • The exadata-sun-computenode have a preinstall/postinstall scriptlet.  They are triggered as soon as the exadata-sun-computenode* rpm are installed.  dbnodeupdate.sh will wait up to 900 seconds for completion.

 

 

Replaced:
      tvflash.x86_64 0:0.9.0-2.el5

    Complete!
[1400789725][2014-05-22 16:23:54 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][HandleUpdateOutcome][]  Entering HandleUpdateOutcome doupdate
[1400789725][2014-05-22 16:23:54 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][HandleUpdateOutcome][]  Picking up from root post - waiting here
[1400789725][2014-05-22 16:23:54 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][HandlePostScriptlet][]  Entering HandlePostScriptlet
[1400789725][2014-05-22 16:23:54 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][HandlePostScriptlet][]  Waiting for post rpm script to finish. Sleeping another 60 seconds (60 / 900)
[1400789725][2014-05-22 16:23:54 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintMsg][]    (ACTION:) Waiting for post rpm script to finish. Sleeping another 60 seconds (60 / 900)
[1400789725][2014-05-22 16:24:54 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][HandlePostScriptlet][]  Waiting for post rpm script to finish. Sleeping another 60 seconds (120 / 900)
[1400789725][2014-05-22 16:24:54 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintMsg][]    (ACTION:) Waiting for post rpm script to finish. Sleeping another 60 seconds (120 / 900)

  

    • Here is where update could be interrupted.   The expected outcome is that before 900 seconds, the post-install is complete and machine should reboot.  If machine is not rebooted  after 900 seconds, dbnodeupdate.log will report something like:

     

 

1400789725][2014-05-22 16:37:55 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintMsg][]    (ACTION:) Waiting for post rpm script to finish. Sleeping another 60 seconds (900 / 900)
[1400789725][2014-05-22 16:38:55 -0400][FILE][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][HandlePostScriptlet][]  [FILE: /var/log/cellos/exadata.computenode.post.log]
    2013-10-01 15:38:50
    2013-10-01 15:38:50  Logging started in /var/log/cellos/exadata.computenode.post.log at Tue Oct  1 15:38:50 EDT 2013
    2013-10-01 15:38:50  [INFO] Current image version: 11.2.3.1.1.120607
    2013-10-01 15:38:50  [INFO] New image version is 11.2.3.2.1.130302

Note the content of the file exadata.computenode.post.log is old.  That means this file has not been updated.  Also, the file dbnodeupdate.log will report that the post-install scriplet did not finish:

[1400789725][2014-05-22 16:38:55 -0400][ERROR][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][HandlePostScriptlet][]  Post RPM scriplet did not complete within the expected time.
[1400789725][2014-05-22 16:38:55 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintErrorNextSteps][]  Entering PrintErrorNextSteps
[1400789725][2014-05-22 16:38:55 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][PrintErrorNextSteps][]  Leaving PrintErrorNextSteps
[1400789725][2014-05-22 16:38:55 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][CleanupIsoAndMount][]  Entering CleanupIsoAndMount
[1400789725][2014-05-22 16:38:55 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][CleanupIsoAndMount][]  Unmounting the loop on /var/www/html/yum/unknown/EXADATA/dbserver/220514161522
[1400789725][2014-05-22 16:38:55 -0400][INFO][/u01/software/patch/18370227/Infrastructure/ExadataDBNodeUpdate/3.26/dbnodeupdate.sh][CleanupIsoAndMount][]  umount loop successful

  


    • The post-install scriplet is a shell script running different things, but there is one important command associated to this situation:


NOTE:  Each version of the exadata-sun-computenode* will have similar calls but with different arguments.  Below is the case for 11.2.3.3.0:


    /sbin/service exachkcfg postrpm 11.2.3.3.0.131014.1 exadata-sun-computenode $EXADATA_DBNODEUPDATE_ACTIVE

In file /etc/init.d/exachfg, will execute

    nohup opt/oracle.cellos/exadata.computenode.post.sh $version $name "$yum_opts" $dbupdate_active

    Example for 11.2.3.3.0

    /opt/oracle.cellos/exadata.computenode.post.sh 11.2.3.3.0.131014.1 exadata-sun-computenode-11.2.3.3.0.131014.1-1.x86_64



    • As mentioned before, in this stage is where normal process can be interrupted and a common cause is associated with the modification of the "profile" scripts (environment definition).

 


Known cases



1. Modification of /etc/profile.   Bug 18245341

    Following code was added to file /etc/profile

     if [[ ! -d $HOME ]]
     then
             echo "You are not authorized to access this server."
             logger -p user.err "Login denied by /etc/profile due to no home directory..."
             exit
     fi

    This interrupted the execution of the post-install scriptlet because during the execution, the /etc/profile is loaded but HOME variable is null.  Because of the referenced code, execution of the scriplet will exit
    and will not complete.

    Workaround

    1. Remove the entry from /etc/profile
    2. Adjust code to

     if [[ ! -d $HOME ]]
     then
         if [ "$EXADATA_DBNODEUPDATE_ACTIVE" != 'yes' ]
         then
             echo "You are not authorized to access this server."
             logger -p user.err "Login denied by /etc/profile due to no home directory..."
           exit
        fi
     fi


2. Modification of file /root/.bash_profile

    This case, file /root/.bash_profile was modified with a lot of code, but most important:

    # rootlog script
       DATE=`date +%m%d%y`
       TIME=`date +%T`
       script /var/log/rootlogs/root.$DATE.$TIME.$PPID.out
       exit 0



    The script /opt/oracle.cellos/exadata-computenode-post.sh, the first line is "#!/bin/bash -l" where the -l flag means: Make bash act as if it had been invoked as a login shell.
    The /root/.bash_profile will be executed and when the line "exit 0" will cause to terminate the execution of the session, not completing the post-install scriplet execution.

 

Workaround

  • Remove line with exit 0 or better use a clean /root/.bash_profile (no modifications).

 

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
    . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH
unset USERNAME

  

3. Another modification of file /root/.bash_profile

    This time, file /root/.bash_profile was modified with following line

    cd /tmp

    This cause the confusion of the post-install scriplet

    [1400677260][2014-05-21 15:41:34 +0200][INFO][/opt/oracle.SupportTools/dbnodeupdate_helpers/11.2.3.3.0/bootstrap.uln/dbnodeupdate.sh][PrintMsg][]    (ACTION:) Waiting for post rpm script to finish. Sleeping another 60 seconds (900 / 900)
    [1400677260][2014-05-21 15:42:34 +0200][WARNING][/opt/oracle.SupportTools/dbnodeupdate_helpers/11.2.3.3.0/bootstrap.uln/dbnodeupdate.sh][HandlePostScriptletOneTime][]  [FILE: /var/log/cellos/exadata.computenode.post.log]
        File is not an     absolute path or doesn't exist in current working directory /opt/oracle.SupportTools/dbnodeupdate_helpers/11.2.3.3.0/bootstrap.uln
    [1400677260][2014-05-21 15:42:34 +0200][ERROR][/opt/oracle.SupportTools/dbnodeupdate_helpers/11.2.3.3.0/bootstrap.uln/dbnodeupdate.sh][HandlePostScriptletOneTime][]  bootstrap.sh did not complete, exiting

Workaround

Remove customization to the file /root/.bash_profile.

 

Additional Notes

 

    • How to complete the execution of dbnodeupdate?

 

The clean method will be running dbnodeupdate.sh rollback after identifying and fixing the cause of the problem.  Of course this will take longer time.

There is another option but needs to be executed with caution and it may be different through releases.   Below is an example of 11.2.3.3.0 and basically is the execution of certain scripts.

Everything is based on the ID assigned for the last execution of dbnodeupdate.sh

 

i) create the following directories ( You can refer the dbnodeupdate.log of last try runid -

In this example :- dbnodeupdate.sh runid - 220514160310

# mkdir /var/www/html/yum/unknown/EXADATA/dbserver/220514160310
# mkdir /u01/app/oracle/stage.220514160310

ii) unzip the file for 11.2.3.3.0 (p17809253_112330_Linux-x86-64.zip )

# unzip /u01/software/patch/p17809253_112330_Linux-x86-64.zip /u01/app/oracle/stage.220514160310/.

iii) mount the ISO

# mount -o loop /u01/app/oracle/stage.220514160310/repoimage.iso /var/www/html/yum/unknown/EXADATA/dbserver/220514160310

iv) Run exadata.computenode.post.sh

For 112330 this results in execution of:
 .
# /opt/oracle.cellos/exadata.computenode.post.sh 11.2.3.3.0.131014.1 exadata-sun-computenode-11.2.3.3.0.131014.1-1.x86_64

 

    • How to get the content of the scriplet

 

# rpm -q --scripts exadata-sun-computenode > postscrp.txt

 


Attachments
This solution has no attachment
  Copyright © 2018 Oracle, Inc.  All rights reserved.
 Feedback