search
HomeDatabaseMysql TutorialRHEL6 ASM方式安装Oracle 11g R2

RHEL6 ASM方式安装Oracle 11g R2教程目录: 一、安装前的准备二、安装网格基础架构三、安装数据库软件四、创建监听五、创建数据库

RHEL6 ASM方式安装Oracle 11g R2教程目录:

一、安装前的准备
二、安装网格基础架构
三、安装数据库软件
四、创建监听
五、创建数据库实例

一、安装前的准备

1.1 确定操作系统环境


# cat /etc/RedHat-release

Red Hat Enterprise Linux Server release 6.2 (Santiago)

Kernel \r on an \m

# free -m

            total      used      free    shared    buffers    cached

Mem:          2008      1309        699          0        62        875

-/+ buffers/cache:        371      1637

Swap:          509          0        509

# fdisk -l

Disk /dev/sda: 32.2 GB, 32212254720 bytes

255 heads, 63 sectors/track, 3916 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

  Device Boot      Start        End      Blocks  Id  System

/dev/sda1  *          1          5      40131  83  Linux

/dev/sda2              6        2172    17406427+  8e  Linux LVM

/dev/sda3            2173        2237      522112+  82  Linux swap / Solaris

/dev/sda4            2238        3916    13486567+  5  Extended

/dev/sda5            2238        2542    2449881  83  Linux

/dev/sda6            2543        2847    2449881  83  Linux

/dev/sda7            2848        3152    2449881  83  Linux

/dev/sda8            3153        3457    2449881  83  Linux

/dev/sda9            3458        3765    3077120  83  Linux

# df -h

Filesystem            Size  Used Avail Use% Mounted on

/dev/mapper/Vol0-root

                      7.6G  3.2G  4.1G  41% /

/dev/mapper/Vol0-oracle

                      8.6G  101M  747M  1% /u01

/dev/sda1            38M  16M  21M  42% /boot

tmpfs                1005M    0 1005M  0% /dev/shm

如果没有满足1G内存的要求,虽然对安装的影响也不是很大,但会在安装正式开始前收到一个先决条件检查不通过的“友情警告”信息。

Swap交换区大小与物理内存大小的比例关系的一般规律如下:

这边仅用于测试,故只分配了512M的swap空间,可以忽略警告信息。

因为Oracle 11gR2中,ASM必须单独安装Grid Infrastructure,再加上数据库软件的安装,所需要的磁盘大小一般不超过8G,所以应保证/u01目录所在的文件系统可用空间在8G以上即可。

数据库文件将采用ASM方式存储,这里用了4个2.5G的raw分区用于活动的数据库文件+DATA的ASM磁盘组,1个3G的raw分区用于闪回恢复区+FRA的ASM磁盘组

因为在安装过程中,有一部分数据会写入到“/tmp”目录下,建议该目录所在的文件系统空间大小不要小于1G

1.2 网络参数的配置

# cat /etc/sysconfig/network
NETWORKING=yes
NETWORKING_IPV6=no
HOSTNAME=ora11g.vnimos.org
# service NetworkManager stop
# chkconfig NetworkManager off
# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
BOOTPROTO=static
HWADDR=00:0C:29:32:C3:9C
IPADDR=192.168.0.90
NETMASK=255.255.255.0
ONBOOT=yes
# cat /etc/hosts
127.0.0.1      localhost.localdomain  localhost
192.168.0.90    ora11g.vnimos.org      ora11g
//必须至少包含以上两行、三列(IP 长名 短名),否则安装的时候将会出现”Oracle Net Configuration Assistant failed”的错误

1.3 oracle用户环境变量、系统参数的配置


# groupadd oinstall
# groupadd dba
# useradd -g oinstall -G dba,root oracle
# echo "oracle" | passwd --stdin oracle
# mkdir -p /u01/app/{oracle,oraInventory}
# chown oracle:oinstall /u01/app/oracle
# chown oracle:oinstall /u01/app/oraInventory
# vi /home/oracle/.bash_profile
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1
export ORACLE_SID=orcl
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib:/usr/X11R6/lib
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ORACLE_HOME/rdbms/lib
export CLASS_PATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib
export CLASS_PATH=$CLASS_PATH:$ORACLE_HOME/rdbms/jlib
export CLASS_PATH=$CLASS_PATH:$ORACLE_HOME/network/jlib
export TNS_ADMIN=$ORACLE_HOME/network/admin
export NLS_LANG=american_america.AL32UTF8
export ORACLE_TERM=xterm
export EDITOR=vi
export PATH=$ORACLE_HOME/bin:$PATH
export LANG=en_US
# vi /etc/sysctl.conf
kernel.shmmax = 1073741824                    //物理内存的一半(字节)
# sysctl -p

