Photo by Debby Hudson on Unsplash

In the previous blog posts I explained mainly how to create, alter and tweak the configuration file for the AutoUpgrade tool. By now you should have your config file set up and adjusted for your environment(s). Let me go a step further and explain the different processing modes of AutoUpgrade: ANALYZE, FIXUPS, UPGRADE and DEPLOY modes. Then you’ll have a precise idea what the tool is actually doing, and how it operates.

AutoUpgrade – Step-by-step

  1. The new AutoUpgrade Utility – Download, documentation and supported versions
  2. Create and adjust the config file for AutoUpgrade
  3. Config file for AutoUpgrade – Advanced options
  4. Config file for AutoUpgrade – Tweaking init parameters
  5. AutoUpgrade: ANALYZE, FIXUPS, UPGRADE and DEPLOY modes
  6. AutoUpgrade: Where do you find all the logfiles?
  7. UPG: The AutoUpgrade Command Line Interface
  8. Upgrading Multitenant databases with AutoUpgrade
  9. Moving to a new server with AutoUpgrade
  10. How to tweak the hidden settings in AutoUpgrade
  11. AutoUpgrade and Data Guard, RAC, Restart and non-CDB to PDB
  12. AutoUpgrade and Wallets

Overview – 4 different modes

First of all, you will find the different modes of AutoUpgrade described in the Oracle 19c Upgrade Guide. These modes are:

  • analyze
  • fixups
  • upgrade
  • deploy

Analyze Mode

The analyze mode does not change your source database. It just reads from it. And as its name says, it analyzes your database. But it does more than running just the preupgrade.jar. It checks your setup as well.


It produces two files with information about your database, one in html, another one in text format: SID.htmland SID_preupgrade.log.

java -jar autoupgrade.jar -config myconfig.cfg -mode analyze

We highly recommend that you run the analyze phase in all cases. Once it completes successfully without error, you can be sure that the database won’t get any unforeseen surprises during a subsequent unattended upgrade. You will use this mode also for cases where you move to a new server. You’ll execute it on the source server and set source and target homes to the same value (the source home) in your config file.

    Fixups Mode

    The fixups mode does more than the analyze. It changes your database in the source environment. It performs the same checks as it does in analyze of course before it fixes the findings.

    AutoUpgrade: ANALYZE, FIXUPS, UPGRADE and DEPLOY modes

    It generates a status file (see the blog post about AutoUpgrade logs). In case you use it for a system move, you will execute the fixups phase on the source environment with source and target home set to the source home’s directory in the config file.

    java -jar autoupgrade.jar -config myconfig.cfg -mode fixups

    Upgrade Mode

    The upgrade mode is only meant for cases where you don’t have access to the source home. You need this mode only for cases where you move to a new server, and the source home does not exist on this server. It runs the actual database upgrade and the post upgrade steps. But it does neither create a guaranteed restore point nor does it drain any load.
    Description of autoupgrade-upgrade-flow.eps follows

    java -jar autoupgrade.jar -config myconfig.cfg -mode upgrade

    In this mode, no postupgrade actions will be performed automatically.

    Deploy Mode

    The deploy mode is the most important – and the comprehensive mode as it does everything in one pass, analyze, fixups and upgrade including the postupgrade actions.

    AutoUpgrade: ANALYZE, FIXUPS, UPGRADE and DEPLOY modes

    In addition to calling the modes directly, it creates a guaranteed restore point where possible and drains the load.

    java -jar autoupgrade.jar -config myconfig.cfg -mode deploy

    It writes all the necessary logs. And it upgrades your entire database from start till end with just a single call. Unattended.

    Matrix and Overview

    This graph shows you the operations done in each mode when you call the autoupgrade.jar:

    AutoUpgrade: ANALYZE, FIXUPS, UPGRADE and DEPLOY modes

    AutoUpgrade Matrix: Which operations happen in which mode?

    Best Practice and Recommendation

    We recommend to always run the analyze mode at first. If it is successful, the AutoUpgrade can fix all things it found. Then you call autoupgrade.jar again in deploy mode with a start_time set to the desired time. And it will upgrade your database. The deploy will repeat the analyze part.

    For instance, you call at 15:00h:

    java -jar autoupgrade.jar -config myconfig.cfg -mode analyze

    And then, with a start_time set in your config file at 23:00h the same day:

    java -jar autoupgrade.jar -config myconfig.cfg -mode deploy

    Once the analyze does not show any errors, all is fine for a unattended upgrade with deploy.



    Share this: