Centos5.5 install oracle11g

Source: Internet
Author: User

Centos5.5 install oracle11g
1. Install vmwarevm
2. install linux in a Virtual Environment
3. download the latest oracle installation file from the official website.
Http://www.oracle.com/index.html

Upload the following two files to the centos operating system (the tool: CRT requires yum install lrzsz to install this command before uploading)
Linux_11gR2_database_1of2.zip
Linux_11gr2_databasesilicate f2.zip


4. After the upload is complete, run the unzip command to decompress the two files you just uploaded. The command format is as follows:
Unzip file name (for example, unzip linux_11gR2_database_1of2.zip)
(Note: you only need to put the two installation files in the same directory and decompress them once. After decompression, the two installation files are automatically decompressed to a folder named database)


5. Run the following command to install the required package


Yum install-y binutils *
Yum install-y compat-libstdc *
Yum install-y elfutils-libelf *
Yum install-y gcc *
Yum install-y glibc *
Yum install-y ksh *
Yum install-y libaio *
Yum install-y libgcc *
Yum install-y libstdc *
Yum install-y make *
Yum install-y sysstat *
Yum install-y numactl *
Yum install libXp *-y
Yum install-y glibc-kernheaders
Yum install libXext. i386


Three more packages may be used and cannot be downloaded using yum.
UnixODBC-2.2.11-7.1-i386_x64
UnixODBC-2.2.11-7.1_devel
Pdksh-5.2.14 (32-bit and 64-bit packages)


After downloading the file and uploading it to linux, run the following command to install the file:
Rpm-ivh *. rpm -- nodeps -- force -- install the package uploaded to the System


* ** Rm-f/var/run/yum. pid. For example, if yum shows that it is in use, run this command to delete it, re-run yum, or wait for a while.






6. Create a negative group and an oracle installation path for the master Group
Groupadd oinstall
Groupadd dba
Mkdir-p/u01/oracle


Add an oracle user. The root directory is/u01/oracle. The master group is the dba group used by oinstall.
Useradd-g oinstall-G dba-d/u01/oracle


Copy the following three files to the oracle installation path:
Cp/etc/skel/. bash_profile/u01/oracle
Cp/etc/skel/. bashrc/u01/oracle
Cp/etc/skel/. bash_logout/u01/oracle


Set Password 123456 for oracle users
Passwd oracle
Modify the group and operator of the u01 file:
Chown-R oracle: oinstall u01


Check whether nobody exists. id nobody
It exists by default. If it does not exist #/usr/sbin/useradd-g nobody
7. Add the following three codes to the following three files:
Vi/etc/sysctl. conf


Fs. aio-max-nr = 1048576
Fs. file-max = 6815744
Kernel. shmall = 2097152
Kernel. shmmax = 536870912
Kernel. shmmni = 4096
Kernel. sem = 250 32000 100 128
Net. ipv4.ip _ local_port_range = 9000 65500
Net. core. rmem_default = 262144
Net. core. rmem_max = 4194304
Net. core. wmem_default = 262144
Net. core. wmem_max = 1048586
-------------
Vi/etc/security/limits. conf


Oracle soft nproc 2047
Hard nproc 16384
Oracle soft nofile 1024
Oracle hard nofile 65536
------------
Vi/etc/pam. d/login


Session required pam_limits.so
8. Set oracle user environment variables


Su-oracle


Pwd
Ls-la


---------------
Vi. bash_profile


ORACLE_BASE =/u01
ORACLE_HOME = $ ORACLE_BASE/oracle
ORACLE_SID = wilson
PATH = $ ORACLE_HOME/bin: $ PATH: $ HOME/bin


Export ORACLE_BASE ORACLE_HOME ORACLE_SID PATH
9. Copy the extracted oracle Installation File database to the installation path u01 and modify the database operation permissions:
Mv database/u01/


Cd/u01
Ls-l


Chown-R oracle: oinstall database/




10. Use the oracle user logon graphical interface for installation (remember !! If the installation package is incomplete, do not ignore it. Otherwise, problems may occur)


Cd/u01/database
./RunInstaller


Yum groupinstall "KDE (K Desktop Environment )"


Yum install tigervnc-server Download vnc command
Xhost + failed to check display color run this command as root


Vi/etc/sysconfig/i18n Language

LANG = "en_US.UTF-8"


The options in the installation process are as follows ):
Installation Optiong
Install database software only


Grid Options
Single instance database installation


Product ages
English


Database Edition
Enterprise Edition (3.95)


Installation Location
Oracle Base:/u01
Software Loacation:/u01/oracle


Tip: yes


Create Inventory
Mkdir/oraInventory


Chown-R oracle: oinstall oraInventory


Operating System Groups
Next


Prerequis ite Checks
Ignore All


Summary
Finish


Install Product
2 scripts are prompted after installation.


/OraInventory/orainstRoot. sh
/U01/oracle/root. sh
Press enter directly. The default value is OK.


Finish
The installation of Oracle Database was successful




11. The software is installed above, the database is not created, and the Listener is configured.


Netca
Always default next step, and Finish


Ps-ef: Check whether the Listener is configured successfully.


Dbca
Run "Next" until the Global Database Name and SID are all input wilson (note: the Database Name can be customized)


Select User the Same... All Accounts


Password 123456




Select Sample Schemas


Memory allocation. The default value is enough.
Character Sets select Use Unicode (AL32UTF8)


Next until the end.


A Confirmation is displayed. Click OK and install it automatically.


Install to/u01/oradata/wilson

12. Then, you can modify vi/etc/inittab so that when centos5.5 is started, you can directly enter the character interface without entering the graphic interface.


Id: 5: initdefault: changed to id: 3: initdefault:


Save and exit (esc,: wq), and then restart the system


13. log on remotely with an oracle user and then


$ Sqlplus/nolog


SQL> conn/as sysdba


Connected to an idle instance.
Error


SQL> startup


[Oracle @ localhost ~] $ Sqlplus/nolog


SQL * Plus: Release 11.2.0.1.0 Production on Fri Jun 25 15:05:54 2010


Copyright (c) 1982,200 9, Oracle. All rights reserved.


SQL> conn/as sysdba
Connected.
SQL> create table testUser (id integer, name char (10 ));


Table created.


SQL> insert into testUser values (0, 'jack ');


1 row created.


SQL> commit;


Commit complete.


SQL> select * from testUser;


ID NAME
--------------------
0 Jack


Close Database
SQL> shutdown immediate


SQL> quit

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.