Oracle Database Client Installation Guide, 11g Release 2 (11.2) for Apple Mac OS X (Intel)

11g Release 2 (11.2)

E38228-01

Contents

Title and Copyright Information

Preface

- Audience

- Documentation Accessibility

- Command Syntax

- Accessing Documentation

- Related Documentation

- Typographic Conventions

1 Overview of Oracle Database Client Installation

- 1.1 Planning Your Installation

- 1.2 Installation Considerations

- 1.3 Oracle Database Client Installation Types

- 1.4 Oracle Database Client and Oracle Database Interoperability

- 1.5 Simplified Patching of Timestamp with Time Zone Data Type

2 Oracle Database Client Preinstallation Tasks

- 2.1 Logging In to the System as root

- 2.2 Checking the Hardware Requirements

- 2.2.1 Memory Requirements

- 2.2.2 System Architecture

- 2.2.3 Disk Space Requirements

- 2.2.4 Display Requirements

- 2.2.5 Recommended Hardware Requirement for SQL Developers

- 2.3 Checking the Software Requirements

- 2.3.1 Instant Client Light Requirements

3 Installing and Removing Oracle Database Client

- 3.1 Downloading and Installing the Oracle Database Client Software

- 3.2 Removing the Oracle Database Client Software

4 Oracle Database Client Postinstallation Tasks

- 4.1 Required Postinstallation Tasks

- 4.1.1 Updating Instant Client

- 4.1.2 Connecting with Instant Client

- 4.2 Recommended Postinstallation Tasks

- 4.2.1 Connecting Instant Client or Instant Client Light to an Oracle Database

- 4.2.1.1 Specifying a Connection by Using the Easy Connect Naming Method

- 4.2.1.2 Specifying a Connection Using an Empty Connect String and TWO_TASK

- 4.2.2 Setting the NLS_LANG Environment Variable

- 4.3 Required Product-Specific Postinstallation Tasks

- 4.3.1 Configuring Oracle Precompilers

- 4.3.1.1 Configuring Pro*C/C++

Index

Oracle® Database

Client Installation Guide

11g Release 2 (11.2) for Apple Mac OS X (Intel)

E38228-01

January 2013

Oracle Database Client Installation Guide, 11g Release 2 (11.2) for Apple Mac OS X (Intel)

E38228-01

Copyright © 2011, 2013, Oracle and/or its affiliates. All rights reserved.

Primary Author: Tanvee Ravi

Contributing Authors: Bharathi Jayathirtha, Janelle Simmons

Contributors:  David Austin, Namrata Bhakthavatsalam, Rohitash Panda, Subhranshu Banerjee, Janelle Simmons, Mark Bauer, Robert Chang, Jonathan Creighton, Sudip Datta, Thirumaleshwara Hasandka, Joel Kallman, George Kotsovolos, Simon Law, Shekhar Vaggu, Richard Long, Rolly Lv, Padmanabhan Manavazhi, Sreejith Minnanghat, Krishna Mohan, Rajendra Pingte, Hanlin Qian, Roy Swonger, Ranjith Kundapur, Aneesh Khandelwal , Barb Lundhild, Barbara Glover, Binoy Sukumaran, Prasad Bagal, Martin Widjaja, Ajesh Viswambharan, Eric Belden, Sivakumar Yarlagadda, Rudregowda Mallegowda , Matthew McKerley, Trivikrama Samudrala, Akshay Shah, Sue Lee, Sangeeth Kumar, James Spiller, Saar Maoz, Rich Long, Mark Fuller, Sunil Ravindrachar, Sergiusz Wolicki, Eugene Karichkin, Joseph Francis, Srinivas Poovala, David Schreiner, Neha Avasthy, Dipak Saggi, Sudheendra Sampath, Mohammed Shahnawaz Quadri, Shachi Sanklecha, Zakia Zerhouni, Jai Krishnani, Darcy Christensen., Kevin Flood, Clara Jaeckel, Emily Murphy, Terri Winters

