Skip to Content

SAP HANA remote source configure for oracle

1) Download file ==> unixodbc

http://www.unixodbc.org/

unixODBC-2.3.4.tar.gz

2) oracle client

http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html

instantclient-odbc-linux.x64-12.1.0.2.0.zip

instantclient-basic-linux.x64-12.1.0.2.0.zip

3) Install in HANA system

-. enable ftp

vi /etc/vsftpd.conf

Now, the following lines will be commented, uncomment them.

local_enable=YES    – this lets the local users login via FTP

write_enable=YES   – this lets the users upload files

Save and quit the file.

/etc/init.d/vsftpd restart

=> upload files

ftp> put unixODBC-2.3.4.tar.gz

200 PORT command successful. Consider using password

150 Ok to send data.

226 File receive OK.

ftp: 0.90 2045.43KB

ftp> put instantclient-odbc-linux.x64-12.1.0.2.0.zip

200 PORT command successful. Consider using password

150 Ok to send data.

226 File receive OK.

ftp: 0.48  2657.74KB

ftp> put instantclient-basic-linux.x64-12.1.0.2.0.zip

200 PORT command successful. Consider using password

150 Ok to send data.

226 File receive OK.

ftp: 14.36  4412.95KB


4) install unixodbc

tar xvf unixODBC-2.3.4.tar.gz

./configure

make

make install

su – sidadm

cd /ODBC/unixodbc

-. isql test (recieved error below)

SID:/ODBC/unixODBC-2.3.4> isql –help

isql: error while loading shared libraries: libodbc.so.2: cannot open shared object file: No such file or directory

SIDADM:/ODBC/unixODBC-2.3.4> find / -name  libodbc.so.2

/ODBC/unixODBC-2.3.4/DriverManager/.libs/libodbc.so.2

– export LD_LIBRARY_PATH

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/ODBC/unixODBC-2.3.4/DriverManager/.libs/

SIDADM:/ODBC/unixODBC-2.3.4> isql –help

unixODBC 2.3.4

– ADD LD_LIBRARY_PATH to profile

SIDADM:/usr/sap/BWP/HDB00> vi ~/.bashrc

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/ODBC/unixODBC-2.3.4/DriverManager/.libs/

SIDADM:/usr/sap/BWP/HDB00> isql –help

unixODBC 2.3.4

5) unzip oracle instant client and odbc client

SIDADM:/ODBC # ls

instantclient-basic-linux.x64-12.1.0.2.0.zip  msodbcsql-11.0.2260.0         unixODBC-2.3.4

instantclient-odbc-linux.x64-12.1.0.2.0.zip   msodbcsql-11.0.2260.0.tar.gz  unixODBC-2.3.4.tar.gz

ORASID:/ODBC # unzip instantclient-basic-linux.x64-12.1.0.2.0.zip

Archive:  instantclient-basic-linux.x64-12.1.0.2.0.zip

  inflating: instantclient_12_1/adrci

  inflating: instantclient_12_1/BASIC_README

  inflating: instantclient_12_1/genezi

  inflating: instantclient_12_1/libclntshcore.so.12.1

  inflating: instantclient_12_1/libclntsh.so.12.1

  inflating: instantclient_12_1/libipc1.so

  inflating: instantclient_12_1/libmql1.so

  inflating: instantclient_12_1/libnnz12.so

  inflating: instantclient_12_1/libocci.so.12.1

  inflating: instantclient_12_1/libociei.so

  inflating: instantclient_12_1/libocijdbc12.so

  inflating: instantclient_12_1/libons.so

  inflating: instantclient_12_1/liboramysql12.so

  inflating: instantclient_12_1/ojdbc6.jar

  inflating: instantclient_12_1/ojdbc7.jar

  inflating: instantclient_12_1/uidrvci

  inflating: instantclient_12_1/xstreams.jar


ORASID:/ODBC # unzip instantclient-odbc-linux.x64-12.1.0.2.0.zip

Archive:  instantclient-odbc-linux.x64-12.1.0.2.0.zip

   creating: instantclient_12_1/help/

   creating: instantclient_12_1/help/us/

   creating: instantclient_12_1/help/us/META-INF/

