SQLSTATE 42968
App/software: DB2 Client server v10.1 , JDK7+
Problem: SQL1598N An attempt to connect to the database server failed because of a licensing problem SQLSTATE=42968.
In my case, I can start up my db2 command line processor, i added my databases using the db2 catalog tcpip node <my-local-node> remote <database-ip-orhost-name> server <port> authentication SERVER, then catalogue the databases db2 catalog db <database-name> as <database-alias> at node <my-local-node>, but every time i try db2 connect to <database-alias> user <user-name> using <password>, this error shows up.
Diagnosing:
1. Either you dont have a product license, you can check this by running db2 command line processor then type db2licm -l .. there you will see if your license has expired.
2. Or if there is no indication of expiration and you obtained your product from your work ei company license already installed (i got mine from ISSI). The licensing problem this error is referring to is odbc driver license. Check CLASSPATH in your System Environment Variables if all odbc license are there.
How i resolved:
1. If you have the license somewhere (files ending with .lic) then add it to your registry by running, db2licm -a <filepath>\<sample.lic>, sample: db2licm -a C:\db2consv_ee.lic.
2. The ODBC drivers we need for this are: db2jcc.jar, db2jcc_license_cisuz.jar, db2jcc_license_cu.jar, sqlj.zip. If one/more license is missing in CLASSPATH, add it. These licenses are found in <DB2 instance filepath>\SQLLIB\java. Add the missing license(s) to your classpath and reinstall db2 client server v10.1 then reboot computer.
Additional info: You can catalogue your databases by using administrative tool Data Source (ODBC).
Control Panel -> Administrative Tools -> Data Source (ODBC) -> System DSN -> Add -> IBM DB2 ODBC Driver DB2COPY1
Data Source Name: i put the Database name, click Add in database alias, then fill out the fields.