This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited.

The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing.

If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, the following notice is applicable:

U.S. GOVERNMENT END USERS: Oracle programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, delivered to U.S. Government end users are "commercial computer software" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, use, duplication, disclosure, modification, and adaptation of the programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, shall be subject to license terms and license restrictions applicable to the programs. No other rights are granted to the U.S. Government.

This software or hardware is developed for general use in a variety of information management applications. It is not developed or intended for use in any inherently dangerous applications, including applications that may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this software or hardware in dangerous applications.

Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.

Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Opteron, the AMD logo, and the AMD Opteron logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered trademark of The Open Group.

This software or hardware and documentation may provide access to or information on content, products, and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim all warranties of any kind with respect to third-party content, products, and services. Oracle Corporation and its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of third-party content, products, or services.

Preface

This guide provides instructions about installing and configuring Oracle Database Client 11g Release 2 (11.2.0.3) for Apple Mac OS X (Intel)(32-Bit) and Apple Mac OS X (Intel)(64-Bit).

The preface contains the following topics:

- Audience

- Documentation Accessibility

- Command Syntax

- Accessing Documentation

- Related Documentation

- Typographic Conventions

Audience

This guide is intended for anyone responsible for installing Oracle Database Client 11g Release 2 (11.2). Additional platform-specific installation guides for Oracle Database, Oracle Real Application Clusters, Oracle Clusterware, Oracle Database Examples, and Oracle Enterprise Manager Grid Control are available on the relevant installation media.

See Also:

- Oracle Database Installation Guide to install Oracle Database using the default settings

- The Oracle Technology Network (OTN) website for information about supported Application Programming Interfaces (API) at

http://www.oracle.com/technetwork/index.html

Documentation Accessibility

For information about Oracle's commitment to accessibility, visit the Oracle Accessibility Program website at http://www.oracle.com/pls/topic/lookup?ctx=acc&id=docacc.

Access to Oracle Support

Oracle customers have access to electronic support through My Oracle Support. For information, visit http://www.oracle.com/pls/topic/lookup?ctx=acc&id=info or visit http://www.oracle.com/pls/topic/lookup?ctx=acc&id=trs if you are hearing impaired.

Command Syntax

UNIX command syntax appears in monospace font. The dollar character ($), number sign (#), or percent character (%) are UNIX command prompts. Do not enter them as part of the command. The following command syntax conventions are used in this guide:

Convention

Description

backslash \

A backslash is the UNIX command continuation character. It is used in command examples that are too long to fit on a single line. Enter the command as displayed (with a backslash) or enter it on a single line without a backslash:

dd if=/dev/rdsk/c0t1d0s6 of=/dev/rst0 bs=10b \
count=10000

braces { }

Braces indicate required items:

.DEFINE {macro1}

brackets [ ]

Brackets indicate optional items:

cvtcrt termname [outfile]

ellipses ...

Ellipses indicate an arbitrary number of similar items:

CHKVAL fieldname value1 value2 ... valueN

italics

Italic type indicates a variable. Substitute a value for the variable:

library_name

vertical line |

A vertical line indicates a choice within braces or brackets:

FILE filesize [K|M]

Accessing Documentation

The documentation for this release includes platform-specific documentation and generic product documentation.

Product Documentation

Product documentation includes information about configuring, using, or administering Oracle products on any platform. The product documentation for Oracle Database 11g products is available in both HTML and PDF formats on the Oracle Technology Network (OTN) website:

http://www.oracle.com/technetwork/indexes/documentation/index.html

Related Documentation

The related documentation for Oracle Database 11g products includes the following manuals:

- Oracle Database Installation Guide

- Oracle Real Application Clusters Installation Guide

- Oracle Grid Infrastructure Installation Guide

For information about Oracle error messages, see Oracle Database Error Messages. Oracle error message documentation is available only in HTML. If you only have access to the Oracle Database 11g Release 2 (11.2) Online Documentation Library, then you can browse the error messages by range. Once you find the specific range, use your browser's "find in page" feature to locate the specific message. When connected to the Internet, you can search for a specific error message using the error message search feature of the Oracle online documentation.

Many books in the documentation set use the sample schemas of the seed database, which is installed by default when you install Oracle. Refer to Oracle Database Sample Schemas for information on how these schemas were created and how you can use them yourself.

To download free release notes, installation documentation, white papers, or other collateral, visit the Oracle Technology Network. You must register online before using OTN; registration is free and can be done at:

http://www.oracle.com/technetwork/community/join/index.html

If you have a user name and password for Oracle Technology Network, then you can go directly to the documentation section of the Oracle Technology Network website at:

http://www.oracle.com/technetwork/indexes/documentation/index.html

Typographic Conventions

The following text conventions are used in this document:

Convention

Meaning

boldface

Boldface type indicates graphical user interface elements associated with an action, or terms defined in text or the glossary.

italic

Italic type indicates book titles, emphasis, or placeholder variables for which you supply particular values.

monospace

Monospace type indicates commands within a paragraph, URLs, code in examples, text that appears on the screen, or text that you enter.

1 Overview of Oracle Database Client Installation

This chapter describes the different installation types of Oracle Database Client and issues to consider before you install Oracle Database Client:

- Planning Your Installation

- Installation Considerations

- Oracle Database Client Installation Types

- Oracle Database Client and Oracle Database Interoperability

- Simplified Patching of Timestamp with Time Zone Data Type

1.1 Planning Your Installation

The Oracle Database installation process consists of the following phases:

1. Review the licensing information: Although the installation media in your media pack contain many Oracle components, you are permitted to use only those components for which you have purchased licenses.
Oracle Support Services does not provide support for components for which licenses have not been purchased.

See Also:
Oracle Database Licensing Information

2. Plan the installation: This chapter describes the Oracle products that you can install and issues that you must consider before starting the installation.

3. Complete preinstallation tasks: Chapter 2 describes preinstallation tasks that you must complete before installing the product.

4. Install the software: Chapter 3 describes how to install Oracle Database Client.

5. Complete postinstallation tasks: Chapter 4 describes recommended and required postinstallation tasks.

1.2 Installation Considerations

This section contains hardware and software certification information that you should consider before deciding to install this product.

The platform-specific hardware and software requirements included in this guide were current when this guide was published. However, because new platforms and operating system software versions might be certified after this guide is published, review the certification matrix on the My Oracle Support website for the most up-to-date list of certified hardware platforms and operating system versions. The My Oracle Support website is available at the following URL:

https://support.oracle.com/

You must register online before using My Oracle Support. After logging in, from the menu options, select the Certifications tab. On the Certifications page, use the Certification Search options to search by Product, Release, and Platform. You can also search using the Certification Quick Links options such as Product Delivery and Lifetime Support.

1.3 Oracle Database Client Installation Types

In Oracle Database Client 11g Release 2, Instant Client and Instant Client Light are the only supported installation types.

The Instant Client installation type enables you to install only the shared libraries required by Oracle Call Interface (OCI), Oracle C++ Call Interface (OCCI), Pro*C, or Java Database Connectivity (JDBC) OCI applications. This installation type requires much less disk space than the other Oracle Database Client installation types.

See Also:
Oracle Call Interface Programmer's Guide or Oracle Database JDBC Developer's Guide for more information about Instant Client

The Instant Client Light (English) version of Instant Client further reduces the disk space requirements of the client installation. The size of the library has been reduced by removing error message files for languages other than English and leaving only a few supported character set definitions out of around 250.

This Instant Client Light version is geared toward applications that use either US7ASCII, WE8DEC, WE8ISO8859P1, WE8MSWIN1252, or a Unicode character set. There is no restriction on the LANGUAGE and the TERRITORY fields of the NLS_LANG setting, so the Instant Client Light operates with any language and territory settings. Because only English error messages are provided with the Instant Client Light, error messages generated on the client side, such as Net connection errors, are always reported in English, even if NLS_LANG is set to a language other than AMERICAN. Error messages generated by the database side, such as syntax errors in SQL statements, are in the selected language provided the appropriate translated message files are installed in the Oracle home of the database instance.

Instant Client Light supports the following client character sets:

- Single-byte

- US7ASCII

- WE8DEC

- WE8MSWIN1252

- WE8MSWIN1252

- WE8ISO8859P1

- Unicode

- UTF8

- AL16UTF16

- AL32UTF8

- Instant Client Light can connect to databases having one of these database character sets:

- US7ASCII

- WE8DEC

- WE8MSWIN1252

- WE8ISO8859P1

- WE8EBCDIC37C

- WE8EBCDIC1047

- UTF8

- AL32UTF8

The advantage of using Instant Client Light is that it has a smaller footprint than the regular Instant Client. The shared libraries, which an application must load, are only 34 MB as opposed to the 110 MB that regular Instant Client uses. Therefore, the applications use less memory.

1.4 Oracle Database Client and Oracle Database Interoperability

For information about interoperability between Oracle Database Client and Oracle Database releases, see Note 207303.1 on the My Oracle Support website at the following URL:

https://support.oracle.com/

1.5 Simplified Patching of Timestamp with Time Zone Data Type

Starting with Oracle Database 11g Release 2 (11.2), the patching process of TIMESTAMP WITH TIMEZONE data type values is simplified.

See Also:
"Oracle Database 11g Release 2 (11.2) New Features in Globalization" and "Clients and Servers Operating with Different Versions of Time Zone Files" in Oracle Database Globalization Support Guide for information about simplified patching process and how certain clients work with server with different time zone files

2 Oracle Database Client Preinstallation Tasks

This chapter describes the tasks that you must complete before you install Oracle Instant Client. It includes the following information:

- Logging In to the System as root

- Checking the Hardware Requirements

- Checking the Software Requirements

2.1 Logging In to the System as root

Before you install the Oracle software, you must complete several tasks as the root user. To log in as the root user, complete the following procedure:

1. Log in to the system as a user that is a member of the admin group.

2. Start a local terminal session (/Applications/Utilities/Terminal).

3. If you are not logged in as the root user, enter the following command to start a shell session with root privileges:

$ sudo sh

4. When prompted, enter your password.

2.2 Checking the Hardware Requirements

The system must meet the following minimum hardware requirements for Oracle Database Client 11g Release 2:

- Memory Requirements

- System Architecture

- Disk Space Requirements

- Display Requirements

- Recommended Hardware Requirement for SQL Developers

2.2.1 Memory Requirements

The following are the memory requirements for Oracle Database Client 11g Release 2 (11.2):

- At least 512 MB of RAM.
To determine the physical RAM size, use System Profiler (/Applications/Utilities/System Profiler) or enter the following command:

# /usr/sbin/system_profiler SPHardwareDataType | grep Memory

If the size of the physical RAM is less than the required size, then you must install more memory before continuing.

- The following table describes the relationship between installed RAM and the configured swap space requirement:

RAM

Swap Space

Up to 512 MB

2 times the size of RAM

Between 513 MB and 726 MB

1.5 times the size of RAM

More than 726 MB

0.75 times the size of RAM

To determine the size of the configured swap space, enter the following command:

# df -h

Note:

Mac OS X dynamically creates swap files as required in /private/var/vm directory. Ensure that you have at least 512 MB of available disk space on the root (/) file system to accommodate newly created swap files.

To determine the available RAM and swap space, enter the following command:

# free

IMPORTANT:

- Oracle recommends that you take multiple values for the available RAM and swap space before finalizing on a value. This is because the available RAM and swap space keep changing depending on the user interactions with the computer.

- Contact your operating system vendor for swap space allocation guidance for your server. The vendor guidelines supersede the swap space requirements listed in this guide.

2.2.2 System Architecture

To determine whether the system architecture can run the software, enter the following command:

# uname -p

Note:
This command displays the processor type. The command output must be i386. If you do not see the expected output, then you cannot install the software on this system.

2.2.3 Disk Space Requirements

The minimum disk space requirement for software files for Oracle Database Client 11g Release 2 (11.2) is 220 MB.

To determine the amount of free disk space available, enter the following command:

# df -h

2.2.4 Display Requirements

The minimum display requirement for Oracle Database 11g Release 2 (11.2) is a resolution of 1024 x 768 or higher.

2.2.5 Recommended Hardware Requirement for SQL Developers

The following are the recommended CPU, Memory and Display requirements for SQL Developer:

Resource

Recommended

Memory

1 GB RAM (recommended), 256 MB RAM (minimum)

Display

65536 colors, set to at least 1024 X 768 resolution

2.3 Checking the Software Requirements

Depending on the products that you intend to install, verify that the following software is installed on the system. The procedure following the table describes how to verify whether these requirements are addressed.

Item

Requirement

Operating system

The following or later versions of the operating system are supported for Oracle Database 11g Release 2 (11.2):

- Mac OS X Lion 10.7.3 or higher updates
Both 32-bit and 64-bit versions of Oracle Database Instant Client 11g Release 2 (11.2.0.3) are supported.

- Mac OS X Mountain Lion 10.8.2 or higher updates
Both 32-bit and 64-bit versions of Oracle Database Instant Client 11g Release 2 (11.2.0.3) are supported.

Tools

- Xcode 4.3.1 or later

- GNU C compiler (gcc) version 4.2.1 or later
This version of gcc is included in Xcode 4.3.1 or later.

- JDK 1.6.0_33 or later

Pro*C/C++, Oracle Call Interface, Oracle C++ Call Interface

The version of the GNU C and C++ compiler listed previously is supported for use with these products.

Oracle JDBC/OCI Drivers

You must use JDBC-OCI 1.6.0 or later versions with the JNDI extension.

See Also:
If you plan to use GNU Compiler Collection as the primary compiler, then refer to Oracle Database Installation Guide for Apple Mac OS X (Intel) for instructions on configuring the primary compiler

To ensure that the system meets these requirements:

1. To determine the operating system version, enter the following command:

# sw_vers

The output of this command must be similar to the following:

ProductName:    Mac OS X
ProductVersion: 10.7.4
BuildVersion:   11D50

Note:
Only the versions listed in the previous table are supported. Do not install the software on other versions of Apple Mac OS X.

2. To determine whether the required version of gcc is installed, enter the following command:

# gcc -v

This command returns output similar to the following:

Using built-in specs.
Target: i686-apple-darwin11
Configured with: /private/var/tmp/11vmgcc42/11vmgcc42-2336.9~22/src/configure --disable-checking --enable-werror --prefix=/Applications/Xcode.app/Contents/Developer/usr/llvm-gcc-4.2 --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-prefix=llvm- --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-slibdir=/usr/lib --build=i686-apple-darwin11 --enable-llvm=/private/var/tmp/llvmgcc42/llvmgcc42-2336.9~22/dst-llvmCore/Developer/usr/local --program-prefix=i686-apple-darwin11- --host=x86_64-apple-darwin11 --target=i686-apple-darwin11 --with-gxx-include-dir=/usr/include/c++/4.2.1
Thread model: posix
gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.9.00)

