App Connect

App Connect

Join this online user group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Connect to db2 using ODBC

    Posted Fri April 14, 2023 01:45 PM

    Hi,
    We are in the process of migrating  our application to App Connect Enterprise as a Service.
    Could you please help us with odbc configuration in App Connect Enterprise?
    Do we need  install odbc driver in ACE ? If yes then how can we add the driver?

    Regards
    Adrita





    ------------------------------
    ADRITA BHAUMIK
    ------------------------------


  • 2.  RE: Connect to db2 using ODBC

    Posted Fri April 14, 2023 01:55 PM

    Hi @ADRITA BHAUMIK

    I have raised the question to our team internally - in the meantime; I have found the following blog in App Connect:  Connecting to Databases from App Connect Enterprise That I believe could be helpful until our team comes back with an answer. 

    there is also a doc in the KC:  Connecting to a database from Linux and UNIX systems by using the IBM Integration ODBC Database Extender

    I will get back to you as soon as the team has an answer. 



    ------------------------------
    Gabriel Marte Blanco
    Austin TX
    ------------------------------



  • 3.  RE: Connect to db2 using ODBC

    Posted Fri April 14, 2023 02:03 PM

    Adrita,

     

    What databases are you connecting to?

    ACE comes with many drivers.

    Are you installing on Linux or Windows or ???

    What version of ACE are you installing?

     

    You see in ACE 11.0.0.11 (for example) there is a directory (after the installation on Linux) called:

    /opt/IBM/mqsi/11.0.0.11/servr/ODBC/drivers/lib

    In this directory are many *.so files (drivers for connecting to various databases (oracle, sql, etc.).  You can review on the website which drivers are compatible with your database versions.

    -rw-r--r--. 1 root root  2198528 Dec 15  2020 UKtrc95.so

    -rw-r--r--. 1 root root  4226128 Dec 15  2020 UKsqls95.so

    -rw-r--r--. 1 root root    15824 Dec 15  2020 UKoradtc95.so

    -rw-r--r--. 1 root root  4424760 Dec 15  2020 UKora95.so

    -rw-r--r--. 1 root root    15744 Dec 15  2020 UKasedtc95.so

    -rw-r--r--. 1 root root  3620456 Dec 15  2020 UKase95.so

    -rw-r--r--. 1 root root  2363656 Dec 15  2020 libUKssl95.so

    -rw-r--r--. 1 root root 14666736 Dec 15  2020 libUKicu95.so

    drwxr-xr-x. 4 root root       47 Dec 15  2020 ..

    drwxr-xr-x. 2 root root      163 Dec 15  2020 .

     

    We configured an odbc.ini file in /var/mqsi/odbc.  An example of how to configure this file is in:

    Here you will see at the top of this file:

    ;#######################################

    ;#### List of data sources stanza ######

    ;#######################################

     

    [ODBC Data Sources]

    ;#DB2DB=IBM DB2 ODBC Driver

    ;#DB2DSDB=IBM Data Server Driver included in ACE

    ;#ORACLEDB=DataDirect ODBC Oracle Wire Protocol

    ;#ORACLERACDB=DataDirect ODBC Oracle RAC Wire Protocol

    ;#ORACLESSLDB=DataDirect ODBC Oracle SSL Wire Protocol

    ;#SYBASEDB=DataDirect ODBC Sybase Wire Protocol

    ;#SYBASEDBUTF8=DataDirect ODBC Sybase UTF8 Wire Protocol

    SQLSERVERDB=DataDirect ODBC SQL Server Wire Protocol

     

    For connecting to MongoDB you must install in node_modules ─ loopback-connector-mongodb@6.2.0.  And again, the version of the mongo connector depends on your MongoDB version.

     

    I hope this helps.  I can help more if you provide answers to the questions above.

     

    Susan Barker

    Senior MQ, ACE, ITX Domain Architect II

    Victory is nothing without humility, respect and charity...unknown

    Let no one ever come to you without leaving happier...Mother Theresa

     

     

    __

    Logo, company name  Description automatically generated

    IBM WAS Advisory Board

    IBM ACEvNext Beta Program

    IBM MQvNext Beta Program

     






  • 4.  RE: Connect to db2 using ODBC

    Posted Mon April 17, 2023 03:49 AM

    Hi Susan,
    Thank you so much for replying.  We are new to this technology and need to complete the migration at the earliest.
    We are using IBM App Connect Enterprise (12.0.7) Saas on AWS .
    Platform : Linux 4.18.0-305.76.1.el8_4.x86_64
    We have to connect to IBM Db2 database . Do we need to specify the path of odbc DB2 driver in odbc.ini?
    Also we are unable to launch the console to run commands.
    Thanks and Regards
    Adrita




    ------------------------------
    ADRITA BHAUMIK
    ------------------------------



  • 5.  RE: Connect to db2 using ODBC

    Posted Wed April 19, 2023 10:35 AM

    Hi @ADRITA BHAUMIK 
    You can follow this article to configure your odbc connectivity to DB2 database.  Although the article is talking about Kubernetes environment, same instructions would be applicable to ACEaaS on AWS

    https://community.ibm.com/community/user/integration/blogs/amar-shah1/2022/01/23/connecting-to-databases-from-app-connect-enterpris



    ------------------------------
    AMAR SHAH
    ------------------------------



  • 6.  RE: Connect to db2 using ODBC

    Posted Thu April 20, 2023 02:19 AM

    Hi Amar,
    Thank you so much for your advice. 
    We have been able to proceed with the first step of ODBC configuration for db2 following the instructions in the shared document.
    We have configured odbc.ini , db2cli.ini  and set user id/pwd using setDbParams.
    But now we are getting the below error.  2322E: Database error: SQL State '08001'; Native Error Code '-30081'; Error Text '[unixODBC][IBM][CLI Driver] SQL30081N A communication error has been detected. Communication protocol being used: "TCP/IP". Communication API being used: "SOCKETS". Location where the error was detected: "158.176.91.122". Communication function detecting the error: "recv". Protocol specific error code(s): "104", "*", "0". SQLSTATE=08001 '. 
    We are connecting to the ssl port for db2 .
     We have tried with adding
    1.security=ssl (odbc.ini)
    2. added the db2 self signed certificate in Integration server

    Could you please guide us to resolve the issue. Thanks Again !!
    -------------------------------------------------------------------------------------
    ODBC.ini
    ------------------------------
    [ODBC Data Sources]
    BLUDB=IBM Data Server Driver included in ACE
    [BLUDB]
    DRIVER=/opt/ibm/ace-12/server/ODBC/dsdriver/odbc_cli/clidriver/lib/libdb2o.so
    Description=IBM Db2 ODBC Database accessed using IBM Data Server Driver included in ACE
    Database=BLUDB
    [ODBC]
    InstallDir=/opt/ibm/ace-12/server/ODBC/drivers
    UseCursorLib=0
    IANAAppCodePage=4
    UNICODE=UTF-8
    --------------------------------------------------------------
    db2cli.ini
    -----------------------------------
    [BLUDB]
    HostName=922b61d4-8423-4340-8858-92851a27fd58.bs2io90l08kqb1od8lcg.databases.appdomain.cloud
    Port=31592
    Database=BLUDB
    ------------------------
    set credentials
    -----------------------------
    mqsisetdbparms  -n BLUDB -u ********-p **********

    Thanks and Regards
    Adrita



    ------------------------------
    ADRITA BHAUMIK
    ------------------------------