Migrate from db2 9.7 express-c to db2 11.5 developer - db2

I have an old application handling data on a DB2 server (Linux version, 9.7 express-c) and I need to upgrade the server. I searched on the IBM site and I found that the last "free" version (11.5) is the only one available, but I cannot restore a backup taken from a 9.7 directly into the 11.5.
Is there any other way instead of using db2look and db2move?
Do anyone know if it's possible to find the 11.1 developer Linux version?

You can download the server-fixpack via https://www.ibm.com/support/pages/node/6427871
( IBM registration is required ),
This is an indirect way to IBM passport advantage website. It's important to choose the "DB2 Server Fix Pack" as distinct from other images. It is wise to always download the most recent fixpack for the release when using the Server-Fixpack, these fixpacks are cumulative and do not require the base version to be preinstalled.
You can get a trial license with it and just do the intermediate restore (from the v9.7 backup-image into a disposable Db2 v11.1 instance, then backup that database offline and copy the image to a place accessible to your Db2 v11.5 new instance.
You can then drop the v11.1 db2instance, and uninstall the Db2 v11.1 product.
Finally restore that Db2 v11.1 backup image into your Db2 v11.5 instance. This will upgrade the database to the Db2 v11.5 release, consider running db2updv115 afterwards, and revalidating all objects with SYSPROC.ADMIN_REVALIDATE_DB_OBJECTS etc.
Whether the above indirect method is quicker (or easier) than using db2move to export and load, will depend on the complexity of your database. Worth checking...if your Db2 v9.7 instance is still running of course.
Other methods are possible, if you want to spend $$ on recovery tools that extract data from backup images.

Related

Azure Postgres Single server version upgrade

Azure Postgres Single server version is 11. Is it possible to upgrade it to 13+ version using dump and restore as mentioned here:
https://learn.microsoft.com/en-us/azure/postgresql/how-to-upgrade-using-dump-and-restore
It should still remain Single Server.
Yes, you can.
The document you shared is Microsoft's official and therefore there is no doubt that you can upgrade it to any higher version using dump and restore.
Just take care of the below mentioned points:
You can upgrade your PostgreSQL server deployed in Azure Database for PostgreSQL by migrating your databases to a higher major version server using following methods.
Offline method using PostgreSQL pg_dump and pg_restore which incurs downtime for migrating the data.
Online method using Database Migration Service (DMS). This method provides a reduced downtime migration and keeps the target database in-sync with the source and you can choose when to cut-over. However, there are few prerequisites and restrictions to be addressed for using DMS.
The following table provides some recommendations based on database sizes and scenarios.
Choose the right approach based on your database configuration and it should be done without any issue.
To upgrade using pg_dump and pg_restore, you can refer Migrate your PostgreSQL database by using dump and restore.
It is not possible.
In the document, prerequisites states:
A source PostgreSQL database server running a lower version of the
engine that you want to upgrade. A target PostgreSQL database server
with the desired major version Azure Database for PostgreSQL server -
Single Server or Azure Database for PostgreSQL - Flexible Server.
The question asks about upgrading target.

AWS RDS PostgreSQL Upgrade from 9.6.22 to 10.17

Good day. I just finished upgrading my AWS RDS database engine from 9.6.22 to 10.17. I used these steps to make the upgrade using the AWS Console:
Create snapshot of target database to upgrade
Restore snapshot
Upgrade the restored snapshot's (which is now a new instance) DB Engine version.
After I did all of this, everything seems fine but when I access the database, this warning message appears
WARNING: psql major version 9.6, server major version 10.
Some psql features might not work.
I did not continue on my testing because I want to know what is the meaning of this first. Because I am fairly new in AWS as a whole. Thanks!
The meaning is that just because you are connecting to an upgraded database on some machine run by Amazon, the PostgreSQL installation on your local machine was not magically updated. psql from version 9.6 doesn't know what metadata tables were changed in v10, what features were removed and so on.
It would be a good idea to install a more recent version of PostgreSQL on your machine. By the way, upgrading to v10 was not the smartest move, as that version will go out of support in less than a year. You should upgrade to the latest version that your service provider offers.
The client program psql you are using to connect to the database is from an older version than the database it is connecting to. Some of the introspection features might not work. For example, psql from 9.6 won't know how to do tab completion for commands that were added to the server after 9.6.
This is generally not a major problem for psql (unless the server wants to use SCRAM authentication), but for optimal experience it would be good to install a newer client. Other tools like pg_dimp might not with at all against a server newer than they are.

What are the steps to upgrade from Db2 10.5 to DB2 11.1 with loosing any persisted data

We are currently using 10.5 version of DB2 and we are planning to upgrade to 11.1 version of DB2. I would like to know if the upgrade scenario does backup of the persisted data of 10.5 DB2 version to a specific location and after the upgrade the Db2 picks same data from the backup location?
If there is no provision in such a way of a backup location, would like to know the steps to backup the persisted data and other things I have to take into consideration while making the upgrade.
During a Db2 upgrade, it is your responsibility to take a backup copy of the database prior to the the upgrade.
There are instructions here within the overall Database Fundamentals - Upgrating section of the manuals
https://www.ibm.com/support/knowledgecenter/SSEPGG_11.5.0/com.ibm.db2.luw.qb.upgrade.doc/doc/t0007139.html

Connecting to DB2 using SQL Developer

I trying to connect to DB2 database through SQL Developer. I followed following steps create connection:
1. Open SQL Developer
2. Go to Tools > Preferences > Database > Third Party JDBC Drivers.
3. I added third-party JDBC driver path entries (db2jcc.jar and db2jcc_license_cu.jar)
As soon as I try to create connection I get below error
Oracle SQL-Developer Version 17.2 works fine for me with Db2 Version 11 for Linux x64 and I am using a recent Type-4 jdbc (db2jcc4.jar) driver from IBM.
You question shows that your Db2 jdbc driver version is very old (Version 9.7 fixpack 5) and out of support, so you should upgrade to the latest available Db2 client for your (unspecified) operating-system. Also you should ensure you are using the latest release of the Oracle-SQL-Developer for your operating system.
As your question gives no facts about your versions of Oracle or Db2 products or operating systems, this is the best advice that is possible.
I got the same problem, it turned out SQL Developer doesn't display tables for DB2, but still allows to perform SQL queries. If you know table names, you will be able to select data from those tables if you have enough permissions to do so.
You can test ability to perform SQL queries by selecting DB2 version (SQL below is valid for DB2 12.0)
SELECT GETVARIABLE('SYSIBM.VERSION') AS VERSION FROM SYSIBM.SYSDUMMY1;
Make sure you don't forget to specify schema while selecting data from your tables!
select * from schema.table_name;

Enable stored procedures after database downgrade

I've recently upgraded/downgraded a database as stated on this link:
https://www-304.ibm.com/support/docview.wss?uid=swg21351101
Specifically, it was from db2 9.7.5 (32bit) to 9.7.6 (64bit) to 9.7.0 (32bit)
(license issues, bear with me). Now, after successfully restoring my backup to 9.7.0, I can't run any stored procedures.
On resolving the problem, It says:
Contact your DBAdmins and let them verify if the required stored
procedures are enabled on the DB2 database. The required stored
procedures are: JAVA Database Connectivity (JDBC) Open Database
Connectivity (ODBC)
Then I'm at a loss. How do I enable a procedure?
After upgrading or downgrading your DB2 instance you need to also upgrade or downgrade all databases in that instance. You do that by running the UPGRADE DATABASE command, as explained in the manual, which will create catalog tables, views, and other system objects appropriate for the version and fix pack level.