extracting: instantclient_12_1/help/us/META-INF/MANIFEST.MF

  inflating: instantclient_12_1/help/us/sqora.htm

  inflating: instantclient_12_1/help/us/toc.htm

   creating: instantclient_12_1/help/us/img/

  inflating: instantclient_12_1/help/us/img/setup_work.gif

  inflating: instantclient_12_1/help/us/img/odbcmodel.gif

  inflating: instantclient_12_1/help/us/img/setup_app.gif

  inflating: instantclient_12_1/help/us/img/setup_ssmig.gif

  inflating: instantclient_12_1/help/us/img/setup_ora.gif

  inflating: instantclient_12_1/help/us/img/odbcdrvarch.gif

   creating: instantclient_12_1/help/us/img_text/

  inflating: instantclient_12_1/help/us/img_text/setup_work.htm

  inflating: instantclient_12_1/help/us/img_text/setup_ora.htm

  inflating: instantclient_12_1/help/us/img_text/setup_ssmig.htm

  inflating: instantclient_12_1/help/us/img_text/odbcmodel.htm

  inflating: instantclient_12_1/help/us/img_text/odbcdrvarch.htm

  inflating: instantclient_12_1/help/us/img_text/setup_app.htm

  inflating: instantclient_12_1/help/us/map.xml

  inflating: instantclient_12_1/help/us/blafdoc.css

  inflating: instantclient_12_1/help/us/cpyr.htm

  inflating: instantclient_12_1/help/us/oracle.gif

   creating: instantclient_12_1/help/ja/

  inflating: instantclient_12_1/help/ja/map.xml

  inflating: instantclient_12_1/help/ja/oracle.gif

  inflating: instantclient_12_1/help/ja/cpyr.htm

  inflating: instantclient_12_1/help/ja/toc.htm

  inflating: instantclient_12_1/help/ja/sqora.htm

   creating: instantclient_12_1/help/ja/img_text/

  inflating: instantclient_12_1/help/ja/img_text/setup_ora.htm

  inflating: instantclient_12_1/help/ja/img_text/setup_ssmig.htm

  inflating: instantclient_12_1/help/ja/img_text/setup_app.htm

  inflating: instantclient_12_1/help/ja/img_text/odbcdrvarch.htm

  inflating: instantclient_12_1/help/ja/img_text/odbcmodel.htm

  inflating: instantclient_12_1/help/ja/img_text/setup_work.htm

  inflating: instantclient_12_1/help/ja/blafdoc.css

   creating: instantclient_12_1/help/ja/img/

  inflating: instantclient_12_1/help/ja/img/setup_app.gif

  inflating: instantclient_12_1/help/ja/img/setup_work.gif

  inflating: instantclient_12_1/help/ja/img/odbcmodel.gif

  inflating: instantclient_12_1/help/ja/img/setup_ssmig.gif

  inflating: instantclient_12_1/help/ja/img/setup_ora.gif

  inflating: instantclient_12_1/help/ja/img/odbcdrvarch.gif

   creating: instantclient_12_1/help/ja/META-INF/

extracting: instantclient_12_1/help/ja/META-INF/MANIFEST.MF

  inflating: instantclient_12_1/libsqora.so.12.1

  inflating: instantclient_12_1/ODBC_IC_Readme_Unix.html

  inflating: instantclient_12_1/odbc_update_ini.sh

6. Loading enviroment

SIDADM:/etc/unixODBC> vi ~/.bashrc

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib64

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/lib64

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/ODBC/instantclient_12_1

export ODBCINI=/etc/unixODBC/odbc.ini

export ODBCSYSINI=/etc/unixODBC

7. ISQL Testing

SIDADM:/usr/sap/BWP/HDB00> isql -v ORACLE_SID system oracle

[01000][unixODBC][Driver Manager]Can’t open lib ‘/ODBC/instantclient_12_1/libsqora.so.12.1’ : file not found

[ISQL]ERROR: Could not SQLConnect

SIDADM:/ODBC/instantclient_12_1> ldd /ODBC/instantclient_12_1/libsqora.so.12.1

        linux-vdso.so.1 =>  (0x00007fff055ff000)

        libdl.so.2 => /lib64/libdl.so.2 (0x00007fcc5c533000)

        libm.so.6 => /lib64/libm.so.6 (0x00007fcc5c2ba000)

        libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fcc5c09d000)

        libnsl.so.1 => /lib64/libnsl.so.1 (0x00007fcc5be84000)

        librt.so.1 => /lib64/librt.so.1 (0x00007fcc5bc7b000)

        libclntsh.so.12.1 => /ODBC/instantclient_12_1/libclntsh.so.12.1 (0x00007fcc58cbe000)

        libodbcinst.so.2 => not found    <——–

SIDADM:/etc/unixODBC # find / -name libodbcinst.so.2

/usr/local/lib/libodbcinst.so.2

^C

SIDADM:/etc/unixODBC # ln -s /usr/local/lib/libodbcinst.so.2 /ODBC/instantclient_12_1

SIDADM:/etc/unixODBC # pwd

/etc/unixODBC

/etc/unixODBC] vi odbc.ini

[ORACLE_SID]

Driver=/ODBC/instantclient_12_1/libsqora.so.12.1

ServerName=//192.168.1.160:1521/ORACLE_SID

su – sidadm

8. Test Sucessful

SIDADM:/usr/sap/BWP/HDB00> isql -v ORACLE_SID system XXXXXX

+—————————————+

| Connected!                            |

|                                       |

| sql-statement                         |

| help [tablename]                      |

| quit                                  |

|                                       |

+—————————————+

SQL>

QL> select count(*) from tab;

+—————————————–+

| COUNT(*)                                |

+—————————————–+

| 163                                     |

+—————————————–+

SQLRowCount returns -1

1 rows fetched



Set up hana unixodbc for oracle completed sucessfully

To report this post you need to login first.

Be the first to leave a comment

You must be Logged on to comment or reply to a post.

Leave a Reply