A couple of systems have finally succeeded with CentOS installation Oralce, and here I've also consulted a lot of information on the web as well as Oracle's official documentation
1, download Oracle, I choose here is the 11GR2 version, download down there are two files, using the unzip command extracted to the same directory
2. Establish an Oracle installation directory on disk
# This is the installation base directory for Oracle # This is a directory of some file logs
3. Create Oracle Users and Groups
Here's why you want to set up users and groups, because the database holds some important data, not who you want to access, you must manage the user's permissions, only the user joins the current group, and gives them permission to operate the database.
# Create a user group Oinstall # Create user group DBA# Create user Oracle and join Oinstall and DBA user groups # Set the user's login password for Oracle, enter the password two times as prompted # Set the directory owner to be an Oracle user for the Oinstall user group -R Oracle:oinstall/oracle/orainventory
4. Modify the operating system name
# Edit
Modified to: redhat-7
I'm not sure here either, because Oracle's officially certified system is redhat, Oracle Linux, SuSE, and so on, and finally CentOS is chosen to install Oracle, and because CentOS is a redhat release, I think compatibility is still possible.
5. Modify Kernel parameters
This change is primarily due to the fact that there is a minimum requirement for Oracle Database installation configuration in Oracle's official documentation, so you need to modify
Vi/etc/sysctl.conf#editing,#Add the following code at the endnet.ipv4.icmp_echo_ignore_broadcasts= 1Net.ipv4.conf.all.rp_filter= 1Fs.file-max = 6815744#set the maximum number of open filesFs.aio-MAX-NR = 1048576Kernel.shmall= 2097152#Total shared memory, 8G memory settings: 2097152*4k/1024/1024Kernel.shmmax= 2147483648#Maximum segment size for shared memoryKernel.shmmni= 4096#maximum number of shared memory side of the entire systemKernel.sem= 250 32000 100 128Net.ipv4.ip_local_port_range= 9000 65500#IPv4 port range available for useNet.core.rmem_default= 262144Net.core.rmem_max= 4194304Net.core.wmem_default= 262144Net.core.wmem_max= 1048576
After you save the exit, do the following to make the configuration effective
# make configuration effective immediately
6. Set limits on Oracle users
# Add the following code at the end 2047163841024x76865536
Note: Suddenly think of, join if VI Edit file content more, you can enter the command mode input "$" to jump to the end of the text.
7, configure the user's environment variables
vi/home/oracle/. Bash_profile#Add the following code at the endExport Oracle_base=/data/oracle#Oracle Database installation directoryExport Oracle_home= $ORACLE _base/product/11.2.0/db_1#Oracle Database pathExport Oracle_sid=orcl#Oracle Startup DB Instance nameExport Oracle_term=xterm#xterm window mode installationExport PATH= $ORACLE _home/bin:/usr/sbin: $PATH#adding system environment variablesExport Ld_library_path= $ORACLE _home/lib:/lib:/usr/lib#adding system environment variablesExport#prevents garbled installation processExport Nls_lang=american_america. Zhs16gbk#Set the Oracle client character set and must be consistent with the set of character sets at Oracle installation, such as: ZHS16GBK, otherwise the data import and export in Chinese garbled problem
After you save the exit, enter the following command to make the configuration effective
# make settings effective immediately
8. Turn off SELinux
vi/etc/selinux/# edit config file ## comment out selinuxtype=targeted SELINUX # Increase
9. Configure the Firewall
Since I installed the system is the CentOS 7 live version, so there are a lot of things no, I added the following code, I did not find the iptables restart command, and then restarted the system, anyway, there is no impact, I guess I have no firewall in this version. The online code is as follows:
# Edit the firewall configuration file and add the following -A rh-firewall-1-input-m state–state new-m tcp-p tcp–dport 1521-J ACCEPT# Restart the firewall for configuration to take effect
10, check the dependency relationship
Here I checked the two steps, first in accordance with the official document check again, in the official document I refer to redhat-7 all the necessary things, as follows:
Binutils-2.23.52.0.1-12. el7.x86_64 Compat-libcap1-1.10-3. el7.x86_64 gcc-4.8.2-3. el7.x86_64 gcc-c++-4.8.2-3. el7.x86_64 glibc-2.17-36. el7.i686 glibc-2.17-36. el7.x86_64 glibc-devel-2.17-36. el7.i686 glibc-devel-2.17-36. el7.x86_64 Kshlibaio-0.3.109-9. el7.i686 Libaio-0.3.109-9. el7.x86_64 Libaio-devel-0.3.109-9. el7.i686 Libaio-devel-0.3.109-9. el7.x86_64 LIBGCC-4.8.2-3. el7.i686 LIBGCC-4.8.2-3. el7.x86_64 LIBSTDC++-4.8.2-3. el7.i686 LIBSTDC++-4.8.2-3. el7.x86_64 LIBSTDC++-devel-4.8.2-3. el7.i686 LIBSTDC++-devel-4.8.2-3. el7.x86_64 Libxi-1.7.2-1. el7.i686 Libxi-1.7.2-1. el7.x86_64 libxtst-1.2.2-1. el7.i686 libxtst-1.2.2-1. el7.x86_64 Make-3.82-19. el7.x86_64 Sysstat-10.1.5-1.el7.x86_64
Check the use of the following command, direct online installation, if installed will definitely prompt, otherwise installed
# take the first packet as an example
Then by the way I refer to an article to detect the relationship between the method has also been used, this command has a wildcard, installed more than the package, the radiation range more wide, to ensure foolproof.
Yum install gcc* gcc-* gcc-c++-* glibc-devel-* glibc-headers-* compat-libstdc* libstdc* elfutils-libelf-devel* libaio-devel* sysstat* unixodbc-* pdksh-*
This has a pdksh may prompt without this package, but it doesn't matter, at the first step has been detected installed Ksh
11, the next installation of graphical interface, the first to switch to the top created by the user Oracle under the best logout after landing.
12, CD into the top of the extracted Oracle installation file directory in database
Note: Because the owner of the database above is root,oracle, you can use the following command to make the owner of this folder Oracle.
# switch to root user Chown-r Oracle/.../database
13, run the following command to start the installation interface
# set the encoding to prevent garbled graphics interface ./runinstaller
Note: This may be a reminder of how the display failed, and what I overlooked, seemingly unaffected
Next step into the installation step, very simple, steps to be able to, select part by default can be
In the next installation, you may be prompted to ignore the error and other emails to continue,
Then there may be host name and IP not mapped using the following command to modify the hosts file can be
vi/etc/hosts# Enter and add your hostname to the 127.0.0.1, note the hostname, not your username
14, I also encountered two other errors in the installation process is about makefile, and a warning, but I ignored, after the installation, there is no problem, put the error code here, to be resolved later
Install Makfile Error
Info:exception Thrown fromaction:makeexception name:makefileexceptionexception string:errorinchInvoking target'Install'of makefile'/oracle/oraclebase/product/11.2.0/db_1/ctx/lib/ins_ctx.mk'. See'/oracle/orainventory/logs/installactions2014-12-22_05-24-27pm.log' fordetails. Exception Severity:1info:calling Action unixActions10.2.0.3.0Make registeronly=false Installmakepath=/usr/bin/Make installmakefilename=/oracle/oraclebase/product/11.2.0/db_1/racg/lib/ins_has.mk Installtarget=Racg_install Undomakefilename=installarguments= oracle_home=/oracle/oraclebase/product/11.2.0/db_1 LogFile=/oracle/oraclebase/product/11.2.0/db_1/install/Make.log Undotarget=progmsg=linking RACG executablesinfo:linking RACG executablesinfo:linking RACG executablesinfo:the output of this make Ope Ration isAlso available at:'/oracle/oraclebase/product/11.2.0/db_1/install/make.log'INFO:
Agent NMHS Makefile Error
Info:exception thrown fromaction:makeexception name:makefileexceptionexception string:errorinchInvoking target'Agent NMHS'of makefile'/oracle/oraclebase/product/11.2.0/db_1/sysman/lib/ins_emagent.mk'. See'/oracle/orainventory/logs/installactions2014-12-22_05-24-27pm.log' fordetails. Exception Severity:1info:calling Action unixActions10.2.0.3.0Make registeronly=false Installmakepath=/usr/bin/Make installmakefilename=/oracle/oraclebase/product/11.2.0/db_1/rdbms/lib/ins_rdbms.mk Installtarget=ALL_NO_ORCL Undomakefilename=installarguments= oracle_home=/oracle/oraclebase/product/11.2.0/db_1 LogFile=/oracle/oraclebase/product/11.2.0/db_1/install/Make.log Undotarget=progmsg=linking RDBMS executablesinfo:linking RDBMS executablesinfo:linking RDBMS executablesinfo:the output of this make Operation isAlso available at:'/oracle/oraclebase/product/11.2.0/db_1/install/make.log'INFO:
[Oracle]centos 7 Installing Oracle