Oracle client libraries windows

Содержание
  1. Oracle client libraries windows
  2. Free, light-weight, and easily installed Oracle Database tools, libraries and SDKs
  3. Oracle Instant Client
  4. What’s New
  5. Oracle Linux has Instant Client RPMs
  6. Instant Client is available for Docker
  7. Instant Client Features
  8. Instant Client applications are cloud ready
  9. FAQ по Oracle Client
  10. Что такое Oracle Client?
  11. Откуда скачать Oracle Client?
  12. Установка клиента Oracle 12c 32-bit не проходит после установки Oracle 12c 64-bit клиента (или наоборот)
  13. Как настроить подключение к СУБД Oracle в приложении, использующем Oracle Client?
  14. Что такое SERVICE_NAME и SID?
  15. Как адресовать таблицы в Oracle?
  16. Что такое схема и база данных в Oracle?
  17. Почему не удается определить OCI environment (например, в Attunity)?
  18. Как настроить символьную кодировку Oracle Client?
  19. Oracle Client
  20. Описание
  21. Версии
  22. Инсталляция
  23. Oracle client libraries windows
  24. Oracle Instant Client Downloads for Microsoft Windows (x64) 64-bit
  25. Version 19.10.0.0.0
  26. Download
  27. Description
  28. Download
  29. Description
  30. Download
  31. Description
  32. Version 18.5.0.0.0
  33. Download
  34. Description
  35. Instant Client Installation for Microsoft Windows 64-bit
  36. ODPI-C Installation¶
  37. Overview¶
  38. Oracle Client Library Loading¶
  39. Oracle Client and Oracle Database Interoperability¶
  40. Linux¶
  41. Oracle Instant Client Zip Files¶
  42. Oracle Instant Client RPM Files¶
  43. Local Database or Full Oracle Client¶
  44. Docker Files¶
  45. Windows¶
  46. Oracle Instant Client Zip Files¶
  47. Configure Oracle Instant Client¶
  48. Local Database or Full Oracle Client¶
  49. macOS¶
  50. Oracle Instant Client DMG Files¶
  51. Manual Installation¶
  52. Scripted Installation¶
  53. Oracle Instant Client Zip Files¶
  54. Configure Oracle Instant Client¶
  55. Other Platforms¶

Oracle client libraries windows

Your search did not match any results.

We suggest you try the following to help find what you’re looking for:

  • Check the spelling of your keyword search.
  • Use synonyms for the keyword you typed, for example, try “application” instead of “software.”
  • Try one of the popular searches shown below.
  • Start a new search.

Free, light-weight, and easily installed Oracle Database tools, libraries and SDKs

Oracle Instant Client enables development and deployment of applications that connect to Oracle Database, either on-premise or in the Cloud. The Instant Client libraries provide the necessary network connectivity and advanced data features to make full use of Oracle Database. The libraries are used by the Oracle APIs of popular languages and environments including Python, Node.js, Go, PHP and Ruby, as well as providing access for Oracle Call Interface (OCI), Oracle C++ Call Interface (OCCI), JDBC-OCI, ODBC and Pro*C applications. Tools included in Instant Client, such as SQL*Plus, SQL*Loader and Oracle Data Pump, provide quick and convenient data access.

Oracle Instant Client

What’s New

Oracle Linux has Instant Client RPMs

Instant Client RPM packages for Oracle Linux can now be installed from yum.oracle.com for Oracle Linux 8 and Oracle Linux 7. Older releases are available for Oracle Linux 8, Oracle Linux 7 and Oracle Linux 6.

Instant Client is available for Docker

Dockerfiles are available on GitHub.

Instant Client Features

  • Free to download, deploy and distribute
  • Small footprint
  • ZIPs available for quick, one-step install
  • RPM Packages also available for Linux, and DMG Packages for macOS
  • Same libraries as full Oracle Database or Oracle Client
  • Includes tools such as SQL*Plus, SQL*Loader and Data Pump
  • Widely used and tested

Instant Client applications are cloud ready

Deploy applications using Instant Client in the cloud, or connect to a cloud database.

Whether your applications are in the cloud or on-premise, you can install Instant Client and connect to cloud databases. Follow the normal installation process for your operating system. Some cloud-specific references are shown below.

FAQ по Oracle Client