If the required version (including the date and build number) or a later version is not installed, then download and install Xcode 4.3.1 or later. You can download this software from the Apple Developer Connection website:

http://connect.apple.com/cgi-bin/WebObjects/MemberSite

After you log in, choose Download Software, then Developer Tools to display the download page.

2.3.1 Instant Client Light Requirements

In addition to the requirements described in the preceding section, if you plan to use Instant Client Light, then the applications must use the following languages and character sets:

- Language: Any language that is supported by Oracle

- Territory: Any territory that is supported by Oracle

- Character sets:

- Single byte

- US7ASCII

- WE8DEC

- WE8MSWIN1252

- WE8ISO8859P1

- Unicode

- UTF8

- AL16UTF16

- AL32UTF8

Instant Client Light can connect to databases having one of the following database character sets:

- US7ASCII

- WE8DEC

- WE8MSWIN1252

- WE8ISO8859P1

- WE8EBCDIC37C

- WE8EBCDIC1047

- UTF8

- AL32UTF8

Instant Client Light can also operate with the OCI Environment handles created in the OCI_UTF16 mode.

The language, territory, and character sets are determined by the NLS_LANG environment variable.

Note:
Ensure that you set the NLS_LANG environment variable to the required character set before you run Oracle Database Instant Client.

3 Installing and Removing Oracle Database Client

