Install the Oracle10g client in Ubuntu 8.10

Source: Internet
Author: User

Oracle has set up a dedicated apt source server for Ubuntu users. You only need to add a line in/etc/apt/source. list:
Deb http://oss.oracle.com/debian unstable main non-free
You can. Before running the apt-get update command, you must add the public key of the source server to the keystore of the local apt system. First download the public key:
Wget http://oss.oracle.com/el4/RPM-GPG-KEY-oracle
After the download is complete, add the public key to the keystore:
Sudo apt-key add RPM-GPG-KEY-oracle
Run again
Sudo apt-get update
Synchronize the software package index file.
We can download and install Oracle 10g Express Edition from this source. You can select the following software packages:
Oracle-xe-Oracle Database 10g Express Western European Edition
Oracle-xe-client-Oracle Client 10g Express Edition
Oracle-xe-universal-Oracle Database 10g Express Universal Edition
Because I only need to install a local client to connect to the Oracle server, I chose to install the oralce-xe-client package.
Sudo apt-get install oracle-xe-client
After the installation is successful, you also need to set relevant environment variables. Edit/etc/environment and add the following lines: (copy it directly. Otherwise, ORACLE_HOME is a directory)
ORACLE_HOME =/usr/lib/oracle/xe/app/oracle/product/10.2.0/client
LD_LIBRARY_PATH = $ ORACLE_HOME/lib: $ LD_LIBRARY_PATH
TNS_ADMIN =/usr/lib/oracle
PATH = $ PATH: $ ORACLE_HOME
After saving the file, run
Source/etc/environment
The environment variables that have been set immediately take effect on the current terminal. Switch to the/usr/lib/oracle directory and create the tnsnames. ora file to configure the connection information of the Oracle server.
After all the work is done, you can connect to the Oracle server locally for development.
If SQLPLUS is enabled
/Usr/lib/oracle/xe/application/oracle/product/10.2.0/client/bin/nls_lang.sh: 112: [[: not found
Then: vim/Usr/lib/oracle/xe/app/oracle/product/10.2.0/client/bin/nls_lang.sh

Original content:

If [[-n "$ LC_ALL"]; then
 Locale = $ LC_ALL
Elif [[-n "$ LANG"]; then
 Locale = $ LANG
Else
 Locale =
Fi

Modify:

If [-n "$ LC_ALL"]; then
 Locale = $ LC_ALL
Elif [-n "$ LANG"]; then
 Locale = $ LANG
Else
 Locale =
Fi

You can.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.