Home PC Games Linux Windows Database Network Programming Server Mobile  
  Home \ Linux \ Ubuntu install Oracle 10g process and problem solution     - Oracle ordinary users show parameter method (Database)

- How to forcibly change the Linux system password on a regular basis (Linux)

- Ubuntu font settings: Using Windows Font (Linux)

- Enterprise-class GitHub warehousing environment build (Server)

- GitLab remote backup of Linux Shell Scripting (Linux)

- CentOS6 5 source compiler installation Hadoop2.5.1 (Server)

- Linux systems use IP masquerading anti-hacker (Linux)

- MySQL monitoring tools -orzdba (Database)

- Linux_Logo - output color ANSI Linux distributions logo command-line tool (Linux)

- Linux signal and orphans, and zombie process (Programming)

- Elasticsearch 2.20 Beginners: aggregation (Server)

- How to install PlayOnLinux 4.2.5 under Ubuntu 14.04 / 12.04 (Linux)

- Build a super simple "hardware" firewall router (Linux)

- The Java way to stop a thread of execution (Programming)

- Linux Security (Linux)

- On Android running ClojureScript (Linux)

- Lenovo Ultrabooks Ubuntu system can not open the wireless hardware switch solutions (Linux)

- Workspace Go language and environment variables GOPATH (Linux)

- Docker build their own private warehouses (Linux)

- Let VMware ESXi virtual switch support VLAN (Linux)

  Ubuntu install Oracle 10g process and problem solution
  Add Date : 2018-11-21      
  PS: Ubuntu 12.04 install Oracle 10g whole process (perfect) and problem-solving approach under normal circumstances, the perfect correct. . If you encounter problems, there are solutions

1. Installation preparation work

1.1 oracle official website to download to their own computers oracle package;