The Oracle Database Client software is available on Oracle Technology Network website. This chapter describes the following sections:

- Downloading and Installing the Oracle Database Client Software

- Removing the Oracle Database Client Software

3.1 Downloading and Installing the Oracle Database Client Software

Download and install Oracle Database Client 11g Release 2 by completing the following steps:

1. Download the Instant Client for Mac OS X (Intel) (32-bit and 64-bit) package from the Instant Client Downloads page on Oracle Technology Network at

http://www.oracle.com/technetwork/index.html

2. Create a directory on your computer, for example, instantclient. Choose a directory to install the Oracle Instant Client and unzip the downloaded zip file in that directory. The unzipped file creates the instantclient_11_2 directory.

3. Set the DYLD_LIBRARY_PATH and the NLS_LANG environment variables to the full path of the instantclient_11_2 directory. For example, if you unzipped the Instant Client zip file in the /bin/oracle directory, then set the DYLD_LIBRARY_PATH environment variable to /bin/oracle/instantclient_11_2.
Refer to "Instant Client Light Requirements" for information about setting the NLS_LANG environment variable to the required character set.

This completes the installation of Oracle Database Client. To connect to the Oracle Database server, run your client from the Oracle Database Instant Client environment.

3.2 Removing the Oracle Database Client Software

