DBA installation of Oracle Database11g database graphic tutorial in Linux, dbadatabase11g

Source: Internet
Author: User

DBA installation of Oracle Database11g database graphic tutorial in Linux, dbadatabase11g

Oracle11g is a common version. It is a pity that it failed to try to install Oracle 12c.
The following documents are prepared:

1. Connect to the Installation File

Http://download.oracle.com/otn/linux/oracle11g/R2/linux.x64_11gR2_database_1of2.zip? AuthParam = 1407205871_20179949f8bacf912168611692563a693
Http://download.oracle.com/otn/linux/oracle11g/R2/linux.x64_11gR2_database_2of2.zip? AuthParam = 1407205876_ec394cc017d1815a8cce7cc31e0f0bb9

2. The procedure is as follows:

Step 1. Download the Installation File
Step 2. Configure the initialization environment before installation
Step3. install Oracle Installer-Database
Step 4. Configure Oracle Database-Configuration
Step 5. Configure Listener
Step 6. Start the database and test whether the database is successful.

3. OEM Installation Considerations

4. Steps for starting a database

Start listening./lsnrctl start
Start library sqplus> start up
 
Ii. Configure the initialization environment before installation

1. Create an oracle user in linux and log on to linux as the root user in the Management Group. Run the following command:

#/Usr/sbin/groupadd dba
#/Usr/sbin/groupadd Partition
#/Usr/sbin/groupadd oinstall
# Useradd oracle
#/Usr/sbin/usermod-g oinstall-G dba oracle (dba is the Management Group)
#/Usr/sbin/useradd-g oinstall-G dba oracle
# Passwd oracle

2. Create an installation directory in advance

# Mkdir-p/opt/oracle/product
# Mkdir-p/opt/oracle/product/11.2.0/db_home1
# Mkdir-p/opt/oraInventory
# Mkdir-p/opt/oracle/oradata
# Mkdir-p/var/opt/oracle

3. Set the group and permissions of the directory owner

# Chown-R oracle. oinstall/opt/oracle
# Chown-R oracle. oinstall/opt/oracle/oradata
# Chown-R oracle. oinstall/opt/oracle/product/11.2.0/db_home1
# Chown-R oracle. dba/opt/oraInventory
# Chown oracle. dba/var/opt/oracle
# Chmod-R 775/opt/oracle
# Chmod-R 755/var/opt/oracle

4. Set oracle environment variables to add the following to the file:

# Su-oracle
# Vi/home/oracle/. bash_profile
 
Export ORACLE_BASE =/opt/oracle
Export ORACLE_HOME = $ ORACLE_BASE/product/11.2.0/db_home1
Export ORACLE_SID = PROD
Export ORACLE_OWNER = oracle
Export ORACLE_TERM = vt100
Export PATH = PATH: ORACLE_HOME/bin: $ HOME/bin
Export PATH = ORACLEHOME/bin: ORACLE_HOME/Apache/bin: $ PATH
LD_LIBRARY_PATH = $ ORACLE_HOME/lib:/usr/local/lib
Export LD_LIBRARY_PATH
CLASSPATH = ORACLEHOME/JRE: ORACLE_HOME/jlib: $ ORACLE_HOME/rdbms/jlib
CLASSPATH = CLASSPATH: ORACLE_HOME/network/jlib
Export CLASSPATH
PATH = $ PATH:/usr/sbin; export PATH
PATH = $ PATH:/usr/bin; export PATH
 
$ Source/home/oracle/. bash_profile
 
Iii. Install Oracle Installer-Database

Use the Oracle account to upload the oracle Installation File to the server and decompress it.

Cd/opt/oracle/database
./RunInstaller

1. Configure Security Updates

2. Installation Options

3. grid options

4. Installation type

5. Typical Installation

6. Prerequisite check

7. Summary

8. Install the product

9. Run the following two scripts after installing the SDK as Root:

4. Configure Oracle Database-Configuration

1.1 run dbca script to configure the database

Cd/opt/oracle/product/11.2.0/db_home1/bin

./Dbca

2.1 Create a database

2.2 Database Templates

2.3 Database identification

2.4 Management Options

2.5 Database Credentiais

2.6 Database File Locations

2.7 Database Content

2.8 Initilization Paramters

2.9 Creation Options

5. Configure Listener

1.1 run netca script to configure database listening

Cd/opt/oracle/product/11.2.0/db_home1/bin

./Netca

2. Configure Listener

2.1 Listener Configuration

2.2 Create an Listener

2.3 Confirm Port Number

3. Configure the server Local Net Service Name Configuration


3.1 Add Local Net Service Name Configuration

3.2 Service Name

3.3 TCP and Host Name

6. Start the Database Listener and the database for testing.

1. Start database listening

Cd/opt/oracle/product/11.2.0/db_home1/bin
./Lsnrctl start

2. Start the database

Sqlplus '/as sysdba'
SQL> startup

3. View processes after startup


4.1. Exception (failed to modify the configuration file when the Database Listener is started)

/Etc/selinux/config
./Lsnrctl error while loading shared libaries libclntsh. so.11.1

4.2. Exception (failed to modify the configuration file when the Database Listener is started)

Exception:

Lsnrctl message1070

Solution:

Check whether the environment variable $ ORACLE_HOME in/home/. bash_profile is correct.

4.3. Exception (SQLPLUS cannot be used)

Exception

Sqlplus ora-01034

A ORA-01034: ORACLE not avaiable
ORA-27101: shared memory realm does not exist
Process ID: 0
Session ID: 0 Serial Number: 0

Solution

Log on to the database through sysdba and then log on to the database as a common user.

4.4 The installation package is missing during verification

Yum install unixODBC-devel-2.2.11
Yum install unixODBC-2.2.11
Yum install sysstat-5.0.5
Yum install libaio-devel-0.3.105
Yum install liaio-devel-0.3.105
Yum install compat-libstdc ++-33-3.2.3
Yum install libaio-devel
Yum install pdksh
Yum install elfutils-libelf-devel
Yum install sysstat

4.5 During verification, OS Kernel Parmaters

Modify the/etc/sysctl. conf file and activate it with sysctl-p.


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

5 Oracle Yum install yi

Step 1. Check the network environment to ensure smooth network connection
[Root @ gavinsit] # cat/etc/issue
[Root @ gavinsit] # ping www.baidu.com


Step 2. Check whether yum is installed
[Root @ gavinsit] # rpm-qa | grep yum


Step 3. Switch to the/etc/yum. repos. d/directory/
[Root @ gavinsit] # cd/etc/yum. repos. d/


Step 4. Obtain and modify the configuration file
[Root @ gavinsit] # yum. repos. d] # wget http://public-yum.oracle.com/public-yum-ol6.repo


Step 5. Use yum to install the oracle-rdbms-server-11gR2-preinstall package
[Root @ gavinsit] # yum install oracle-rdbms-server-11gR2-preinstall


How to install an oracle database in linux

Before installing the oracle database on linux, you must set system parameters and create related users and directories. If all the work is done, garbled characters are displayed on the runinstaller interface. You can set the linux language environment to English.
Export LANG = C
./Runinstaller
Good luck.

The Oracle database is successfully installed in Linux, but the prompt that the command does not exist when you type sqlplus on the Character interface. How can this problem be solved?

You put
PATH =/usr/sbin: $ PATH;

Export PATH

PATH = $ ORACLE_HOME/bin: $ PATH;

Export PATH

Merge a sentence
Export PATH =/usr/sbin: $ PATH: $ ORACLE_HOME/bin

(After setting, remember to make the variable take effect, log out or restart, or execute source. bash_profile)
Set to see if the variable is correct

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.