Home Database Mysql Tutorial RedHat 5.5下安装Oracle 10g+RAC

RedHat 5.5下安装Oracle 10g+RAC

Jun 07, 2016 pm 04:43 PM

成本的相对廉价,技术的成熟,功能的强大此方案将越来越受中小企业的青睐。 一.实验前准备 虚拟机版本:VMware server1.0.6 Linu

成本的相对廉价,技术的成熟,功能的强大此方案将越来越受中小企业的青睐。

一.实验前准备

虚拟机版本:VMware server1.0.6

Linux版本:RedHat 5.5 Enterprise服务器版

Oralce版本:Oracle 10g 10.2.1

Oracle集群软件:Clusterware

VMware Workstation版本在共享磁盘上没有很好的解决办法。VMware server在Windows7安装可能存在一定的驱动问题。本实验是在xp系统上完成,下图给出虚拟机的ip及主机名配置

Node1:主机名rac1

网卡1ip192.168.100.100

网卡2ip192.168.200.100

虚拟ip192.168.2.100

Node2主机名rac2

网卡1ip192.168.100.101

网卡2ip192.168.200.101

虚拟ip192.168.2.101

在CentOS 6.4下安装Oracle 11gR2(x64)

Oracle 11gR2 在VMWare虚拟机中安装步骤

Debian 下 安装 Oracle 11g XE R2

二.虚拟机配置及linux安装

实验利用vware配置虚拟机只需要配置一台即主节点,在虚拟机中的配置如:

硬盘配置:

该配置是一个重点配置,默认配置一个磁盘,大小为20G该磁盘为rac1的服务器磁盘,包括了linux系统的安装及oracle软件的安装都在该磁盘上。

还需要分配其他四块磁盘:2:ocr,3:vote4,5:asm

其大小分别为100M,100M,2G,2G

磁盘分部为:1,SCSI0:02,SCSI1:13,SCSI1:24,SCSI1:35,SCSI1:4且2-5都需要在高级中勾选independent-persisant选项

*硬盘分配的注意点:I/O适配器类型都选择"LSILogin"方式

*所有磁盘类型都选在"SCSI",如果选择IDE类型的磁盘的话,vware只能虚拟出4块,而rac环境是需要5块磁盘来实现。由于是在虚拟机中实现,建议将2-5磁盘配置到其他目录中。

两块在安装clusterware软件的时候要用到,也就是ORACLERAC所必须的ocr以及vote磁盘,表现出来是裸设备方式,还有两块磁盘我们要用来作为共享磁盘存放数据文件,即asm磁盘

网卡配置:

rac环境中需要两块网卡,,当然可以创建地三块网卡和pc交互。便于文件等内容的传输

网卡的类型选择的都为Bridged类型。该类型的网卡在虚拟机就等同一个独立的网卡。可以和主机通信也可以连通互联网。下给出一张配置后的截图:

虚拟机中安装linux

在虚拟机中安装linux,在磁盘分区时将除0:0外的其他磁盘不参与分区,即如下图,只勾选sda选项。在挂盘上随个人喜好。为方便这里只挂了/一个盘

        关于ip的配置,eth0:ip192.168.100.100

                Eth1:ip192.168.200.100

Eth2:选择自动获取

服务的话,建议都选择安装,目前还没有完全了解其中包的关联关系。

disk.locking="false"

diskLib.dataCacheMaxSize="0"

diskLib.dataCacheMaxReadAheadSize="0"

diskLib.DataCacheMinReadAheadSize="0"

diskLib.dataCachePageSize="4096"

diskLib.maxUnsyncedWrites="0"

scsi1:1.deviceType="disk"

scsi1:2.deviceType="disk"

scsi1:3.deviceType="disk"

scsi1:4.deviceType="disk"

三.Linux配置                       

文件配置


1,编辑/etc/hosts文件,添加如下内容:

192.168.100.100rac1

192.168.100.101rac2

192.168.100.200rac1-vip

192.168.100.201rac2-vip

192.168.2.100rac1-priv

192.168.2.101rac2-priv   

2,创建组oinstall,dba,用户oracle

groupaddoinstall

groupadddba

useradd-d/home/oracle-goinstall-Gdbaoracle

如果是非虚机安装,要注意记录下用户和组ID,在其它机器上创建同名组时,务必确认组ID和用户ID与此相同。

设置oracle用户密码(密码也设为oracle)

passwdoracle

3,配置oralce用户的bash_profile文件

exportTMP=/tmp

exportTMPDIR=$TMP

exportORACLE_BASE=/opt/ora10g

exportORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1

exportORACLE_SID=RACDB1

exportORACLE_TERM=xterm

exportPATH=/usr/sbin:$PATH

exportPATH=$ORACLE_HOME/bin:$PATH

exportLD_LIBRARY_PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin

exportCLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib

ulimit-u16384-n65536

umask022

2,创建/opt/ora10g目录,要注意该目录所有者或oracle用户的权限

[root@rac1~]#mkdir/opt/ora10g

由于该目录主要由oracle用户操作,因此我们将其所有者改为oracle

[root@rac1~]#chownoracle.oinstall/opt/ora10g

3,配置内核参数