За время работы с Oracle Database и Microsoft SQL Server Integration Services я собрал 2 FAQ-а. Первый — по Oracle Client — я публикую здесь, а второй — по коннекторам SSIS к Oracle, следующим постом.

Что такое Oracle Client?

Это промежуточное ПО, предназначенное для доступа к Oracle Database. Некоторые приложения имеют встроенного клиента. Встраиваемый клиент, предназначенный для разработчиков, называется Instant Client.

Откуда скачать Oracle Client?

С сайта www.oracle.com из раздела Downloads -> Databases -> Oracle Database, где выбрать вашу версию СУБД или выше.

Если Вы возьмете клиента от более старшей версии это будет плюсом, поскольку не придется его обновлять на работающей системе, когда потребуется соединяться со следующей СУБД Oracle.

Не перепутайте Oracle Client и Oracle Instant Client, предназначенный для разработчиков. Так же, не качайте Data Access Components, поскольку DAC, помимо Oracle Client, содержит много средств, нужных только для разработки приложений.

Установка клиента Oracle 12c 32-bit не проходит после установки Oracle 12c 64-bit клиента (или наоборот)

Если Вы только что установили одного из клиентов Oracle 12c и не перезагружались, перезагрузитесь.

Программа установки Oracle Client, называемая Oracle Universal Installer, создает службу OracleRemExecService, которая согласно неофициальному описанию нужна только для OUI и должна исчезнуть после перезагрузки. В реальности она не исчезает, но и не запускается при старте ПК. Является ли правильным остановить службу, я не знаю, но это тоже помогает.

Как настроить подключение к СУБД Oracle в приложении, использующем Oracle Client?

Со стороны прикладного программного обеспечения, работающего через Oracle Client, для указания БД может быть использовано имя сервиса TNS или строка конфигурации, содержащая часть объявления имени сервиса TNS.

В первом случае в папке Oracle Client в «\network\admin\tnsnames.ora» укажите:

При этом, в приложениях в поле TNS Service Name указывается имя подключения.

Следует иметь ввиду, что в приложении, запускаемом в 32-х битной среде, используется Oracle Client 32-bit, а в 64-х битной среде используется Oracle Client 64-bit, поэтому может потребоваться сделать «tnsnames.ora» в обоих клиентах.

Что такое SERVICE_NAME и SID?

Подключение к базе данных по сети со стороны сервера обслуживает промежуточное ПО, называемое Listener.

SID это уникальный идентификатор базы данных Oracle на машине, а SERVICE_NAME, это идентификатор базы данных, заданный в Listener. Таким образом, одна и та же база данных, может быть доступна под разными SERVICE_NAME, но только под одним SID. Вас, поскольку Вы находитесь снаружи Listener-а, волнует SERVICE_NAME.

Как адресовать таблицы в Oracle?

По-умолчанию пользователь Oracle обращается к таблицам в своей схеме. Для того, что бы запрос обращался к одним и тем же таблицам из под любого пользователя, нужно указывать имя схемы перед точкой. Например, BM9.BM_CUSTOMER_CONTACT адресует таблицу BM_CUSTOMER_CONTACT в схеме BM9.

Что такое схема и база данных в Oracle?

База данных в СУБД Oracle = отдельный набор процессов СУБД с общей памятью.

Схема содержится внутри базы данных и является контейнером для таблиц. Кроме того, схема = пользователь.

Таблицы с одинаковыми именами могут существовать одновременно в разных схемах.

Почему не удается определить OCI environment (например, в Attunity)?

Приложение использующее Oracle Client должно каким-то образом его найти. Путь установки Oracle Client добавляется в %PATH% Oracle Installer-ом при установке. Но следует иметь ввиду, что переменные окружения устанавливаются процессу при запуске и, к примеру, Visual Studio (BIDS, Data Tools) запущенная до установки клиента, требует перезапуска, что бы начать использовать новый %PATH%.

Эта ошибка может быть по разному сформулирована в других приложениях.

Как настроить символьную кодировку Oracle Client?

Неверно настроенная кодировка может влиять как на получаемые данные, так и на выполнение запросов. Это может проявляться в том, что REPLACE(table_column, ‘А’, ‘Б’) в одном инструменте работает, а в другом нет, потому, что литералы ‘А’ и ‘Б’, поступающие в БД, воспринимаются иначе в одном из инструментов.

Для 32-х разрядного клиента в реестре в [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ORACLE] установите параметр «NLS_LANG»=»RUSSIAN_CIS.CL8MSWIN1251» (типа REG_SZ).

Читайте также:  Как установить windows longhorn

Для 64-х разрядного клиента в реестре в [HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE], аналогично, установите параметр «NLS_LANG»=»RUSSIAN_CIS.CL8MSWIN1251» (типа REG_SZ).

После настройки кодировки необходимо перезагрузиться, поскольку, уже запущенный Oracle Client её не перечитает.

Oracle Client

Описание

Oracle Client – это официальный клиент (программа), благодаря которому вы можете работать в базе данных Oracle. Вы получаете доступ базе данных, которая находится на стороннем компьютере, подсоединившись через удаленный сервер.

Воспользуйтесь этим клиентом и войдите в профиль, а также просканируйте права доступа и составления запросов. В этом клиенте вы можете работать в собственной БД. Этот софт можно установить на компьютер с OS Windows.

Войдя в эту программу, вы сможете просматривать БД, используя «проводниковую структуру файлов», но с практичным интерфейсом и оболочкой.

Версии

Сейчас в сети можно скачать этот клиент с «билдом» 12.0, но версия 11g считается намного лучше. Клиент Oracle Client 11g устанавливают на многих предприятиях и организациях. Софт можно устанавливать на компьютеры, в которых операционная система поддерживает 32 и 64 битную структуру файлов.

Главная особенность 32 разрядной версии программы – это поддержка Toad, SQL Developer и прочих инструментов визуализации. Версия x64 не подходит для подключения сторонних модулей.

Инсталляция

Устанавливая этот софт, вы выбираете тип установки: Instant Client, Administrator, Runtime и Custom. Инсталлировав клиент в первом режиме, вы сможете работать с разделенными библиотеками.

Указав Administrator, вы установите консоль администратора, которая интегрируется в дополнительные библиотеки клиента. В режиме Runtime вы инсталлируете пакет файлов вспомогательных утилит для простой обработки готовой базы данных.

В режиме «Custom» вы сами подбираете составные части, а потом установить их. Выбрав режим инсталляции, нажмите установить и подождите, пока установщик скопирует все файлы.

Полноценная работа софта доступна без инсталляции вспомогательных модулей и драйверов. Oracle Client также поддерживает работу через меню автозагрузки операционной системы. Этот клиент доступен для закачки в бесплатном режиме.

Oracle client libraries windows

Your search did not match any results.

We suggest you try the following to help find what you’re looking for:

  • Check the spelling of your keyword search.
  • Use synonyms for the keyword you typed, for example, try “application” instead of “software.”
  • Try one of the popular searches shown below.
  • Start a new search.

Oracle Instant Client Downloads for Microsoft Windows (x64) 64-bit

See the Instant Client Home Page for more information about Instant Client.

The installation instructions are at the foot of the page.

Oracle Client-to-Oracle Database version interoperability is detailed in Doc ID 207303.1. For example, applications using Oracle Call Interface 19 can connect to Oracle Database 11.2 or later. Some tools may have other restrictions.

Version 19.10.0.0.0

Base — one of these packages is required

Download

Description

All files required to run OCI, OCCI, and JDBC:OCI applications

(82,565,845 bytes) (cksum — 2615031909)

Smaller version of the Basic package, with only English error messages and Unicode, ASCII, and Western European character set support

(42,294,233 bytes) (cksum — 3532277538)

Tools — optional packages

Download

Description

The SQL*Plus command line tool for SQL and PL/SQL queries

(973,448 bytes) (cksum — 2154713824)

Includes Data Pump, SQL*Loader and Workload Replay Client

(1,206,710 bytes) (cksum — 4031943553)

Development and Runtime — optional packages

Download

Description

Additional header files and an example makefile for developing Oracle applications with Instant Client

(1,859,518 bytes) (cksum — 3684376259)

Additional support for Internationalization under JDBC

(1,586,269 bytes) (cksum — 445389429)

Additional libraries for enabling ODBC applications

(862,815 bytes) (cksum — 263003309)

Precompiler Package Precompiler Downloads Additional files for Pro*C and Pro*COBOL

Version 18.5.0.0.0

Base — one of these packages is required

Download

Description

All files required to run OCI, OCCI, and JDBC:OCI applications

(77,769,261 bytes) (cksum — 1317689833)

Instant Client Installation for Microsoft Windows 64-bit

See the Instant Client Home Page for more information about Instant Client packages.

Client-server version interoperability is detailed in Doc ID 207303.1. For example, Oracle Call Interface 19, 18 and 12.2 can connect to Oracle Database 11.2 or later. Some tools may have other restrictions.

  1. Download the appropriate Instant Client packages for your platform. All installations require the Basic or Basic Light package.
  2. Unzip the packages into a single directory such as C:\oracle\instantclient_19_3
  3. Add this directory to the PATH environment variable. If you have multiple versions of Oracle libraries installed, make sure the new directory occurs first in the path. Restart any terminal windows or otherwise make sure the new PATH is used by your applications.
  4. Download and install the correct Visual Studio Redistributable from Microsoft. Instant Client 19 requires the Visual Studio 2017 redistributable. Instant Client 18 and 12.2 require the Visual Studio 2013 redistributable. Instant Client 12.1 requires the Visual Studio 2010 redistributable.
  5. If you intend to co-locate optional Oracle configuration files such as tnsnames.ora, sqlnet.ora, ldap.ora, or oraaccess.xml with Instant Client, then create a subdirectory such as C:\oracle\instantclient_19_3\network\admin

This is the default Oracle client configuration directory for applications linked with this Instant Client.

Alternatively, Oracle client configuration files can be put in another, accessible directory. Then set the environment variable TNS_ADMIN to that directory name.

ODPI-C Installation¶

Overview¶

To use ODPI-C in your own project, download its source from GitHub. A sample Makefile is provided if you wish to build ODPI-C as a shared library. Otherwise, add the ODPI-C source code to your project. On Windows, Visual Studio 2008 or higher is required. On macOS, Xcode 6 or higher is required. On Linux, GCC 4.4 or higher is required.

ODPI-C has been tested on Linux, Windows and macOS. Other platforms should also work but have not been tested.

Projects using ODPI-C require Oracle Client libraries to be installed. The libraries provide the necessary network connectivity allowing applications to access an Oracle Database instance. They also provide basic and advanced connection management and data features to ODPI-C applications.

Oracle Client Library Loading¶

The simplest Oracle Client is the free Oracle Instant Client. Only the “Basic” or “Basic Light” package is required. Oracle Client libraries are also available in any Oracle Database installation or full Oracle Client installation.

ODPI-C dynamically loads available Oracle Client libraries at runtime. This allows code using ODPI-C to be built only once, and then run using any available Oracle Client 19, 18, 12, or 11.2 libraries. If Oracle Client libraries are not found, the error “DPI-1047: Cannot locate an Oracle Client library” is raised. If an Oracle Client library is found but the version cannot be determined, the error “DPI-1072: the Oracle Client library version is unsupported” is raised. For example, this could be because the Oracle Client library version is too old (prior to 10g) or entirely unsupported (such as Oracle Client 19 on Windows 7).

If the member dpiContextCreateParams.oracleClientLibDir is specified when calling dpiContext_createWithParams() , then only that directory is searched for the Oracle Client libraries.

If no directory is specified, then the Oracle Client libraries are looked for in the same directory that the ODPI-C library (or application binary) is located in. If they are not found, then they are searched for in the standard operating system search path, for example PATH on Windows or LD_LIBRARY_PATH on Linux. See standard Windows library search order or standard Linux library search order. Finally, on platforms other than Windows, $ORACLE_HOME/lib is also searched.

When using Instant Client on Linux and related operating systems, then that directory must always be in the system library search path.

When using the library directory from a full client or database installation, then you additionally need to set the application environment to use this software, for example by setting the ORACLE_HOME environment variable. This should be done prior to ODPI-C initialization.

Make sure the application has directory and file access permissions for the Oracle Client libraries. On Linux ensure libclntsh.so exists. On macOS ensure libclntsh.dylib exists. ODPI-C will not directly load libclntsh.*.XX.1 files in dpiContextCreateParams.oracleClientLibDir or from the directory where the ODPI-C library (or application binary) is. Note other files used by libclntsh* are also required.

