Install Oracle10g in RedhatEnterpriseLinux5.6

Source: Internet
Author: User
Note: The Oracle version is 10 GB and the Linux version is RedHatEnterpriseLinux5.61. Check whether the system has installed the file package rpm-qgc required by oracle.

Note: The Oracle version is 10 GB and the Linux version is RedHat Enterprise Linux 5.61. Check whether the system has installed the file package rpm-q gc required by oracle.

Note: The Oracle version is 10 GB and the Linux version is RedHat Enterprise Linux 5.6.

1. Check whether the system has installed the file packages required by oracle.

Rpm-q gcc make binutils openmotif setarch compat-db compat-gcc-c ++ compat-libstdc ++-devel libXp

Because there is a strict dependency between the missing packages, you must install the missing packages in the following order.
Compat-db-4 rpm-Uvh *
Libaio-0 rpm-Uvh *
Rpm-Uvh compat-libstdc ++-33-3 *
Rpm-Uvh glibc-headers-2.5-12.i386.rpm
Rpm-Uvh glibc-devel-2.5-12.i386.rpm
Compat-gcc-34-3 rpm-Uvh *
Rpm-Uvh compat-gcc-34-c ++-3 *
LibXp-1 rpm-Uvh *
Openmotif-2 rpm-Uvh *
Gcc-4 rpm-Uvh *
Rpm-Uvh glibc-2.5-12.i686.rpm
Rpm-Uvh libgomp-4.1.1-52.el5.i386.rpm
Rpm-Uvh gcc-4.1.1-52.el5.i386.rpm
After the installation is complete, the system still prompts that some packages are not installed, but it does not affect the usage.
Package compat-gcc is not installed
Package compat-gcc-c ++ is not installed
Package compat-libstdc ++ is not installed
Package compat-libstdc ++-devel is not installed

2. Added Oracle Installation and Use users.
(1) Add groups and users
Groupadd oinstall
Groupadd dba
Groupadd rule
Useradd-g oinstall-G dba oracle
Passwd oracle
(2) create an Oracle installation directory and grant the permission to the oracle user. The file is already available after the user is created.
Mkdir-p/home/oracle/(create a folder recursively)
Chown-R oracle: oinstall/home/oracle
Chmod-R 775/home/oracle

3. modify the configuration file
(1) Add the following content at the end of the/etc/sysctl. conf line, and modify the existing content
Kernel. shmmni = 4096
# Semaphors: semmsl, semmns, semopm, semmni
Kernel. sem = 250 32000 100 128
Fs. file-max = 65536
Net. ipv4.ip _ local_port_range = 1024 65000
Net. core. rmem_default = 262144
Net. core. rmem_max = 262144
Net. core. wmem_default = 262144
Net. core. wmem_max = 262144


Run the following command to make the kernel parameters take effect.
/Sbin/sysctl-p

(2) Add the following content at the end of the/etc/security/limits. conf line
# Use for oracle
# * Soft nproc 2047
# * Hard nproc 16384
# * Soft nofile 1024
# * Hard nofile 65536

(3) Add the following content at the end of the/etc/pam. d/login line
Session required pam_limits.so

(4)/etc/selinux/config
Change SELINUX = disabled to disable the firewall, required

(5) After creating a user, bash_profile has a. bash_profile under the user's directory (using an Oracle user)
Add the following content to the file:
(ORACLE_BASE is the most important. It represents the installation path of Oracle)
(You can create a database during installation. If the database is restarted after installation, it cannot be started when the listener is restarted. Note that ORACLE_HOME must be modified according to the actual path after the database is installed)

ORACLE_BASE =/home/oracle
ORACLE_HOME = $ ORACLE_BASE/product/10.2.0/db_1
ORACLE_SID = orcl
PATH = $ PATH: $ HOME/bin: $ ORACLE_HOME/bin
LD_LIBRARY_PATH = $ ORACLE_HOME/lib:/usr/lib
Export ORACLE_BASE ORACLE_HOME ORACLE_SID PATH LD_LIBRARY_PATH

Another parameter: NLS_LANG is the character set of the database. To ensure that the database can input and output correct language characters (such as simplified Chinese) in the user's region, set the character set to american_america.ZHS16GB K here, american_america is the English character set, and ZHS16GBK is the Chinese character set.

Note that many Oracle Installation failures occur because the environment variables are not correctly configured. The configuration of the environment variables directly affects the later installation and configuration of Oracle10g. Be careful when configuring the environment variables!

(6) modify the hosts file
Edit/etc/hosts. The file should contain text similar to the following:
127.0.0.1 localhost. localdomain localhost (logout)
192.168.203.11 stctestbox01.us.oracle.com stctestbox01 (enter the IP address here)

Change the/etc/redhat-release file because the Oracle10g Database does not currently support RHEL5:
# Vi/etc/redhat-release
# Red Hat Enterprise Linux Server release 5.6 (Tikanga)
Redhat-4

After the installation is complete, change it back.

4. Switch to the root permission and install oracle

Set the DISPLAY variable

The display variable, which is used to tell the system where the figure will be output. The default value is the Local Computer (export DISPLAY =: 0.0). If you use virtual x-windows for installation, the following figure shows the DISPLAY of the remote terminal. For example, if the IP address of the remote terminal is 100.100.100.149, set the DISPLAY variable to "100.100.100.149: 0". 0 "indicates the first display of the terminal.

Xhost + (enabling x-window)

Xhost controls who can access the enhanced X-Windows on the current host.

Xhost + enables all users to access Xserver.

Xhost + ip enables users on the ip address to access Xserver.

Xhost + nis: user @ domain enables the nis user on the domain to access

Xhost + inet: user @ domain enables inet users on the domain to access

Run the xhost command to add or delete the host name on the list of hosts that the X Server accepts connections.

Decompress (Oracle users)
Unzip 10201_database_linux32.zip-d/tmp/oracle


Change permissions
Chown oracle/tmp/oracle
Chmod-R 755/tmp/oracle
Su-oracle
To the root directory:./runInstaller
(If you do not create a database during installation, you can run dbca under Oracle_HOME/bin to create and manage the database)

Note: Execute the command one by one during the installation package. I found that an error is reported in a command in the middle after all commands are directly executed, indicating that there is dependency. In this case, you can add the parameter -- nodeps during the installation package.

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.