To remove the Oracle Database Client software, delete the instantclient_11_2 directory.

4 Oracle Database Client Postinstallation Tasks

This chapter describes how to complete postinstallation tasks after you have installed the Oracle Database Client software. It includes information about the following topics:

- Required Postinstallation Tasks

- Recommended Postinstallation Tasks

- Required Product-Specific Postinstallation Tasks

You must perform the tasks listed in "Required Postinstallation Tasks". Oracle recommends that you perform the tasks listed in "Recommended Postinstallation Tasks" after all installations.

If you install and intend to use any of the products listed in "Required Product-Specific Postinstallation Tasks", then you must perform the tasks listed in the product-specific subsections.

4.1 Required Postinstallation Tasks

You must perform the tasks described in the following sections after completing an installation:

- Updating Instant Client

- Connecting with Instant Client

4.1.1 Updating Instant Client

To update Instant Client:

1. Download Instant Client from Oracle Technology Network:
http://www.oracle.com/technetwork/database/features/instant-client/index-097480.html

2. If you want to place the files in the existing directory, then ensure that the directory is empty.
If you want to place the files into a different directory (and remove the previous files), ensure that you update the DYLD_LIBRARY_PATH environment variable setting to reflect the new location.

Note:
A restriction on Instant Client or Instant Client Light is that you cannot perform patch upgrades using the opatch utility because the Instant Client installation does not create an inventory, which the patch upgrade process must access for patch upgrades. The absence of an inventory also means that the installed intern patch reporting and conflict detection before a patch attempt are not possible.