1.4 绑定裸设备(用于创建ASM磁盘组,,更详细的内容请参考:)

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
What Are the Limitations of Using Views in MySQL?What Are the Limitations of Using Views in MySQL?May 14, 2025 am 12:10 AM

MySQLviewshavelimitations:1)Theydon'tsupportallSQLoperations,restrictingdatamanipulationthroughviewswithjoinsorsubqueries.2)Theycanimpactperformance,especiallywithcomplexqueriesorlargedatasets.3)Viewsdon'tstoredata,potentiallyleadingtooutdatedinforma

Securing Your MySQL Database: Adding Users and Granting PrivilegesSecuring Your MySQL Database: Adding Users and Granting PrivilegesMay 14, 2025 am 12:09 AM

ProperusermanagementinMySQLiscrucialforenhancingsecurityandensuringefficientdatabaseoperation.1)UseCREATEUSERtoaddusers,specifyingconnectionsourcewith@'localhost'or@'%'.2)GrantspecificprivilegeswithGRANT,usingleastprivilegeprincipletominimizerisks.3)

What Factors Influence the Number of Triggers I Can Use in MySQL?What Factors Influence the Number of Triggers I Can Use in MySQL?May 14, 2025 am 12:08 AM

MySQLdoesn'timposeahardlimitontriggers,butpracticalfactorsdeterminetheireffectiveuse:1)Serverconfigurationimpactstriggermanagement;2)Complextriggersincreasesystemload;3)Largertablesslowtriggerperformance;4)Highconcurrencycancausetriggercontention;5)M

MySQL: Is it safe to store BLOB?MySQL: Is it safe to store BLOB?May 14, 2025 am 12:07 AM

Yes,it'ssafetostoreBLOBdatainMySQL,butconsiderthesefactors:1)StorageSpace:BLOBscanconsumesignificantspace,potentiallyincreasingcostsandslowingperformance.2)Performance:LargerrowsizesduetoBLOBsmayslowdownqueries.3)BackupandRecovery:Theseprocessescanbe

MySQL: Adding a user through a PHP web interfaceMySQL: Adding a user through a PHP web interfaceMay 14, 2025 am 12:04 AM

Adding MySQL users through the PHP web interface can use MySQLi extensions. The steps are as follows: 1. Connect to the MySQL database and use the MySQLi extension. 2. Create a user, use the CREATEUSER statement, and use the PASSWORD() function to encrypt the password. 3. Prevent SQL injection and use the mysqli_real_escape_string() function to process user input. 4. Assign permissions to new users and use the GRANT statement.

MySQL: BLOB and other no-sql storage, what are the differences?MySQL: BLOB and other no-sql storage, what are the differences?May 13, 2025 am 12:14 AM

MySQL'sBLOBissuitableforstoringbinarydatawithinarelationaldatabase,whileNoSQLoptionslikeMongoDB,Redis,andCassandraofferflexible,scalablesolutionsforunstructureddata.BLOBissimplerbutcanslowdownperformancewithlargedata;NoSQLprovidesbetterscalabilityand

MySQL Add User: Syntax, Options, and Security Best PracticesMySQL Add User: Syntax, Options, and Security Best PracticesMay 13, 2025 am 12:12 AM

ToaddauserinMySQL,use:CREATEUSER'username'@'host'IDENTIFIEDBY'password';Here'showtodoitsecurely:1)Choosethehostcarefullytocontrolaccess.2)SetresourcelimitswithoptionslikeMAX_QUERIES_PER_HOUR.3)Usestrong,uniquepasswords.4)EnforceSSL/TLSconnectionswith

MySQL: How to avoid String Data Types common mistakes?MySQL: How to avoid String Data Types common mistakes?May 13, 2025 am 12:09 AM

ToavoidcommonmistakeswithstringdatatypesinMySQL,understandstringtypenuances,choosetherighttype,andmanageencodingandcollationsettingseffectively.1)UseCHARforfixed-lengthstrings,VARCHARforvariable-length,andTEXT/BLOBforlargerdata.2)Setcorrectcharacters

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

DVWA

DVWA

Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools