Install Oracle 10g in Linux

Source: Internet
Author: User

Installing oracle in Linux is a daunting task. Its complexity far exceeds that of installing the Linux operating system. If Oracle is successfully installed
At the same time, I also mastered some Linux technologies. This article describes how to install Oracle 10 Gb in RedHat Linux. Description 1: Oracle
10g is short for grid, which is currently a cutting-edge network computing technology. ---Www.bianceng.cn

Oracle 10g has very high requirements on hardware and software, so it takes a lot of money to make fun of it. First, let's take a look at its hardware requirements: 512 MB memory (1 GB recommended), CPU
Clock speed above 7200 GB, Hard Drive Speed above RPM (SCSI hard drive is recommended), according to this condition, I can buy a server. Second, software requirements: in Oracle
In the official documents, there are only three supported operating systems (radhat ES/as 2.1 (x86) and RedHat ES/
3 (x86), unitedlinux1.0 (x86), which can be installed if only RedHat 9 is available, but it requires a little trouble. Of course Oracle
10g requires more software modules for installation. I will describe these software modules one by one later. In this example, use RedHat es
3 (x86) is used as the operating platform and XWindow is installed.

Next, check whether the installation requirements of Oracle 10g are met and list them in a table. The first is the hardware. Log on to the system as root and start X-window. If the value output by the command below is greater than or equal to the recommended value, check the recommended value of the project command/method.

Memory # grep memtotal/proc/meminfo 512 MB

Swap partition # grep swaptotal/proc/meminfo 1 GB

/Tmp directory idle zone # DF-k/tmp 400 mb

Hard Disk Free Space # DF-K 4 GB

Continue to check the software requirements. For RedHat Es 3 (x86), the following software packages are required:

GNU gcc package, gcc-3.2.3-2 or higher

The following package must also be installed:

·make-3.79 
·binutils-2.11
·openmotif-2.2.2-16
·setarch-1.3-1
·compat-db-4.0.14.5
·compat-gcc-7.3-2.96.122
·compat-gcc-c++-7.3-2.96.122
·compat-libstdc++-7.3-2.96.122
·compat-libstdc++-devel-7.3-2.96.122

To ensure that the system meets the requirements, perform the following steps to check the installed Linux version and installed suite.

Check recommended project commands/methods

Linux # Cat/etc/issue Es 3

Installed packages # required packages for rpm-Q package_name installation (listed in the table above)

Here we have thoroughly checked the software and hardware environment required to install Oracle 10 Gb, and then we will create a group and a user for the installation.

The following groups and users must exist.

The oinstall group (the oracle inventory group)
The dba group (the OSDBA group)
The oracle user (the oracle owner)

If the preceding groups and users do not exist, use the following steps to create them.

(1) check whether these groups and users exist:

# Grep oinstall/etc/group

# Grep DBA/etc/group

(2) create groups and users required to install Oracle

# Groupadd oinstall

# Groupadd DBA

# Useradd-G oinstall-g dba Oracle

Check whether Oracle belongs to the group oinstall and DBA (# ID Oracle). Then, set a user password for Oracle # passwd Oracle and enter the password twice.

Create the directory/u01/APP/Oracle (the Oracle base Directory),/u02/oradata (an optional default directory) required for installation, and create it using the command form in the following table. then change its directory permissions.

Create Directory change permission

# Mkdir-P/u01/APP/Oracle # chown-r ORACLE: oinstall/u01/APP/Oracle/u02/oradata

# Mkdir-P/u02/oradata # chmod-r 755/u01/APP/Oracle/u02/oradata

Configure the kernel parameters. The following table lists the Kernel Parameter values recommended by Oracle. For more information, see.

Parameter Value File
semmsl
semmns
semopm
semmni 250
32000
100
128 /proc/sys/kernel/sem
shmall 2097152 /proc/sys/kernel/shmall
shmmax Half the size of physical memory /proc/sys/kernel/shmmax
shmmni 4096 /proc/sys/kernel/shmmni
file-max 65536 /proc/sys/fs/file-max
ip_local_port_range 1024 65000 /proc/sys/net/ipv4/ip_local_port_range

Make sure that the current parameter value is greater than or equal to the values listed in the preceding table. So how to view these parameter values? Run the command #/sbin/sysctl-A | grep
<Parameter Name>, for example, to view semmsl, use #/sbin/sysctl-A | grep
SEM, the remaining is similar. View these parameter values one by one. If the parameter values do not meet the requirements, modify them. Complete these steps

A. Use a text editor to create or edit the/etc/sysctl. conf file and add or modify the following lines:

Kernel. Shmall = 2097152
Kernel. shmmax = 2147483648
Kernel. shmmni = 4096
Kernel. SEM = 250 32000 100 128
FS. File-max = 65536
Net. ipv4.ip _ local_port_range = 1024 65000

B. Use the command #/sbin/sysctl-P to change the value of the current Kernel Parameter.

To improve the performance of running software on Linux, you must set the following shell limits for oracle users.

Shell limit item in limits. conf hard limit
Maximum number of open file descriptors nofile 65536
Maximum number of processes available to a single user nproc 16384

Now create these limits:

1. Add the following row to the file/etc/security/limits. conf.

* Soft nproc 2047
* Hard nproc 16384
* Soft nofile 1024
* Hard nofile 65536

2. Add the following row to the file/etc/PAM. d/login. If it does not exist

Session required/lib/security/pam_limits.so

3. Based on the default shell of oracle users, change the default shell start-up file as follows. If it is a Bourne, Bash, or Korn shell, modify the environment variable/etc/profile file as follows:

If [$ user = "oracle"]; then
If [$ shell = "/bin/KSh"]; then
Ulimit-P 16384
Ulimit-N 65536
Else
Ulimit-u 16384-N 65536
Fi
Fi
If it is a C shell, the change value of the environment variable file/etc/CSH. login is as follows:
If ($ user = "oracle") then
Limit maxproc 16384
Limit descriptors 65536
Endif

Next, attach the CD, # Mount/dev/CDROM/mnt/CDROM.

Log on to the system with the Oracle user name and configure the Oracle user environment. You can use the installer to install Oracle using an oracle account. Before running the installer, you must set the environment variables of the Oracle user. Therefore, you must:

● Set umask of the shell Startup File to 022

● Set the environment variables of display, oracle_base, and oracle_sid. The following steps are used to set these environment variables:

1. Start a terminal session

2. Check whether the XWindow is displayed normally. # Xhost +

3. Change the user to Oracle. $ su-Oracle

4. Check the Oracle user's default shell. $ echo $ Shell

5. Use a text editor to modify the environment variables of oracle users

● Bash shell on RedHat

$ VI. bash_profile

● C Shell

% VI. Login

6. Insert the following row into the file edited above

Umask 022

7. Save the file and exit

8. Run the shell start script:

● Bash shell on Red Hat $.../. Profile

● C shell % source./. Login

9. Set Environment Variables

● BASH Shell

$ Oracle_base =/u01/APP/Oracle

$ Oracle_sid = Sales

$ Export oracle_base oracle_sid

● C Shell

% Setenv oracle_base/u01/APP/Oracle

% Setenv oracle_sid sales

10. confirm that the ORACLE_HOME and tns_admin environment variables are not set by the user.

● BASH Shell

$ Unset ORACLE_HOME

$ Unset tns_admin

● C Shell

% Unsetenv ORACLE_HOME

% Unsetenv tns_admin

11. Check whether the environment variables set above are correct.

$ Umask

$ ENV | more

Go to the installation directory $ CD/tmp where the installer (runinstaller) is located to run and install $/mnt/CDROM/runinstaller. Follow the prompts to complete the installation.

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.