4.1.2 Connecting with Instant Client

If you installed the Instant Client installation type, you can configure users' environments to enable dynamically linked client applications to connect to a database as follows:

1. Set the appropriate shared library path environment variable for the platform to specify the directory that contains the Instant Client libraries. For example, if your Instant Client is located in the /bin/oracle/instantclient_11_2 directory, then set the DYLD_LIBRARY_PATH environment variable to this directory.

2. Use one of the following methods to specify database connection information for the client application:

- Specify a SQL connect URL string using the following format:

//host:port/service_name

For example:

//shobeen:1521/sales_us

- Set the TNS_ADMIN environment variable to specify the location of the tnsnames.ora file and specify a service name from that file.

- Set the TNS_ADMIN and the TWO_TASK environment variables to specify a service name from the tnsnames.ora file.

Note:
It is not required that you specify the ORACLE_HOME environment variable.

4.2 Recommended Postinstallation Tasks

Oracle recommends that you perform the tasks described in the following sections after completing an installation:

- Connecting Instant Client or Instant Client Light to an Oracle Database

- Setting the NLS_LANG Environment Variable

4.2.1 Connecting Instant Client or Instant Client Light to an Oracle Database

Before you can connect Instant Client (including Instant Client Light) to an Oracle database, ensure that the DYLD_LIBRARY_PATH environment variable specifies the directory that contains the Instant Client libraries.

For example, if the shared libraries for Instant Client or Instant Client Light (if you have installed Instant Client Light) are in the /bin/oracle/instantclient_11_2 directory, then set the DYLD_LIBRARY_PATH environment variable to the following path:

/bin/oracle/instantclient_11_2

After checking the DYLD_LIBRARY_PATH environment variable, you can use any of the following methods to specify Oracle Database connection information for client applications:

- Specifying a Connection by Using the Easy Connect Naming Method

- Specifying a Connection Using an Empty Connect String and TWO_TASK

4.2.1.1 Specifying a Connection by Using the Easy Connect Naming Method

You can specify a connection address to an Oracle Database directly from a client application, without having to configure a tnsnames setting for the Instant Client. This method is convenient as you do not have to create and manage a tnsnames.ora file. However, the application users must specify the host name and port number when they want to log in to the application.

For example, if you run SQL*Plus on the client computer and want to connect to the sales_us database, which is located on a server whose host name is shobeen and port number is 1521, then you can log in as follows:

sqlplus system/admin@//shobeen:1521/sales_us

Similarly, in the application code, you can use Oracle Call Interface net naming methods to create the Instant Client-to-Oracle Database connection. For example, the following formats in the OCIServerAttach() call specify the connection information:

- Specify a SQL connect URL string using the following format:

//host[:port][/service_name]

For example:

//shobeen:1521/sales_us

- Alternatively, you can specify the SQL connect information as an Oracle Net keyword-value pair. For example:

"(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp) (HOST=shobeen) (PORT=1521))
(CONNECT_DATA=(SERVICE_NAME=sales_us)))"

See Also:
Oracle Call Interface Programmer's Guide for more information on using Oracle Call Interface Instant Client

4.2.1.2 Specifying a Connection Using an Empty Connect String and TWO_TASK

You can set the connect string to an empty connect string (""), and then set the TWO_TASK environment variable to one of the following values:

- A direct address, as described under "Specifying a Connection by Using the Easy Connect Naming Method"

- Oracle Net keyword-value pair

- A tnsnames.ora entry and TNS_ADMIN is set to the location of tnsnames.ora

- A tnsnames.ora entry and the following:

- tnsnames.ora file located in $ORACLE_HOME/network/admin

- The ORACLE_HOME environment variable set to this Oracle home

This method allows the applications to specify internally a connection string if the application code itself uses an empty connection string. The benefit of an empty connect string is that the application itself does not have to specify the tnsnames.ora entry. Instead, when a user starts the application, the location of the database is determined by a script or the environment, depending on where you have set the TWO_TASK environment variable. The disadvantage of using empty strings is that you must configure this additional information in order for the application to connect to the database.

