Install Oracle 11g R2 and oracle11g in Redhat Linux
Official documents: http://docs.oracle.com/cd/E11882_01/nav/portal_11.htm
1: Basic Environment
Redhat Enterprise Linux 6.132bit
Memory: 1 GB
Disk Space: 30 GB
2: Check the packages required for Oracle 11G. If the packages are not found on the Redhat Enterprise Linux 6.1 installation CD, install them.
ORACLE official: http://docs.oracle.com/cd/E11882_01/install.112/e24326/toc.htm
· Binutils-2.20.51.0.2-5.11.el6 (x86_64)
· Compat-libcap1-1.10-1 (x86_64)
· Compat-libstdc ++-33-3.2.3-69.el6 (x86_64)
· Compat-libstdc ++-33-3.2.3-69.el6.i686
· Gcc-4.4.4-13.el6 (x86_64)
· Gcc-c ++-4.4.4-13. el6 (x86_64)
· Glibc-2.12-1.7.el6 (i686)
· Glibc-2.12-1.7.el6 (x86_64)
· Glibc-devel-2.12-1.7.el6 (x86_64)
· Glibc-devel-2.12-1.7.el6.i686
· Ksh
· Libgcc-4.4.4-13.el6 (i686)
· Libgcc-4.4.4-13.el6 (x86_64)
· Libstdc ++-4.4.4-13. el6 (x86_64)
· Libstdc ++-4.4.4-13. el6.i686
· Libstdc ++-devel-4.4.4-13.el6 (x86_64)
· Libstdc ++-devel-4.4.4-13.el6.i686
· Libaio-0.3.107-10.el6 (x86_64)
· Libaio-0.3.107-10.el6.i686
· Libaio-devel-0.3.107-10.el6 (x86_64)
· Libaio-devel-0.3.107-10.el6.i686
· Make-3.81-19.el6
· Sysstat-9.0.4-11.el6 (x86_64)
Provided by netizens:
1, binutils-2.17.50.0.6 binutils-2.20.51.0.2-5.20.el6.x86_64.rpm
2. compat-libstdc ++-33-3.2.3 compat-libstdc ++-33-3.2.3-69.el6.x86_64.rpm
3, elfutils-libelf-0.125 elfutils-libelf-0.152-1.el6.x86_64.rpm
4, elfutils-libelf-devel-0.125 elfutils-libelf-devel-0.152-1.el6.x86_64.rpm
Elfutils-libelf-devel-static-0.125 5
6, gcc-4.1.2 gcc-4.4.5-6.el6.x86_64.rpm
7. gcc-c ++-4.1.2 gcc-c ++-4.4.5-6. el6.x86 _ 64.rpm
Glibc-2.5-24, glibc-2.12-1.25.el6.x86_64.rpm
9, glibc-common-2.5 glibc-common-2.12-1.25.el6.x86_64.rpm
10, glibc-devel-2.5 glibc-devel-2.12-1.25.el6.x86_64.rpm
11, glibc-headers-2.5 glibc-headers-2.12-1.25.el6.x86_64.rpm
12, kernel-headers-2.6.18 kernel-headers-2.6.32-131.0.15.el6.x86_64.rpm
13, ksh-20060214 ksh-20100621-6.el6.x86_64.rpm
14. libaio-0.3.106 libaio-0.3.107-10.el6.x86_64.rpm
15, libaio-devel-0.3.106 libaio-devel-0.3.107-10.el6.x86_64.rpm
16, libgcc-4.1.2 libgcc-4.4.5-6.el6.x86_64.rpm
17, libgomp-4.1.2 libgomp-4.4.5-6.el6.x86_64.rpm
18. libstdc ++-4.1.2 libstdc ++-4.4.5-6. el6.x86 _ 64.rpm
19, libstdc ++-devel-4.1.2 libstdc ++-devel-4.4.5-6.el6.x86_64.rpm
Make-3.81-19.el6.x86_64.rpm 20, make-3.81
Sysstat-7.0.2, sysstat-9.0.4-18.el6.x86_64.rpm
22, unixODBC-2.2.11 unixODBC-2.2.14-11.el6.x86_64.rpm
23, unixODBC-devel-2.2.11 unixODBC-devel-2.2.14-11.el6.x86_64.rpm
2: run the rpm-q package name command to check whether these packages have been installed:
[Root @ Pet ~] #Rpm-q binutils compat-libstdc ++ elfutils-libelf-develelfutils-libelf-devel-static gcc-c ++ glibc-common glibc-develglibc-headers kernel- headers ksh libaiolibaio-devel libgcc libgomp libstdc ++-devel make sysstat unixODBCunixODBC-devel mpfr ppl clog-ppl cpp (Installation Error prompt, added the four packages to solve the problem)
3: if the package is not installed, run the following command to install the package:
Rpm-ivh unixODBC * -- nodeps -- force
4: Specify the Host Name:
Vim/etc/sysconfig/network
Change the HOSTNAME to the host name you want to set (for example, HJD)
5. Modify the hosts file:
Vim/etc/hosts
Add one: the host name you just set for your IP address
Note: To view the IP address on your host, run the ifconfig-a command.
6. Modify parameters
/Etc/sysctl. conf (modify kernel parameters)
/Etc/security/limits. conf (shell restrictions on oracle users)
/Etc/pam. d/login
/Etc/profile (system-related environment variables)
/Oracle/. bash_profile (oracle user-related environment variables)
6.1 Modify/etc/sysctl. conf
Run the following command:
Vi/etc/sysctl. conf
Modify and add the following content:
# Kernel paramaters required by Oracle11g R2
Fs. aio-max-nr = 1048576
Fs. file-max = 6815744
Kernel. shmall = 2097152
Kernel. shmmax = 536870912
Kernel. shmmni = 4096
Kernel. sem = 250 32000 100128
Net. ipv4.ip _ local_port_range = 900065500
Net. core. rmem_default = 262144
Net. core. rmem_max = 4194304
Net. core. wmem_default = 262144
Net. core. wmem_max = 1048586
(Note: SHMMAX parameter: maximum value of the separately shared memory segment that can be allocated by a Linux Process. It is generally set to half the total memory size. The setting of this value should be greater than the value of SGA_MAX_TARGET or MEMORY_MAX_TARGET. Therefore, the shmmax value of the system that installs the Oracle database should be larger than 1/2 of the memory.
Kernel. shmmax = physical memory * 0.8
SHMMNI parameter: set the maximum number of system-level shared memory segments. We recommend that you set the minimum value of Oracle10g to 4096, which can be increased by 4096.
Kernel. shmmni = 4096
SHMALL parameter: Set the total number of pages in the shared memory. If the value is too small, an error may be reported during database startup. The recommended value is physical memory size divided by page size. (Page size: getconf PAGE_SIZE)
Kernel. shmall = physical memory/PAGE_SIZE
SEMMSL parameter: sets the maximum number of signals in each traffic signal group. The recommended minimum value is 250. For systems with a large number of concurrent connections, we recommend that you set this value to the PROCESSES initialization parameter plus 10.
SEMMNI parameter: set the maximum number of traffic signal groups in the system. The recommended Oracle10g and 11g values are 142.
SEMMNS parameter: set the maximum number of signals in the system. The recommended SEMMNS value is set to SEMMSL * SEMMNI, And the Oracle recommended SEMMNS value is not less than 32000.
SEMOPM parameter: set the maximum number of traffic signal operations that can be performed simultaneously by each system call. The SEMOPM configurations for Oracle 10.2 and 11.1 are 100.
Kernel. sem = 610 86620 100 142 (the four values are respectively SEMMSL, SEMMNS, SEMOPM, and SEMMNI from left to right ))
Save and exit. Run the following command to make the set kernel parameters take effect.
/Sbin/sysctl-p/ect/sysctl. conf or sysctl-p
6.2 Modify/etc/security/limits. conf
Vi/etc/security/limits. conf
Add the following content to the end of the file:
Oracle soft nproc 2047
Hard nproc 16384
Oracle soft nofile 1024
Oracle hard nofile 65536
6.3 Modify/etc/pam. d/login
Vi/etc/pam. d/login
Add the following content to this file:
Session required/lib/security/pam_limits.so
6.4 Modify/etc/profile
Vi/etc/profile
Add the following content to the end of the file:
If [$ USER = "oracle"]; then
If [$ SHELL = "/bin/ksh"]; then
Ulimit-p 16384
Ulimit-n 65536
Else
Ulimit-u 16384-n 65536
Fi
Fi
6.5 Modify/opt/oracle/. bash_profile
Before modifying/opt/oracle/. bash_profile, you must perform the following operations:
① Create user groups and users as owners of software installation and support groups
Groupadd oinstall
Groupadd dba
Useradd-g oinstall-G dbaoracleThese two G types can all be in lower case.
[Root @ Pet/] #Useradd-g oinstall-G dba-d/home/oracle(Add oracle users to the dba sub-group in the oinstall group to the/Oracle_11g/oracle directory)
The root directory is/Oracle_11g/oracle, and the main group is the oinstall sub-group is dba
[Root @ Pet/] #Passwd oracle(SET Password)
② Create a software installation directory
Mkdir-p/Oracle_11g/oracle(-P: Make sure that the directory name exists. If it does not exist, create one)
[Root @ Pet/] #Chown-R oracle: oinstall/home/oracle
[Root @ Pet/] #Chown-R oracle: oinstall/home/oracle/app
7. Upload the installation files linux_11gr2_database_1of2.zipand linux_11gr2_databasesilicate f2.zip to the/home/oracle directory in RedhatEnterprise Linux 6.1.
[Root @ Pet ~] #Cd/home/oracle
Run the following command to decompress the two packages:
[Root @ Pet Oracle_11g] #Unzip linux_11gR2_database_1of2.zip
[Root @ Pet Oracle_11g] #Unzip linux_11gr2_database204 f2.zip
[Root @ Pet/] #Chown-R oracle: oinstall/home/oracle/database
[Root @ Pet/] #Chmod-R 755/home/oracle/
R here should be capitalized.
③ Switch to the oracle user
Su-oracle
Passwd: Enter the oracle Password
Vi. bash_profile
Add and modify the following content to the file:
ORACLE_BASE = (the upper-level directory of the oracle Installation Directory)
ORACLE_HOME = $ ORACLE_BASE/oracle
ORACLE_SID = (Instance name)
PATH = $ ORACLE_HOME/bin: $ PATH: $ HOME/bin
LD_LIBRARY_PATH = $ ORACLE_HOME/lib:/usr/lib
LANG = C-Set this parameter to avoid garbled Characters During the installation process, but the terminal with Oracle permission will be in English. If you want to use Chinese characters, you can remove this parameter, but in some systems, it will be garbled.
Export ORACLE_BASE ORACLE_HOMEORACLE_SID PATH LD_LIBRARY_PATH LANG
Save and exit, and then execute the following command to make it take effect
[Oracle @ localhost ~] $../Bash_profile
Open another terminal window as root
-- This step is critical. If you do not run this step, the graph-based installation interface cannot be started when the oracle user runs #./runInstaller.
# Export DISPLAY =: 0.0
# Xhost +
# Xhost + localhost
# Su-oracle
Cd database/
./RunInstaller
7: start installing Oracle 11gR2
Use the oracle user to enter the graphical interface, open the terminal, go to the database directory, and enter./RunInstallerStart the graphic installation interface.
Remove the hook in the figure and click Next.
Click Yes.
Select to install only the database software.
Select single database installation.
Select the Simplified Chinese language.
Select Enterprise Edition.
Select the Oracle Installation Directory, which corresponds to ORACLE_BASE = (the upper-level directory of the oracle Installation Directory) and ORACLE_HOME = $ ORACLE_BASE/oracle in the/oracle/. bash_profile file.
Then click Next.
Click Next.
Select ignore all, and then click Next.
Click Finish to enter the installation status.
This error occurs because the package is missing: rpm-q mpfr pplclog-ppl cpp finds the four packages, installs them separately, and then clicks "Retry ".
If the problem persists, run the command in the following order:
# Rpm-ivh glibc-common-2.12-1.25.el6.x86_64.rpm
# Rpm-ivhkernel-headers-2.6.32-131.0.15.el6.x86_64.rpm
# Rpm-ivhlibgcc-4.4.5-6.el6.x86_64.rpm
# Rpm-ivhglibc-2.12-1.25.el6.x86_64.rpm
# Rpm-ivhlibgomp-4.4.5-6.el6.x86_64.rpm
# Rpm-ivhnscd-2.12-1.25.el6.x86_64.rpm
# Rpm-ivhglibc-headers-2.12-1.25.el6.x86_64.rpm
# Rpm-ivhglibc-devel-2.12-1.25.el6.x86_64.rpm
# Rpm-ivhmpfr-2.4.1-6.el6.x86_64.rpm
# Rpm-ivhppl-0.10.2-11.el6.x86_64.rpm
# Rpm-ivhcloog-ppl-0.15.7-1.2.el6.x86_64.rpm
# Rpm-ivhcpp-4.4.5-6.el6.x86_64.rpm
# Rpm-ivhgcc-4.4.5-6.el6.x86_64.rpm
Note: The gcc installation sequence is correct.
# Rpm-ivhlibstdc ++-4.4.5-6. el6.x86 _ 64.rpm
# Rpm-ivhlibstdc ++ devel-4.4.5-6.el6.x86_64.rpm
# Rpm-ivhgcc-c ++-4.4.5-6. el6.x86 _ 64.rpm
Note: The above is the installation of gcc-c ++
Reference: http://blog.csdn.net/paullmq/article/details/8568604
There are two scripts that need to be run by the root user after installation. Open XShell and run the two scripts as the root user.
[Root @ Pet ~] #/OraInventory/orainstRoot. sh
[Root @ Pet ~] #/Oracle_11g/oracle/root. sh
After the script is run, the Oracle 11g R2 database software has been installed.
After installation, click Close to exit the installation page.
8: Set the listener
Use in a terminalNetcaCommand to start creating a listener.
Set the listener name.
The following is the same as the operation on windows...
9. Create a database instance
Use in a terminalDbcaCommand to start creating a database instance.
Set the Instance name. The instance name must correspond to ORACLE_SID = (Instance name) in the/oracle/. bash_profile file.
The operation on windows is the same...
So far, the installation of Oracle 11g R2 under Redhat EnterpriseLinux 6.1 has been completed.
After the configuration is complete, run the following command to start the EM console:
[Oracle @ oracle11g ~] $ Emctl start dbconsole
Http: // localhost: 1158/em/
Access the web Enterprise Management page
How can I install the oracle 11g database in linux redhat5? Thank you very much for your help.
Tutorials are available online!
I really think it's amazing!
An error occurred when calling the target nmo of/sysman/lib/ins_emagentmk when installing oracle 11g r2 in linux redhat 54.
Have you installed it according to the official oracle documents?
Some Dependent packages must be installed in a version that is too high.