[root@rac1~]#vi/etc/sysctl.conf

增加或修改下列内容

kernel.shmmni=4096

kernel.sem=25032000100128

fs.file-max=65536

net.ipv4.ip_local_port_range=102465000

net.core.rmem_default=1048576

net.core.rmem_max=1048576

net.core.wmem_default=262144

net.core.wmem_max=262144

[root@rac1~]#sysctl-p

让设置生效

4,提高Oracle用户的shell限制

设置oracle使用的文件数权限

vi/etc/security/limits.conf

增加下列内容

oraclesoftnproc2047

oraclehardnproc16384

oraclesoftnofile1024

oraclehardnofile65536

修改安全限制

vi/etc/pam.d/login

增加:

sessionrequired/lib/security/pam_limits.so

配置Hangcheck计时器

vi/etc/rc.local

增加:

modprobehangcheck-timerhangcheck-tick=30hangcheck_margin=180

更多详情见请继续阅读下一页的精彩内容:

linux

Statement of this Website
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

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 Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

When might a full table scan be faster than using an index in MySQL? When might a full table scan be faster than using an index in MySQL? Apr 09, 2025 am 12:05 AM

Full table scanning may be faster in MySQL than using indexes. Specific cases include: 1) the data volume is small; 2) when the query returns a large amount of data; 3) when the index column is not highly selective; 4) when the complex query. By analyzing query plans, optimizing indexes, avoiding over-index and regularly maintaining tables, you can make the best choices in practical applications.

Can I install mysql on Windows 7 Can I install mysql on Windows 7 Apr 08, 2025 pm 03:21 PM

Yes, MySQL can be installed on Windows 7, and although Microsoft has stopped supporting Windows 7, MySQL is still compatible with it. However, the following points should be noted during the installation process: Download the MySQL installer for Windows. Select the appropriate version of MySQL (community or enterprise). Select the appropriate installation directory and character set during the installation process. Set the root user password and keep it properly. Connect to the database for testing. Note the compatibility and security issues on Windows 7, and it is recommended to upgrade to a supported operating system.

Explain InnoDB Full-Text Search capabilities. Explain InnoDB Full-Text Search capabilities. Apr 02, 2025 pm 06:09 PM

InnoDB's full-text search capabilities are very powerful, which can significantly improve database query efficiency and ability to process large amounts of text data. 1) InnoDB implements full-text search through inverted indexing, supporting basic and advanced search queries. 2) Use MATCH and AGAINST keywords to search, support Boolean mode and phrase search. 3) Optimization methods include using word segmentation technology, periodic rebuilding of indexes and adjusting cache size to improve performance and accuracy.

Difference between clustered index and non-clustered index (secondary index) in InnoDB. Difference between clustered index and non-clustered index (secondary index) in InnoDB. Apr 02, 2025 pm 06:25 PM

The difference between clustered index and non-clustered index is: 1. Clustered index stores data rows in the index structure, which is suitable for querying by primary key and range. 2. The non-clustered index stores index key values ​​and pointers to data rows, and is suitable for non-primary key column queries.

MySQL: Simple Concepts for Easy Learning MySQL: Simple Concepts for Easy Learning Apr 10, 2025 am 09:29 AM

MySQL is an open source relational database management system. 1) Create database and tables: Use the CREATEDATABASE and CREATETABLE commands. 2) Basic operations: INSERT, UPDATE, DELETE and SELECT. 3) Advanced operations: JOIN, subquery and transaction processing. 4) Debugging skills: Check syntax, data type and permissions. 5) Optimization suggestions: Use indexes, avoid SELECT* and use transactions.

Can mysql and mariadb coexist Can mysql and mariadb coexist Apr 08, 2025 pm 02:27 PM

MySQL and MariaDB can coexist, but need to be configured with caution. The key is to allocate different port numbers and data directories to each database, and adjust parameters such as memory allocation and cache size. Connection pooling, application configuration, and version differences also need to be considered and need to be carefully tested and planned to avoid pitfalls. Running two databases simultaneously can cause performance problems in situations where resources are limited.

The relationship between mysql user and database The relationship between mysql user and database Apr 08, 2025 pm 07:15 PM

In MySQL database, the relationship between the user and the database is defined by permissions and tables. The user has a username and password to access the database. Permissions are granted through the GRANT command, while the table is created by the CREATE TABLE command. To establish a relationship between a user and a database, you need to create a database, create a user, and then grant permissions.

RDS MySQL integration with Redshift zero ETL RDS MySQL integration with Redshift zero ETL Apr 08, 2025 pm 07:06 PM

Data Integration Simplification: AmazonRDSMySQL and Redshift's zero ETL integration Efficient data integration is at the heart of a data-driven organization. Traditional ETL (extract, convert, load) processes are complex and time-consuming, especially when integrating databases (such as AmazonRDSMySQL) with data warehouses (such as Redshift). However, AWS provides zero ETL integration solutions that have completely changed this situation, providing a simplified, near-real-time solution for data migration from RDSMySQL to Redshift. This article will dive into RDSMySQL zero ETL integration with Redshift, explaining how it works and the advantages it brings to data engineers and developers.

See all articles