4.2.2 Setting the NLS_LANG Environment Variable

NLS_LANG is an environment variable that specifies the locale behavior for Oracle software. This variable sets the language and territory used by the client application and the database user session. It also declares the character set of the client, which is the character set of data entered or displayed by an Oracle client program, such as SQL*Plus.

Note:
The character set of the data displayed is determined by the environment of the operating system, such as keyboard driver and fonts in use. The NLS_LANG character set should match the operating system.

Refer to the "Setting Up a Globalization Support Environment" section in Oracle Database Globalization Support Guide for information about Globalization Support.

4.3 Required Product-Specific Postinstallation Tasks

The following sections describe postinstallation tasks that you must perform if you install and intend to use Oracle Precompliers:

Note:
You must perform postinstallation tasks only for products that you intend to use.

4.3.1 Configuring Oracle Precompilers

This section describes postinstallation tasks for Pro*C/C++.

4.3.1.1 Configuring Pro*C/C++

Verify that the PATH environment variable setting includes the directory that contains the C compiler executable. The default directory for the gcc compiler executable is /usr/bin.

See Also:
Pro*C/C++ Programmer's Guide for more information about setting environment variables

Index

C  D  E  H  I  M  O  P  R  S  T

C

character sets, 2.3.1

checking system requirements, 2.3

checking the gcc version, 2.3

checking version of the operating system, 2.3

checking the gcc version, 2.3 checking version of the operating system, 2.3

D

disk space requirements, 2.2.3

display requirements, 2.2.4

downloading Oracle Database Client

installing Oracle Database Client, 3.1

E

environment variables

DYLD_LIBRARY_PATH, 3.1

NLS_LANG, 2.3.1, 3.1, 4.2.2

H

hardware requirement, 2.2

display requirements, 2.2.4

hardware requirement for SQL developers, 2.2.5

memory requirements, 2.2.1

system architecture, 2.2.2

hardware requirement for SQL developers, 2.2.5 hardware requirements

disk space requirements, 2.2.3

I

installation

available products, 1.3

installation considerations, 1.2

certifications, 1.2

installation types

Instant Client, 1.3

installing Oracle Database Client

downloading Oracle Database Client, 3.1

Instant Client

installation type, 1.3

Instant Client Light requirements, 2.3.1

character sets, 2.3.1

M

memory requirements, 2.2.1

O

operating system, 2.3

checking version of the operating system, 2.3

Oracle Database Instant Client

connecting to an Oracle Database, 4.2.1

Oracle Database Instant Client Light

connecting to an Oracle Database, 4.2.1

Oracle JDBC/OCI drivers, 2.3 Oracle precompilers, 4.3.1

Pro C/C++, 4.3.1

Oracle Technology Network

OTN, Preface

OTN

Oracle Technology Network, Preface

P

postinstallation tasks, 4

connecting with Instant Client, 4.1.2

NLS_LANG, 4.2.2

Oracle precompilers, 4.3.1

updating Instant Client, 4.1.1

preinstallation requirements

hardware requirement, 2.2

logging in to the system as root, 2.1

preinstallation tasks, 2

software requirements, 2.3

preinstallation tasks

preinstallation requirements, 2

Pro*C/C++ requirement, 2.3

R

removing Oracle Database Client, 3.2

S

software requirements, 2.3

checking system requirements, 2.3

Instant Client Light requirements, 2.3.1

operating system, 2.3

Oracle JDBC/OCI drivers, 2.3

Pro*C/C++ requirement, 2.3

tools requirement, 2.3

system architecture, 2.2.2

T

TIMESTAMP WITH TIMEZONE patching, 1.5

tools requirement, 2.3

Copyright © 2011, 2013, Oracle and/or its affiliates. All rights reserved.