I was: Oracle Database 10gRelease 2 ( Enterprise / Standard Edition for Linux x86 under: 10201_database_linux32.zip

Address: http: //www.oracle.com/technetwork/database/10201linuxsoft-097986.html

1.2 update ubuntu

# Apt-get update

# Apt-get upgrade

1.3 install additional javaJDK

Ubuntu Software Center in [] search OPENjdk, OpenJDK complete path after the installation path is automatically set up

1.4 install the missing package and reduce GCC version

apt-get install gcc make binutils lesstif2 libc6 libc6-dev rpm libmotif3 libaio1 alien

apt-get install ksh libtool libstdc ++ 5 build-essential compat-libstdc ++

Uninstall gcc-4.6, install gcc-4.4 version

apt-get remove gcc-4.6

apt-get install gcc-4.4

1.5 Create oracle user

Log on to the root user the following:

1.5.1 modify shell

ls -l / bin / sh if it is modified to bash dash

rm / bin / sh

ln -s / bin / bash / bin / sh

1.5.2 create users and groups and oracle installation path

addgroup oinstall

addgroup dba

addgroup nobody

usermod -g nobody nobody

adduser oracle

usermod -g oinstall -G dba oracle

id oracle

id nobody

mkdir -p / opt / oracle

mkdir -p / opt / oradata

chown -R oracle: dba / opt / ora *

chmod -R 775 / opt / ora *

1.5.3 Create deceive Disclaimer

vi / etc / RedHat-release

Then adding Red Hat Linux release 3.1

1.5.4 establish a link

ln -s /usr/bin/gcc-4.4 / usr / bin / gcc

ln -s /lib/i386-linux-gnu/libgcc_s.so.1 /lib/libgcc.s.so.1

ln -s / usr / bin / awk / bin / awk

ln -s / usr / bin / rpm / bin / rpm

ln -s / usr / bin / basename / bin / basename

mkdir /etc/rc.d

ln -s /etc/rc0.d /etc/rc.d/rc0.d

ln -s /etc/rc1.d /etc/rc.d/rc1.d

ln -s /etc/rc2.d /etc/rc.d/rc2.d

ln -s /etc/rc3.d /etc/rc.d/rc3.d

ln -s /etc/rc4.d /etc/rc.d/rc4.d

ln -s /etc/rc5.d /etc/rc.d/rc5.d

ln -s /etc/rc6.d /etc/rc.d/rc6.d

ln -s /etc/init.d /etc/rc.d/init.d

1.5.5 add users to the list sudoer

vi / etc / sudoers

In the "root ALL = (ALL: ALL) ALL" the next line, add:

oracle ALL = (ALL: ALL) ALL

1.5.6 modify kernel parameters and system variables

A modify /etc/sysctl.conf file (can not modify)

gedit /etc/sysctl.conf

Add the following:

kernel.shmall = 2097152

kernel.shmmax = 2147483648

kernel.shmmni = 4096

kernel.sem = 25 32000 100 128

fs.file-max = 65536

net.ipv4.ip_local_port_range = 1024 65000

B modification /etc/security/limits.conf (can not modify)

gedit /etc/security/limits.conf

Add the following:

* Soft nproc 2407

* Hard nproc 16384

* Soft nofile 1024

* Hard nofile 65536

Note: Do not forget the "*" sign can be replaced with oracle

C ubuntu modify the oracle user's environment variables

/home/oracle/.profile And modify / etc / profile file two

vi /home/oracle/.profile

vi / etc / profile

Add the following:

#oracle_path start

export ORACLE_HOME = / opt / oracle

export ORACLE_SID = orcl

export ORACLE_OWNER = oracle

export PATH = $ PATH: $ ORACLE_HOME / bin

#oracle_path end

1.5.7 enable the parameters

Reboot the system or terminal Run sysctl -p

1.5.8 The oracle installation file downloaded to the next mv / home / oracle, and unzip it. Logout root user login oracle user

2. Start the installation oracle

2.1 Open a terminal, cd to the next / home / oracle / database of oracle-extracting files, execute the following command

./runInstaller -jreLoc / usr / lib / jvm / java-6-openjdk-i386 / jre

  java-version is java version installed, which is a fancy to oracle in the image will not be garbled or block

Then to install the same image under windows installation interface.

Does not work, use English installation interface



2.2 Follow the steps image


2.3 Configuration script to execute

  Switch to the root, execute the script in the terminal



2.4 appears oracle database 10g installation is complete, note the two URL.

2.5 Install Database

  Run the following command in the terminal:

$ Dbca // If the Chinese garbled, run the following command

$ Cd / opt / ora10 / bin

$ Gedit dbca

Find "JRE_DIR = / opt / ora10 / jdk / jre" in dbca, replace the JRE_DIR = / usr / lib / jvm / java-1.6.0-openjdk / jre, then save and exit

$ Dbca // normal show

2.6 perform the following steps


  But: To use the database name and SID must be written on orcl

  Until the installation is complete.

3. Start the oracle

In the "Terminal" Run as oracle

Start TNS listener: $ ORACLE_HOME / bin / lsnrctl start

($ ORACLE_HOME, is the oracle installation directory:. / Opt / ora10 direct cd, into the oracle installation directory to the bin folder, $ lsnrctl start, too).

Close TNS: $ ORACLE_HOME / bin / lsnrctl stop

Start sqlplus: $ ORACLE_HOME / bin / sqlplus / nolog

Close sqlplus: SQL> exit

4. In order to be able to use the same as under the windows up and down keys to flip command, also need to install rlwrap package:

sudo apt-get install rlwrap

Then modify the oracle user's ~ / .bashrc file and / etc / profile document, in its final add two lines:

So the arrow keys can be used.

Finally, to solve the problem oracle Chinese character set. Not surprisingly, then, start oracle will find all the Chinese are "?", Or is garbled, this is actually a server-side character set and client character set is inconsistent result.

Solution to: DBA identity into sqlplus, make inquiries

SQL> select userenv ( 'language') from dual;

Copy the query results, in /etc/bash.bashrc file plus line: export NLS_LANG = "Search Results" and re-log problem is solved. For example: my query results SIMPLIFIED CHINESE_CHINA.AL32UTF8, then add a new behavior export NLS_LANG = "SIMPLIFIED CHINESE_CHINA.AL32UTF8".

But sometimes this approach is not always successful, you can



Two files are written to try, but two written documents must be consistent.

5. If you have a problem, according to the following procedure Treatment:


Question: call makefile '. . Error install '/sqlplus/lib/ins_sqlplus.mk' goal '. See '/home/oracle/oraInventory/logs/installActions2011-12-06_11-03-18AM.log' for details.

Workaround: $ ORACLE_HOME / sqlplus / lib / env_sqlplus.mk add a line: EXPDLIBS = -lclntsh, then click the "Retry" button, ok.

In fact, after install gcc-4.4 does not have this problem.


Question: call makefile '. . Error agent nmo nmb 'when /sysman/lib/ins_sysman.mk' goal '. See '. . /oraInventory/logs/installActions2011-12-06_11-03-18AM.log 'for more information.

Analysis: Error encountered later in fact essentially a main problem is the version of gcc high, oracle10g the gcc version is 3.4 or so, but ubuntu speed of development has long used the version 4.0 or higher, and you can not install apt low version

Workaround: Uninstall gcc-4.6, install gcc-4.4 version

apt-get remove gcc-4.6

apt-get install gcc-4.4


Call makefile '. . Error install '/network/lib/ins_net_server.mk' goal '. See '. . /oraInventory/logs/installActions2011-12-06_11-03-18AM.log 'for more information.

        Analysis: Internet I found an article similar documents, see (click to open the link), but I still have a problem, manually compiled, and not -lons parameters of the problem he had referred in oracle10g in.

        Or gcc version of the problem, I have tried to install a lower version of gcc, but a start compiling on the error, so give up, if someone can successfully reduce version environment, I believe we can solve all the wrong question, which is why ubuntu 8 can naturally successful installation of an explanation.

        Method: At present, I have no way to follow the instructions of their .mk file, this thing seems to be time to re-link the database link with fracture

Workaround: Uninstall gcc-4.6, install gcc-4.4 version

In the / usr / bin made of soft links /usr/bin/gcc-4.4

cd / usr / bin

ln -s /usr/bin/gcc-4.4 / usr / bin / gcc


Call makefile '. . Error all_no_orcl ihsodbc '/rdbms/lib/ins_rdbms.mk' goal '. See '. . /oraInventory/logs/installActions2011-12-06_11-07-36-AM.log 'for more information.

      Analysis: We look at the log file

        Information: Generating BASE ORASDK library ...

        Information: Creating /opt/ora10/lib/liborasdkbase.so.10.2

        Information: gcc: Error: /lib/libgcc_s.so.1: No such file or directory

        gcc: error:. / usr / lib / libstdc ++ so.5: No such file or directory

        We are finally seeing that a lot of mistakes, but it is still gcc problem, re-download the libgcc_s.so.1, and re-do stdc ++ links 5, but the problem still more, because only soft links and Download a dynamic library is impossible to solve all the problems.

Workaround: Install the compat-libstdc ++ - 33_3.2.3-48.3_i386.deb, try again. .

In a soft link libgcc_s.so.1

cd / lib

ln -s /lib/i386-linux-gnu/libgcc_s.so.1 libgcc.s.so.1

6. boot

6.1 root the following modifications: vi / etc / oratab

orc1: /opt/oracle/product/10.2.0/db_1: Y

This is the N Y

6.2 oracle following modifications:

cd $ ORACLE_HOME / bin

vi dbstart

ORACLE_HOME_LISTNER find this line, modified to:

ORACLE_HOME_LISTNER = / opt / oracle / product / 10.2.0 / db_1

Modify or directly to:


Test Run dbshut, dbstart see if I can start oracle service and listener service

ps -efw | grep ora_

lsnrctl status

ps -efw | grep LISTEN | grep -v grep

Create a file under 6.3 root:

vi /etc/rc.d/init.d/oracle10

#! / Bin / bash

# Chkconfig: 345 99 10

# Description: Startup Script for Oracle Databases

# /etc/init.d/oracle10

export ORACLE_SID = ym

# Export ORACLE_HOME_LISTNER = / data / files / oracle / 10g / bin

#oracle installation directory

export ORACLE_HOME = / data / files / oracle / 10g

export PATH = $ PATH: $ ORACLE_HOME / bin

case "$ 1" in


su oracle -c $ ORACLE_HOME / bin / dbstart # Start Service

su oracle -c $ ORACLE_HOME / bin / lsnrctl start # start listening

touch / var / lock / oracle

echo "OK"



echo -n "Shutdown Oracle:"

su oracle -c $ ORACLE_HOME / bin / dbshut # start shutting down services

su oracle -c $ ORACLE_HOME / bin / lsnrctl stop # Close monitoring

rm -f / var / lock / oracle

echo "OK"



echo "Usage: 'basename $ 0' start | stop"

exit 1


exit 0


chmod 775 oracle10

chkconfig --add oracle10

chkconfig --list oracle10
- The hash function under OpenSSL (Linux)
- Ubuntu installation 2.10.x version of Scala (Linux)
- Linux crontab (Linux)
- Configuring Proxy on a Unix terminal, accelerate Android Studio Construction (Linux)
- Linux Getting Started tutorial: Experience VirtualBox Virtual Machine chapter (Linux)
- Disk Management LVM (Linux)
- Linux vi command list (Linux)
- How to avoid two Chrome icon appears in ELementary OS Freya (Linux)
- Rails 4.1.6 start being given Could not find a JavaScript runtime (Linux)
- Variables Python variables (Programming)
- Big Data Common Glossary (Linux)
- Linux process group, session daemon (Linux)
- Ubuntu Apache2 setting, problem solving css, pictures, etc. can not be displayed (Server)
- Spring Data study notes -Helloworld (Programming)
- Linux pwd command learning experience (Linux)
- How the program is executed (Programming)
- Android custom slideshow menu slidmenu (Programming)
- CentOS / Linux SELinux Close (Linux)
- Teach you to diagnose problems with strace (Linux)
- Android thread mechanism --AsyncTask (Programming)
  CopyRight 2002-2020 newfreesoft.com, All Rights Reserved.