To trace the loading of Oracle Client libraries, the environment variable DPI_DEBUG_LEVEL can be set to 64 before starting your application. See ODPI-C Debugging .

The following sections explain how to ensure the Oracle Client is installed and configured correctly on the various platforms so that ODPI-C is able to find it.

Oracle Client and Oracle Database Interoperability¶

Oracle’s standard client-server network interoperability allows connections between different versions of Oracle Client and Oracle Database. For certified configurations see Oracle Support’s Doc ID 207303.1. In summary, Oracle Client 19, 18 and 12.2 can connect to Oracle Database 11.2 or greater. Oracle Client 12.1 can connect to Oracle Database 10.2 or greater. Oracle Client 11.2 can connect to Oracle Database 9.2 or greater. The technical restrictions on creating connections may be more flexible. For example Oracle Client 12.2 can successfully connect to Oracle Database 10.2.

Since a single ODPI-C binary can use multiple client versions and access multiple database versions, it is important your application is tested in your intended release environments. Newer Oracle clients support new features, such as the oraaccess.xml external configuration file available with 12.1 or later clients, session pool improvements, call timeouts with 18 or later clients, and other enhancements.

The function dpiContext_getClientVersion() can be used to determine which Oracle Client version is in use and the function dpiConn_getServerVersion() can be used to determine which Oracle Database version a connection is accessing. These can then be used to adjust application behavior accordingly. Attempts to use some Oracle features that are not supported by a particular client/server combination may result in runtime errors. These include:

when attempting to access attributes that are not supported by the current Oracle Client library you will get the error “ORA-24315: illegal attribute type”

when attempting to use implicit results with Oracle Client 11.2 against Oracle Database 12c you will get the error “ORA-29481: Implicit results cannot be returned to client”

when attempting to get array DML row counts with Oracle Client 11.2 you will get the error “DPI-1050: Oracle Client library must be at version 12.1 or higher”

Linux¶

ODPI-C requires Oracle Client libraries, which are found in Oracle Instant Client, or an Oracle Database installation, or in a full Oracle Client installation, see Oracle Client Library Loading . The libraries must be either 32-bit or 64-bit, matching your application and ODPI-C library (if one is created separately).

Oracle Instant Client Zip Files¶

To run ODPI-C applications with Oracle Instant Client zip files:

Download an Oracle 19, 18, 12, or 11.2 “Basic” or “Basic Light” zip file: 64-bit or 32-bit, matching your application 64-bit or 32-bit architecture.

Unzip the package into a directory that is accessible to your application. For example:

Install the operating system libaio package with sudo or as the root user. For example:

On some Linux distributions this package is called libaio1 instead.

On recent Linux versions, such as Oracle Linux 8, you may also need to install the libnsl package.

If there is no other Oracle software on the machine that will be impacted, permanently add Instant Client to the runtime link path. For example, with sudo or as the root user:

Alternatively, set the environment variable LD_LIBRARY_PATH to the appropriate directory for the Instant Client version. For example:

If you use optional Oracle configuration files such as tnsnames.ora , sqlnet.ora or oraaccess.xml , put the files in an accessible directory. Then set the member dpiContextCreateParams.oracleClientConfigDir when calling dpiContext_createWithParams() .

Alternatively, set the environment variable TNS_ADMIN to that directory name.

Alternatively, create a network/admin subdirectory of Instant Client, if it does not exist. For example, with Instant Client 12.2:

Put the files in this directory. This is the default Oracle configuration directory for applications linked with this Instant Client.

Oracle Instant Client RPM Files¶

To run ODPI-C applications with Oracle Instant Client RPMs:

Download an Oracle 19, 18, 12, or 11.2 “Basic” or “Basic Light” RPM: 64-bit or 32-bit, matching your application architecture.

Install the downloaded RPM with sudo or as the root user. For example:

On recent Linux versions, such as Oracle Linux 8, you may also need to manually install the libnsl package. Yum will automatically install other required dependencies, such as libaio .

Oracle Linux users can alternatively automate download and installation. For example:

For Instant Client 19 RPMs, the system library search path is automatically configured during installation.

For older versions, if there is no other Oracle software on the machine that will be impacted, permanently add Instant Client to the runtime link path. For example, with sudo or as the root user:

Alternatively, for version 18 and earlier, every shell will need to have the environment variable LD_LIBRARY_PATH set to the appropriate directory for the Instant Client version. For example:

If you use optional Oracle configuration files such as tnsnames.ora , sqlnet.ora or oraaccess.xml , put the files in an accessible directory. Then set the member dpiContextCreateParams.oracleClientConfigDir when calling dpiContext_createWithParams() .

Alternatively, set the environment variable TNS_ADMIN to that directory name.

Alternatively, create a network/admin subdirectory of Instant Client, if it does not exist. For example, with Instant Client 12.2:

Put the files in this directory. This is the default Oracle configuration directory for applications linked with this Instant Client.

Local Database or Full Oracle Client¶

ODPI-C applications can use Oracle Client 19, 18, 12, or 11.2 libraries from a local Oracle Database or full Oracle Client installation.

The libraries must be either 32-bit or 64-bit, matching your application and ODPI-C library (if one is created separately).

Set required Oracle environment variables by running the Oracle environment script. For example:

For Oracle Database XE 11.2, run:

Optional Oracle configuration files such as tnsnames.ora , sqlnet.ora or oraaccess.xml can be placed in $ORACLE_HOME/network/admin .

Alternatively, Oracle configuration files can be put in another, accessible directory. Then set the member dpiContextCreateParams.oracleClientConfigDir when calling dpiContext_createWithParams() , or set the environment variable TNS_ADMIN to that directory name.

Docker Files¶

ODPI-C applications can easily be used in Docker by basing your deployments on the Instant Client Dockerfiles on GitHub.

To build an Instant Client image, create a Dockerfile, for example:

The new image can be used as the basis for your application.

Windows¶

ODPI-C requires Oracle Client libraries, which are found in Oracle Instant Client, or an Oracle Database installation, or in a full Oracle Client installation, see Oracle Client Library Loading . The libraries must be either 32-bit or 64-bit, matching your application and ODPI-C library (if one is created separately).

Oracle Client libraries require the presence of the correct Visual Studio redistributable.

Oracle 19 needs VS 2017

Oracle 18 and 12.2 need VS 2013

Oracle 12.1 needs VS 2010

Oracle Instant Client Zip Files¶

To run ODPI-C applications with Oracle Instant Client zip files:

Download an Oracle 19, 18, 12, or 11.2 “Basic” or “Basic Light” zip file: 64-bit or 32-bit, matching your application architecture.

Note that 19c is not supported on Windows 7.

Unzip the package into a directory that is accessible to your application. For example unzip instantclient-basic-windows.x64-19.8.0.0.0dbru.zip to C:\oracle\instantclient_19_8 .

Configure Oracle Instant Client¶

There are several alternative ways to tell your application where your Oracle Instant Client libraries are.

Alternatively, move the unzipped Instant Client files to the directory containing ODPIC.DLL (or into the directory of the application’s binary, if ODPI-C is compiled into the application).

Alternatively, add the Instant Client directory to the PATH environment variable. For example, on Windows 7, update PATH in Control Panel -> System -> Advanced System Settings -> Advanced -> Environment Variables -> System Variables -> PATH. The Instant Client directory must occur in PATH before any other Oracle directories.

Restart any open command prompt windows.

To avoid interfering with existing tools that require other Oracle Client versions, instead of updating the system-wide PATH variable, you may prefer to write a batch file that sets PATH , for example:

Invoke this batch file every time you want to run your application.

Or simply use SET to change your PATH in each command prompt window before you run your application.

If you use optional Oracle configuration files such as tnsnames.ora , sqlnet.ora or oraaccess.xml , put the files in an accessible directory. Then set the member dpiContextCreateParams.oracleClientConfigDir when calling dpiContext_createWithParams() .

Alternatively, set the environment variable TNS_ADMIN to that directory name.

Alternatively, create a network\admin subdirectory of Instant Client, if it does not exist. For example C:\oracle\instantclient_19_8\network\admin .

Put the files in this directory. This is the default Oracle configuration directory for applications linked with this Instant Client.

If you wish to package Instant Client with your application, you can move the Instant Client libraries to the same directory as the ODPI-C library (or application). Refer to the Instant Client documentation for the minimal set of Instant Client files required. There is no need to set dpiContextCreateParams.oracleClientConfigDir or to set PATH .

Local Database or Full Oracle Client¶

