Updating an IBM Db2 Warehouse MPP deployment on Linux

Use the following procedure to update a working Db2® Warehouse MPP deployment. The update process is usually significantly faster than the initial deployment process. All of your data and settings will automatically be preserved after the update.

Before you begin

  • Clear your browser cache.
  • Stop all applications that are connected to the Db2 Warehouse database.
  • Close the web console.
  • Ensure that your Linux® system meets the prerequisites described in Getting container images.

Procedure

  1. Ensure that you have root authority on the host operating system.
  2. Log in to Docker by using your API key:
    echo <apikey> | docker login -u iamapikey --password-stdin icr.io
    where <apikey> is the API key that you created as a prerequisite in Getting container images.
  3. To reduce system downtime, on each node host in the MPP cluster, issue one of the following commands:
    • For POWER® LE hardware:
      docker pull icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-ppcle
    • For z Systems® hardware:
      docker pull icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-s390x
    • For x86 hardware:
      docker pull icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-linux
  4. If you are unsure which host is the head-node host, identify it by issuing the following command:
    docker exec -it Db2wh status
    The head node host is identified in the IBM Db2 Warehouse Cluster Status section of the output.
  5. Shut down all services by issuing the following command on the head-node host:
    docker exec -it Db2wh stop
  6. Stop the Db2 Warehouse container by issuing the following command on all node hosts:
    docker stop Db2wh
  7. Rename the current version’s container by issuing the following command on all node hosts:
    docker rename Db2wh v11.5.6.0
  8. Spin up the new Db2 Warehouse container by issuing one of the following docker run commands concurrently on all node hosts. Do not wait until the command finishes running on one node host before issuing it on another.
    • For POWER LE hardware:
      docker run -d -it --privileged=true --net=host --name=Db2wh -v /mnt/clusterfs:/mnt/bludata0 -v /mnt/clusterfs:/mnt/blumeta0 icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-ppcle
    • For z Systems hardware:
      docker run -d -it --privileged=true --net=host --name=Db2wh -v /mnt/clusterfs:/mnt/bludata0 -v /mnt/clusterfs:/mnt/blumeta0 icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-s390x
    • For x86 hardware:
      docker run -d -it --privileged=true --net=host --name=Db2wh -v /mnt/clusterfs:/mnt/bludata0 -v /mnt/clusterfs:/mnt/blumeta0 icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-linux
  9. Issue the following command to check whether the deployment is progressing successfully:
    docker logs --follow Db2wh
  10. Exit the Docker logs by pressing Ctrl+C.

Troubleshooting

If the update attempt fails with SQL code SQL5005C, carry out the troubleshooting procedure. To check the deployment log for SQL code SQL5005C, issue the following command:
dashDB bash -c 'cat $PRODUCT_LOGFILE | grep "SQL5005C"'
Troubleshooting procedure:
  1. Issue the following command to stop the container services for the failed container:
    docker exec -it Db2wh stop
  2. Issue the following command to stop the container on all nodes:
    docker stop Db2wh
  3. Issue the following command to remove the failed container:
    docker rm Db2wh
  4. Restart the update by issuing one of the following docker run commands concurrently on all node hosts. Do not wait until the command finishes running on one node host before issuing it on another.
    • For POWER LE hardware:
      docker run -d -it --privileged=true --net=host --name=Db2wh -v /mnt/clusterfs:/mnt/bludata0 -v /mnt/clusterfs:/mnt/blumeta0 icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-ppcle
    • For z Systems hardware:
      docker run -d -it --privileged=true --net=host --name=Db2wh -v /mnt/clusterfs:/mnt/bludata0 -v /mnt/clusterfs:/mnt/blumeta0 icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-s390x
    • For x86 hardware:
      docker run -d -it --privileged=true --net=host --name=Db2wh -v /mnt/clusterfs:/mnt/bludata0 -v /mnt/clusterfs:/mnt/blumeta0 icr.io/obs/hdm/db2wh_ee:v11.5.6.0-db2wh-linux

What to do next

After you verify that the update was successful, delete the old image and container.