ODPI-C applications can use Oracle Client 19, 18, 12, or 11.2 libraries from a local Oracle Database or full Oracle Client installation.

The Oracle libraries must be either 32-bit or 64-bit, matching your application and ODPI-C library (if one is created separately).

To run ODPI-C applications using client libraries from a local Oracle Database (or full Oracle Client) 19, 18, 12, or 11.2 installation:

Set the environment variable PATH to include the path that contains OCI.dll, if it is not already set. For example, on Windows 7, update PATH in Control Panel -> System -> Advanced System Settings -> Advanced -> Environment Variables -> System Variables -> PATH.

Restart any open command prompt windows.

Optional Oracle configuration files such as tnsnames.ora , sqlnet.ora or oraaccess.xml can be placed in the network/admin subdirectory of the Oracle software.

Alternatively, Oracle configuration files can be put in another, accessible directory. Then set the member dpiContextCreateParams.oracleClientConfigDir when calling dpiContext_createWithParams() , or set the environment variable TNS_ADMIN to that directory name.

macOS¶

ODPI-C requires Oracle Client libraries, which are found in Oracle Instant Client for macOS.

The Instant Client DMG packages are notarized and are recommended for all newer macOS versions. In some future Oracle release, only DMG packages will be available.

Oracle Instant Client DMG Files¶

Manual or scripted installation of Oracle Instant Client DMG files can be performed.

Manual Installation¶

Download the Basic or Basic Light 64-bit DMG from Oracle.

In Finder, double click on the DMG to mount it.

Open a terminal window and run the install script in the mounted package, for example:

This copies the contents to $HOME/Downloads/instantclient_19_8 .

In Finder, eject the mounted Instant Client package.

If you have multiple Instant Client DMG packages mounted, you only need to run install_ic.sh once. It will copy all mounted Instant Client DMG packages at the same time.

Scripted Installation¶

Instant Client installation can alternatively be scripted, for example:

The Instant Client directory will be $HOME/Downloads/instantclient_19_8 .

Oracle Instant Client Zip Files¶

To install Oracle Instant Client zip files:

Download the 19, 18, 12, or 11.2 “Basic” or “Basic Light” zip file from Oracle. Choose either a 64-bit or 32-bit package, matching your application architecture. Most applications use 64-bit.

Unzip the package into a single directory that is accessible to your application. For example, in Terminal you could unzip:

Configure Oracle Instant Client¶

There are several alternative ways to tell your application where your Oracle Instant Client libraries are.

Alternatively, copy Oracle Instant Client to the directory containing the ODPI-C module binary. For example, if libodpic.dylib (or your binary containing the ODPI-C code) is in

/myprograms you can then run ln -s

/myprograms . You can also copy the Instant Client libraries to that directory.

Alternatively, set DYLD_LIBRARY_PATH to the Instant Client directory. Note this variable does not propagate to sub-shells.

Alternatively, you might decide to compile the ODPI-C library with an RPATH option like -Wl,-rpath,/usr/local/lib . Then you can link Oracle Instant Client to this directory, for example:

Or, instead of a link you can copy the required OCI libraries. For example:

Alternatively, on older versions of macOS, you could add a link to $HOME/lib or /usr/local/lib to enable applications to find Instant Client. If the lib sub-directory does not exist, you can create it. For example:

Instead of linking, you can copy the required OCI libraries. For example:

For Instant Client 11.2, the OCI libraries must be copied. For example:

If you use optional Oracle configuration files such as tnsnames.ora , sqlnet.ora or oraaccess.xml , put the files in an accessible directory. Then set the member dpiContextCreateParams.oracleClientConfigDir when calling dpiContext_createWithParams() .

Alternatively, set the environment variable TNS_ADMIN to that directory name.

Alternatively, create a network/admin subdirectory of Instant Client, if it does not exist. For example:

Put the files in this directory. This is the default Oracle configuration directory for applications linked with this Instant Client.

Other Platforms¶

To run ODPI-C applications on other platforms (such as Solaris and AIX), follow the same general directions as for Linux Instant Client zip files or Local Database. Add the Oracle libraries to the appropriate library path variable, such as LD_LIBRARY_PATH on Solaris, or LIBPATH on AIX.

Читайте также:  Mtk preloader 65xx windows 10
Оцените статью