Vmware workstation安装oracle 10g RAC

合集下载

VMwareWorkstation安装OracleRAC集群

VMwareWorkstation安装OracleRAC集群

VMwareWorkstation安装OracleRAC集群1.O racle 10g v2 RAC For Windows(ASM)1.1 安装环境Vmware GSX 3.2.1,虚拟二台服务器,安装Windows Enterprise Server 2003。

每服务器配置384M内存、5G磁盘、双网卡。

服务器1:Windows Enterprise Server 2003主机名:oracle1服务器2:Windows Enterprise Server 2003主机名:oracle2所需软件:Windows Enterprise Server 2003Oracle 10g v2 Database 10201_database_win32Oracle 10g v2 Clusterware 10201_clusterware_win32.rarWMware的Lsi-SCSI驱动Lsi-SCSI.rar 可从虚拟机之家网站得到1.2 安装步骤1.2.1配置共享磁盘和软驱服务器1和服务器2的administrator账户设置成相同口令。

操作系统安装完成后,添加共享磁盘。

方法参见1.2.1.2章节。

Disk1 0.2GB 用作oracle的群集注册表,最少需要100MDisk2 0.1GB 用作oracle的表决盘,最少需要20MB。

Disk3、Disk4、Disk5分别为2GB,用作oracle数据盘和快速恢复盘使用。

添加一个软驱,选择使用软盘映像。

添加展开的Lsi-SCSI.rar中的VMware-LsiLogic-SCSIDriver-Win2003.flp服务器1的软盘和磁盘添加完成。

在服务器2完成同样操作,磁盘添加成“使用现有盘”修改服务器1和服务器2的配置文件。

添加以下行:scsi1.sharedBus = "VIRTUAL"disk.locking = "FALSE"diskLib.dataCacheMaxSize = "0"diskLib.dataCacheMaxReadAheadSize = "0"diskLib.dataCacheMinReadAheadSize = "0"diskLib.dataCachePageSize = "4096"diskLib.MaxUnsyncedWrites = "0"并将所有的scsi1:x.mode = "undoable"改为scsi1:x.mode = "persistent"启动服务器1和服务器2。

vmware workstation 7安装oracle 10gr2 rac (5) 升级clusterware到10.2.0.4

vmware workstation 7安装oracle 10gr2 rac (5) 升级clusterware到10.2.0.4

/archives/164vmware workstation 7安装oracle 10gr2 rac (5) 升级clusterware到10.2.0.4ON2011年10月17日·L E A V E A C O M M E N T本文描述vmware workstation 7安装oracle 10gr2 rac中的升级clusterware到10.2.0.4部分一.准备工作解压和改变属主unzip p6810189_10204_Linux-x86-64.zipchown -R oracle:oinstall Disk1/二.oracle用户登录执行安装[oracle@rac1 ~]$ crs_stop -allAttempting to stop `ora.rac1.gsd` on member `rac1`Attempting to stop `ora.rac2.gsd` on member `rac2`Attempting to stop `ora.rac2.ons` on member `rac2`Attempting to stop `ora.rac1.ons` on member `rac1`Stop of `ora.rac1.gsd` on member `rac1` succeeded. Stop of `ora.rac2.gsd` on member `rac2` succeeded. Stop of `ora.rac1.ons` on member `rac1` succeeded. Stop of `ora.rac2.ons` on member `rac2` succeeded. Attempting to stop `ora.rac1.vip` on member `rac1` Attempting to stop `ora.rac2.vip` on member `rac2` Stop of `ora.rac1.vip` on member `rac1` succeeded. Stop of `ora.rac2.vip` on member `rac2` succeeded.[oracle@rac1 ~]$ crs_stat -tName Type Target State Host ————————————————————ora.rac1.gsd application OFFLINE OFFLINEora.rac1.ons application OFFLINE OFFLINEora.rac1.vip application OFFLINE OFFLINEora.rac2.gsd application OFFLINE OFFLINEora.rac2.ons application OFFLINE OFFLINEora.rac2.vip application OFFLINE OFFLINE [oracle@rac1 ~]$cd /tmp/Disk1/./runInstaller1.欢迎界面2.升级CRS_HOME3.升级模式4.环境检测5.INSTALL呗6.继续跑脚本吧/oracle/crs/bin/crsctl stop crs & /oracle/crs/install/root102.sh跑完脚本clusterware就升级成功了下接vmware workstation 7安装oracle 10gr2 rac (6) 升级database到10.2.0.4。

虚拟机Oracle_10g_RAC_安装

虚拟机Oracle_10g_RAC_安装

Ads by Google Oracle VMware Linux VMware Console VMware3 VMwareThis SiteHomeDBA ScriptsOracle 8i Articles Oracle 9i Articles Oracle 10g Articles Miscellaneous Articles Linux ArticlesOracle Certification ForumsORACLE-BASE Blog Blog Aggregator Industry News Book StoreTSHSQL Download Firefox Search Plugins Site Info LinksPrinter FriendlyOracle SitesOracle Corporation Technology Network Oracle Metalink Oracle Certification Oracle Magazine Ask TomOracle 8i R3 Docs Oracle 9i R1 Docs Oracle 9i R2 Docs Oracle 10g R1 Docs Oracle 10g R2 Docs Oracle 9iAS DocsOracle AS10g R1 Docs Oracle AS10g R2 Docs Oracle AS10g R3 DocsError MessagesORA-Go 8i R39i R19i R210g R110g R2Search Oracle DocsGo Metalink 8i R39i R19i R210g R110g R2SiteWebGo Oracle 10g RAC On Windows 2003 Using VMware ServerThis article describes the installation of Oracle 10g release 2 (10.2.0.1) RAC on Windows 2003 Server Standard Edition using VMware Server with no additional shared disk devices.z Introduction z Download Software z VMware Server Installationz Virtual Machine Setupz Guest Operating System Installation z Oracle Installation Prerequisites z Install VMware Client Tools z Create Shared Disksz Clone the Virtual Machinez Install the Clusterware Softwarez Install the Database Software and Create an ASM Instance z Create a Database using the DBCA z TNS ConfigurationzCheck the Status of the RACIntroductionOne of the biggest obstacles preventing people from setting up test RAC environments is the requirement for shared storage. In a production environment, shared storage is often provided by a SAN or high-end NAS device, but both of these options are very expensive when all you want to do is get some experience installing and using RAC. A cheaper alternative is to use a FireWire disk enclosure to allow two machines to access the same disk(s), but that still costs money and requires two servers. A third option is to use VMware Server to fake the shared storage.Using VMware Server you can run multiple Virtual Machines (VMs) on a single server, allowing you to run both RAC nodes on a single machine. In additon, it allows you to set up shared virtual disks, overcoming the obstacle of expensive shared storage.Before you launch into this installation, here are a few things to consider.zThe finished system includes the host operating system, two guest operating systems, two sets of Oracle Clusterware, two ASM instances and two Database instances all on a single server. As you can imagine, this requires a significant amount of disk space, CPU and memory. To complete this installation I used a dual 3.0G Xeon server with 4G of memory.zThis procedure provides a bare bones installation to get the RAC working. There is no redundancy in the Clusterware installation or the ASM installation. To add this, simply create double the amount of shared disks and select the "Normal" redundancy option when it is offered. Of course, this will take more disk space.z During the virtual disk creation, I always choose not to preallocate the disk space. This makes virtual disk access slower during the installation, but saves on wasted disk space.z This is not, and should not be considered, a production-ready system. It's simply to allow you to get used to installing and using RAC.Download SoftwareDownload the following software.z VMware ServerzOracle 10g (10.2.0.1) CRS and DB softwareVMware Server InstallationFor this article, I used CentOS 4.3 as the host operating systems. To use Windows as the host operating system, simply run the executable installation file and ignore the following VMware Server installation information.First, install the VMware Server software. On Linux you do this with the following command as the root user.# rpm -Uvh VMware-server-*.rpmPreparing... ########################################### [100%] 1:VMware-server ########################################### [100%]Virtual Disaster RecoveryFree White Paper: Building disaster recovery solutions with VMware.Rac Antibodies Santa Cruz Biotechnology, Inc. Source of over26,000 antibodies. /table-rac.html#Then finish the configuration by running the vmware-config.pl script as the root user. Most of the questions can be answered with the default response by pressing the return key. The output below shows my responses to the questions.# vmware-config.plMaking sure services for VMware Server are stopped.Stopping VMware services:Virtual machine monitor [ OK ]You must read and accept the End User License Agreement to continue.Press enter to display it.VMWARE, INC.SOFTWARE BETA TEST AGREEMENT*** Editied out license agreement ***Do you accept? (yes/no) yesThank you.Configuring fallback GTK+ 2.4 libraries.In which directory do you want to install the mime type icons?[/usr/share/icons]What directory contains your desktop menu entry files? These files have a.desktop file extension. [/usr/share/applications]In which directory do you want to install the application's icon?[/usr/share/pixmaps]Trying to find a suitable vmmon module for your running kernel.The module bld-2.6.9-5.EL-i686smp-RHEL4 loads perfectly in the running kernel.Do you want networking for your virtual machines? (yes/no/help) [yes]Configuring a bridged network for vmnet0.The following bridged networks have been defined:. vmnet0 is bridged to eth0All your ethernet interfaces are already bridged.Do you want to be able to use NAT networking in your virtual machines? (yes/no)[yes]Configuring a NAT network for vmnet8.Do you want this program to probe for an unused private subnet? (yes/no/help)[yes]Probing for an unused private subnet (this can take some time)...The subnet 172.16.210.0/255.255.255.0 appears to be unused.The following NAT networks have been defined:. vmnet8 is a NAT network on private subnet 172.16.210.0.Do you wish to configure another NAT network? (yes/no) [no]Do you want to be able to use host-only networking in your virtual machines?[yes] noTrying to find a suitable vmnet module for your running kernel.The module bld-2.6.9-5.EL-i686smp-RHEL4 loads perfectly in the running kernel.Please specify a port for remote console connections to use [902]Stopping xinetd: [ OK ]Starting xinetd: [ OK ]Configuring the VMware VmPerl Scripting API.Building the VMware VmPerl Scripting API.Using compiler "/usr/bin/gcc". Use environment variable CC to override.The installation of the VMware VmPerl Scripting API succeeded.Do you want this program to set up permissions for your registered virtualmachines? This will be done by setting new permissions on all files found inthe "/etc/vmware/vm-list" file. [no] yesGenerating SSL Server CertificateIn which directory do you want to keep your virtual machine files?[/var/lib/vmware/Virtual Machines] /u01/VMDo you want to enter a serial number now? (yes/no/help) [no] yesPlease enter your 20-character serial number.Type XXXXX-XXXXX-XXXXX-XXXXX or 'Enter' to cancel: ENTER-YOUR-SERIAL-NUMBERStarting VMware services:Virtual machine monitor [ OK ]Virtual ethernet [ OK ]Bridged networking on /dev/vmnet0 [ OK ]Host-only networking on /dev/vmnet8 (background) [ OK ]NAT service on /dev/vmnet8 [ OK ]Starting VMware virtual machines... [ OK ]The configuration of VMware Server e.x.p build-22874 for Linux for this runningkernel completed successfully.#The VMware Server Console is started by issuing the command "vmware" at the command prompt, or by selecting it from the "System Tools" menu.On the "Connect to Host" dialog, accept the "Local host" option by clicking the "Connect" button.You are then presented with the main VMware Server Console screen.The VMware Server is now installed and ready to use.Virtual Machine SetupNow we must define the two virtual RAC nodes. We can save time by defining one VM, then cloning it when it is installed. In this article I use Linux as my host operating system, so all the file paths are UNIX style paths. If you are using a Windows host operating system you would expect to use Windows style paths to the various VMware files, so adjust the paths as necessary.Click the "Create a new virtual machine" button to start the "New Virtual Machine Wizard". Click the "Next" button onthe welcome page.Select the "Custom" virtual machine configuration and click the "Next" button.Select the "Windows" guest operating system option, and set the version to "Windows Server 2003 Standard Edition", then click the "Next" button.Enter the name "RAC1" and the location should default to "/u01/VM/RAC1", then click the "Next" button.Select the required number of processors and click the "Next" button.Uncheck the "Make this virtual machine private" checkbox and click the "Next" button.Select the amount of memory to associate with the virtual machine. Remember, you are going to need two instances, so don't associate too much, but you are going to need approximately 1 Gig (1024 Meg) to compete the installation successfully.Accept the "Use bridged networking" option by clicking the "Next" button.Accept the "LSI Logic" option by clicking the "Next" button.Select the "Create a new virtual disk" option and click the "Next" button.Accept the "SCSI" option by clicking the "Next" button. It's a virtual disk, so you can still use this option even if your physical disk is IDE or SATA.Set the disk size to "10.0" GB and uncheck the "Allocate all disk space now" option. The latter will make disk access slower, but will save you wasting disk space.Accept "RAC1.vmdk" as the disk file name and complete the VM creation by clicking the "Finish" button.On the "VMware Server Console" screen, click the "Edit virtual machine settings" button.On the "Virtual Machine Settings" screen, highlight the "Floppy 1" drive and click the "- Remove" button.Click the "+ Add" button and select a hardware type of "Ethernet Adapter", then click the "Next" button.Accept the "Bridged" option by clicking the "Finish" button.Click on the "Options" tab, highlight the "Startup/Shutdown" setting and select the "Don't power on virtual machine" in the "On host startup" option. Finish by clicking the "OK" button.The virtual machine is not configured so we can start the guest operating system installation.Guest Operating System InstallationPlace the first Windows 2003 SE disk in the CD drive and start the virtual machine by clicking the "Power on this virtual machine" button. The right pane of the VMware Server Console should display a boot loader, then the Windows installation screen.Continue through the Windows installation as you would for a normal server. To be consistent with the rest of the article, the following information should be set during the installation:z hostname: RAC1z IP Address eth0: 192.168.2.101 (public address)z IP Address eth1: 192.168.0.101 (private address)You are free to change the IP addresses to suit your network, but remember to stay consistent with those adjustments throughout the rest of the article.Oracle Installation PrerequisitesPerform the following steps whilst logged into the RAC1 virtual machine.Amend the C:\windows\system32\drivers\etc\hosts file to contain the following information.127.0.0.1 localhost.localdomain localhost# Public192.168.2.101 rac1.localdomain rac1192.168.2.102 rac2.localdomain rac2#Private192.168.0.101 rac1-priv.localdomain rac1-priv192.168.0.102 rac2-priv.localdomain rac2-priv#Virtual192.168.2.111 rac1-vip.localdomain rac1-vip192.168.2.112 rac2-vip.localdomain rac2-vipVMware sometimes creates additional network adapters, which will prevent the clusterware from loading. Delete any additional adapters as follows. Open a command prompt on RAC1 and issue the following commands.set devmgr_show_nonpresent_devices=1devmgmt.mscOn the resulting "Device Manager" screen, pick the "View > Show hidden devices" menu option.Now check for extra network adapters. You would expect two, but if there are more than this, uninstall the greyed out adapters.Open the "Network Connections" screen (Start > All Programs > Accessories > Communications > Network Connections). Rename the two connections to "public" and "private" respectively, making sure you apply the names to the appropriate connections.Check that the network settings are correct for both connections.The Clusterware installation is very sensitive, so make sure you read the Checking Network Requirements section of the documentation, and make any necessary changes.In addition to the configuration mentioned above, the documentation suggests two more configuration changes that I did not find necessary on VMware Server. Even so, it is advisable to make the changes.First, ensure the public interface is first in the bind order:z Open the "Network Connections" dialog by right-clicking on the "My Network Places" icon and selecting the "Properties" menu option.z Select the "Advanced > Advanced Settings..." menu option.z On the "Adapters and Bindings" tab, make sure the public interface is the first interface listed.z Accept any modifications by clicking on the "OK" button and exiting the "Network Connections" dialog. Second, disable Windows Media Sensing for TCP/IP:z Backup the Windows registry.z Run the Registry Editor (Regedt32.exe) and find the following key:HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\Tcpip\Parameters z Add the following registry value:Value Name: DisableDHCPMediaSenseData Type: REG_DWORD -BooleanValue: 1z This change will not take effect until the computer is restarted.Next, install the VMware client tools.Install VMware Client ToolsLogin on the RAC1 virtual machine, then select the "VM > Install VMware Tools..." option from the main VMware Server Console menu.Click the "Install" button on the subsequent screen.Click the "Next" button to continue.Accept the "Typical" option by clicking the "Next" button.Click the "Install" button to continue.Set the hardware acceleration when prompted by clicking the "Yes" button and following the instructions on the subsequent screens.Once the installatin is complete, click the "Finish" button.The VMware client tools are now installed.Create Shared DisksShut down the RAC1 virtual machine and create a directory on the host system to hold the shared virtual disks.# mkdir -p /u01/VM/sharedOn the VMware Server Console, click the "Edit virtual machine settings" button. On the "Virtual Machine Settings" screen, click the "+ Add" button.Select the hardware type of "Hard Disk" and click the "Next" button.Accept the "Create a new virtual disk" option by clicking the "Next" button.Accept the "SCSI" option by clicking the "Next" button.Set the disk size to "10.0" GB and uncheck the "Allocate all disk space now" option, then click the "Next" button.Set the disk name to "/u01/VM/shared/ocr.vmdk" and click the "Advanced" button.Set the virtual device node to "SCSI 1:1" and the mode to "Independent" and "Persistent", then click the "Finish" button.Repeat the previous hard disk creation steps 4 more times, using the following values:z File Name: /u01/VM/shared/votingdisk.vmdkVirtual Device Node: SCSI 1:2Mode: Independent and Persistentz File Name: /u01/VM/shared/asm1.vmdkVirtual Device Node: SCSI 1:3Mode: Independent and Persistentz File Name: /u01/VM/shared/asm2.vmdkVirtual Device Node: SCSI 1:4Mode: Independent and Persistentz File Name: /u01/VM/shared/asm3.vmdkVirtual Device Node: SCSI 1:5Mode: Independent and PersistentAt the end of this process, the virtual machine should look something like the picture below.Edit the contents of the "/u01/VM/RAC1/RAC1.vmx" file using a text editor, making sure the following entries are present. Some of the tries will already be present, some will not.disk.locking = "FALSE"diskLib.dataCacheMaxSize = "0"diskLib.dataCacheMaxReadAheadSize = "0"diskLib.dataCacheMinReadAheadSize = "0"diskLib.dataCachePageSize = "4096"diskLib.maxUnsyncedWrites = "0"scsi1.present = "TRUE"scsi1.virtualDev = "lsilogic"scsi1.sharedBus = "VIRTUAL"scsi1:1.present = "TRUE"scsi1:1.mode = "independent-persistent"scsi1:1.fileName = "/u01/VM/shared/ocr.vmdk"scsi1:1.deviceType = "plainDisk"scsi1:1.redo = ""scsi1:2.present = "TRUE"scsi1:2.mode = "independent-persistent"scsi1:2.fileName = "/u01/VM/shared/votingdisk.vmdk"scsi1:2.deviceType = "plainDisk"scsi1:2.redo = ""scsi1:3.present = "TRUE"scsi1:3.mode = "independent-persistent"scsi1:3.fileName = "/u01/VM/shared/asm1.vmdk"scsi1:3.deviceType = "plainDisk"scsi1:3.redo = ""scsi1:4.present = "TRUE"scsi1:4.mode = "independent-persistent"scsi1:4.fileName = "/u01/VM/shared/asm2.vmdk"scsi1:4.deviceType = "plainDisk"scsi1:4.redo = ""scsi1:5.present = "TRUE"scsi1:5.mode = "independent-persistent"scsi1:5.fileName = "/u01/VM/shared/asm3.vmdk"scsi1:5.deviceType = "plainDisk"scsi1:5.redo = ""Start the RAC1 virtual machine by clicking the "Power on this virtual machine" button on the VMware Server Console. When the server has started, log in so you can partition the disks.Prior to partitioning the disks on Windows Server 2003, you must enable disk automounting. I didn't need to do this, but I guess it makes sense to do as you're told. To enable automounting do the following command at the command prompt, then restart the server.C:\> diskpartDISKPART> automount enableDISKPART> exitC:\>When the server restarts, open the "Computer Management" dialog (Start > All Programs > Administrative Tools > Computer Management) and click on the Disk Management tree node. This action should initiate the "Initialize and Convert Disk Wizard". Click the "Next" button to continue.Initialize all 5 disks by clicking the "Next" button.Don't convert any of the disks. Make sure all 5 disks are unchecked, then "Next" button.Complete the process by clicking the "Finish" button.Right-click on "Disk 1" and select the "New Partition..." option to start the "New Partition Wizard".Click the "Next" button to continue.Select the "Extended partition" option, then click the "Next" button.Accept the default partition size by clicking the "Next" button.Complete the partition by clicking the "Finish" button.The partition will now be displayed with a green bar. Right-click on the partition and select the "New Logical Drive" option to restart the "New Partition Wizard".Click the "Next" button to continue.Accept the "Logical drive" option by clicking the "Next" button.Accept the default partition size by clicking the "Next" button.Select the "Do not assign a drive letter or drive path" option, then click the "Next" button.Select the "Do not format this partition" option, then click the "Next" button.Complete the logical drive by clicking the "Finish" button.The drive should now be displayed as a healthy drive with a blue bar.Repeat the previous partitioning steps for the remaining 4 disks.The shared disks are now configured.Clone the Virtual MachineThe current version of VMware Server does not include an option to clone a virtual machine, but the following steps illustrate how this can be achieved manually.Shut down the RAC1 virtual machine and copy the RAC1 virtual machine using the following command.# cp -R /u01/VM/RAC1 /u01/VM/RAC2Edit the contents of the "/u01/VM/RAC2/RAC1.vmx" file, making the following change.displayName = "RAC2"Ignore discrepancies with the file names in the "/u01/VM/RAC2" directory. This does not affect the action of the virtual machine.In the VMware Server Console, select the File > Open menu options and browse for the"/u01/VM/RAC2/RAC1.vmx" file. Once opened, the RAC2 virtual machine is visible on the console. Start the RAC2 virtual machine by clicking the "Power on this virtual machine" button and click the "Always Create" button on the subsequent "Question" screen.Open the "Network Connections" screen (Start > All Programs > Accessories > Communications > Network Connections). Amend the IP Addresses of both connections to the correct values for the RAC2 node.The cloning process sometimes alters the network connection setup, so repeat the steps mentioned previously for removing extra network adapters and renaming the connections.Open the "System Properties" dialog (Start > Control Panel > System), click on the "Computer Name" tab and click the "Change" button. Enter the name "rac2" then click the "OK" button.Click all subsequent "OK" buttons to exit the "System Properties" dialog and restart the server when prompted. Once the RAC2 virtual machine has restarted, start the RAC1 virtual machine. When both nodes have started, check they can both ping all the public and private IP addresses using the following commands.ping -c 3 rac1ping -c 3 rac1-privping -c 3 rac2ping -c 3 rac2-privAt this point the virtual IP addresses defined in the hosts file will not work, so don't bother testing them.It's a good idea to take a snapshot of the virtual machines, so you can repeat the following stages if you run into any problems. To do this, shutdown both virtual machines and issue the following commands.# cd /u01/VM# tar -cvf RAC-PreClusterware.tar RAC1 RAC2 shared# gzip RAC-PreClusterware.tarThe virtual machine setup is now complete.Install the Clusterware SoftwareStart the RAC1 and RAC2 virtual machines. The Oracle Clusterware for Windows is very sensitive, so before you start, check the network connection setup on each machine again. Remove and extra network adapters, rename the connections appropriately and check the nodes ping correctly. Make sure your network configuration matches the Checking Network Requirements section of the documentation.Start the Oracle installer on RAC1.On the "Welcome" screen, click the "Next" button.Accept the default inventory location by clicking the "Next" button.Enter the appropriate name and path for the Oracle Home and click the "Next" button.Wait while the prerequisite checks are done. If you have any failures correct them and retry the tests before clicking the "Next" button.The "Specify Cluster Configuration" screen shows only the RAC1 node in the cluster. Click the "Add" button to continue.Enter the details for the RAC2 node and click the "OK" button.Click the "Next" button to continue.The "Specific Network Interface Usage" screen defines how each network interface will be used. Highlight the "public" interface and click the "Edit" button.Set the "public" interface type to "Public" and click the "OK" button.Leave the "private" interface as private and click the "Next" button.On the "Cluster Configuration Storage" screen, highlight disk 1 and click the "Edit" button.Select the "Place OCR(Primary) on this Partition" option and click the "OK" button.Highlight disk 2 and click the "Edit" button. Select the "Place Voting Disk on this Partition" option and click the "OK" button.On the "Cluster Configuration Storage" screen, click the "Next" button and ignore the redundancy warnings by clicking the "OK" button.On the "Summary" screen, click the "Install" button to continue.Wait while the installation takes place.Wait while the configuration assistants run.The VIPCA will fail, so click the "OK" button on the resulting error screen.Click the "Next" button and accept the subsequent warning, then click the "Exit" button to leave the installer.On the RAC1 virtual machine, run the VIPCA manually by issuing the following commands in a command prompt.cd c:\oracle\product\10.2.0\crs\binvipca.batClick the "Next" button on the VIPCA welcome screen.Highlight the "public" interface and click the "Next" button.Enter the vitual IP alias and address for each node. Once you enter the first alias, the remaining values should default automatically. Click the "Next" button to continue.Accept the summary information by clicking the "Finish" button.Wait until the configuration is complete, then click the "OK" button.Accept the VIPCA results by clicking the "Exit" button.The status of the finished cluster can be checked by running the cluvfy.bat script as shown below.C:\oracle\product\10.2.0\crs\BIN>cluvfy.bat stage -post crsinst -n rac1,rac2Performing post-checks for cluster services setupChecking node reachability...Node reachability check passed from node "rac1".Checking user equivalence...User equivalence check passed for user "Administrator".Checking Cluster manager integrity...Checking CSS daemon...Daemon status check passed for "CSS daemon".Cluster manager integrity check passed.Checking cluster integrity...Cluster integrity check passedChecking OCR integrity...Checking the absence of a non-clustered configuration...All nodes free of non-clustered, local-only configurations.Uniqueness check for OCR device passed.Checking the version of OCR...OCR of correct Version "2" exists.Checking data integrity of OCR...Data integrity check for OCR passed.OCR integrity check passed.。

vmware + 裸设备 + crs + oracle10g RAC搭建步骤

vmware + 裸设备 + crs + oracle10g RAC搭建步骤

vmware + 裸设备 + crs + oracle10g RAC搭建步骤(一):创建虚拟机最近在本机上重新用vmware server 1.04 搭建了一套10G RAC系统,在搭建过程把步骤基本记录下来,希望对大家有帮助。

本部分主要讲述如何用vmware server创建一个虚拟服务器。

创建虚拟机1、创建目录G:\>mkdir vm\rac\rac1G:\>mkdir vm\rac\rac2G:\>mkdir vm\rac\sharedstorage2、创建虚拟机双击桌面上的VMware Server图标以启动应用程序:1.按CTRL-N创建一个新的虚拟机。

2.新建虚拟机向导:单击Next。

3.选择适当的配置:a.虚拟机配置:选择Custom。

4.选择客户操作系统:a.客户操作系统:选择Linux。

b.版本:选择Red Hat Enterprise Linux 4。

5.命名虚拟机:a.虚拟机名称:输入“rac1”。

b.位置:输入“G:\vm\rac\rac1”。

6.设置访问权限:a.访问权限:选择Make this virtual machine private。

7.启动/关闭选项:a.虚拟机帐户:选择User that powers on the virtual machine。

8.处理器配置:a.处理器:选择一个处理器。

9.虚拟机内存:a.内存:选择512MB。

10.网络类型:a.网络连接:选择Use bridged networking。

11.选择I/O适配器类型:a.I/O适配器类型:选择LSI Logic。

12.选择磁盘:a.磁盘:选择Create a new virtual disk。

13.选择磁盘类型:a.虚拟磁盘类型:选择SCSI (Recommended)。

14.指定磁盘容量:a.磁盘容量:输入“8GB”。

b.取消选择Allocate all disk space now。

[誉天李老师上课文档]oracle 10g rac安装终手册

[誉天李老师上课文档]oracle 10g rac安装终手册

实验环境vmworkstation +redhat5.4搭建存储虚拟机2块网卡一块eth1 用于连接rac1 rac2 来连存储用192.168.2.10 hostonly一块eth0 用于作为rac1 rac2的公共网卡的网关10.85.10.254 vment2主机名storage添加一个100G硬盘作为存储01 配置共享存储一般的SAN存储服务器可以使用RAID+iSCSI进行架构。

我使用的是一个PC机器,主板不支持RAID,所以只将一块硬盘做成iSCSI服务器。

首先我们做一个服务器端:1、在RHEL5中安装如下的包:iscsi-initiator-utils-6.2.0.868-0.18.el5.i386.rpmperl-Config-General-2.40-1.el5.noarch.rpm(这个包在光盘的cluster storage目录下)scsi-target-utils-0.0-5.20080917snap.el5.i386.rpm (这个包在光盘的cluster storage目录下)2、通过linux中的命令生成IQN编号#iscsi-iname.redhat:e5ab84c569a83、编辑配置文件#vi /etc/tgt/targets.conf在文件中加入<target .redhat:e5ab84c569a8> backing-store /dev/sdb</target>4、启动服务servicetgtd startchkconfigtgtd on5、查看配置信息# tgtadm --lldiscsi --op show --mode targetTarget 1: .redhat:e5ab84c569a8 System information:Driver: iscsiState: readyI_T nexus information:LUN information:LUN: 0Type: controllerSCSI ID: deadbeaf1:0SCSI SN: beaf10Size: 0 MBOnline: YesRemovable media: NoBacking store: No backing storeLUN: 1Type: diskSCSI ID: deadbeaf1:1SCSI SN: beaf11Size: 1000205 MBOnline: YesRemovable media: NoBacking store: /dev/hdbLUN: 2Type: diskSCSI ID: deadbeaf1:2SCSI SN: beaf12Size: 1000205 MBOnline: YesRemovable media: NoBacking store: /dev/hdcAccount information:ACL information:ALL上面的内容就是iSCSI服务的配置,注意,iSCSI的链接端口是3260,保证防火墙访问正常通过。

oracle 10g RAC linux vmware workstation FREENAS共享存储

oracle 10g RAC linux vmware workstation FREENAS共享存储

RAC安装文档一、规划软件规划二、安装freeNAS,作为共享存储FreeNAS是一套免费的NAS服务器,它能将一部普通PC变成网络存储服务器。

该软件基于FreeBSD,Samba 及PHP,支持CIFS (samba), FTP, NFS protocols, Software RAID (0,1,5) 及web 界面的设定工具。

用户可通过Windows、Macs、FTP、SSH 及网络文件系统(NFS) 来访问存储服务器;FreeNAS可被安装于硬盘或移动介质USB Flash Disk上,所占空间不足16MB。

1、freeNAS软件安装将镜像文件放入光驱,启动选择9安装,回车选择3,安装完全系统在HDD+DATA+SWAP partition <OK>将会创建三个分区1.OS 2.DATA 3.SWAP <OK>选择安装介质<ok>选择安装分区ad0 <OK>OS分区大小默认380M <OK>是否创建是swap分区,yesSwap分区默认大小256M <OK>完成安装,重新启动系统启动完成后,设置ip地址:192.168.10.253/24设置完成重置web登录密码,选择3重置web界面密码为:freenas < Yes>帐号是:admin登录:修改语言环境-修改为简体中文:System>general>: save 保存。

2、添加磁盘,模拟存储添加三块磁盘做raid5 ,给rac做共享存储--OK重新启动NAS服务器,登录管理界面找到磁盘>管理点击最右侧下方的+号图标,添加磁盘选项:已格式化的文件系统选择softraid,其他默认将三块磁盘依次添加完成添加完成后---应用更改硬盘---软raid选择raid5 ,并点击右侧+号,添加Raid名称为rac,选择三块硬盘勾选“建立并初始raid”---“添加”应用更改:初始化raid,中间需要几分钟时间;完成:3、配置ISCSI配置ISCSI目标:打开后,首先设置端口,默认端口是3260—“应用更改”配置ISCSI服务发起端定义—“应用更改”配置ISCSI服务目标端定义--“应用更改”打开“设置”勾选右侧启动保存并重启服务4、主机连接freeNAS首先在服务器上安装安装iscsi,iscsi-initiator-utils.x86_64 0:6.2.0.871-0.16.el5,并开启服务,使用iscsiadm连接freeNAS[root@rac1 ~]# yum install *iscsi*iscsi-initiator-utils.x86_64 0:6.2.0.871-0.16.el5root@rac2 ~]# /etc/init.d/iscsi startiscsid is stopped[ OK ] iSCSI daemon: [ OK ][ OK ]Setting up iSCSI targets: iscsiadm: No records found![ OK ][root@rac1 ~]# iscsiadm -m discovery -t sendtargets -p 192.168.10.253192.168.10.253:3260,1 iqn.2007-09.jp.ne.peach.istgt:disk0[root@rac1 ~]# iscsiadm -m node -T iqn.2007-09.jp.ne.peach.istgt:disk0 -p 192.168.10.253 -l Logging in to [iface: default, target: iqn.2007-09.jp.ne.peach.istgt:disk0, portal: 192.168.10.253,3260]Login to [iface: default, target: iqn.2007-09.jp.ne.peach.istgt:disk0, portal: 192.168.10.253,3260]: successful使用fdisk -l查看共享存储连接情况,两台机器均已连接[root@rac1 ~]# fdisk -lDisk /dev/hda: 21.4 GB, 21474836480 bytes255 heads, 63 sectors/track, 2610 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesDevice Boot Start End Blocks Id System/dev/hda1 * 1 13 104391 83 Linux/dev/hda2 14 778 6144862+ 83 Linux/dev/hda3 779 816 305235 82 Linux swap / Solaris/dev/hda4 817 2610 14410305 5 Extended/dev/hda5 817 2610 14410273+ 83 LinuxDisk /dev/sda: 42.9 GB, 42949410816 bytes64 heads, 32 sectors/track, 40959 cylindersUnits = cylinders of 2048 * 512 = 1048576 bytes查看rac节点[root@rac2 ~]# fdisk -lDisk /dev/hda: 21.4 GB, 21474836480 bytes255 heads, 63 sectors/track, 2610 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesDevice Boot Start End Blocks Id System/dev/hda1 * 1 13 104391 83 Linux/dev/hda2 14 778 6144862+ 83 Linux/dev/hda3 779 816 305235 82 Linux swap / Solaris/dev/hda4 817 2610 14410305 5 Extended/dev/hda5 817 2610 14410273+ 83 LinuxDisk /dev/sda: 42.9 GB, 42949410816 bytes64 heads, 32 sectors/track, 40959 cylindersUnits = cylinders of 2048 * 512 = 1048576 bytesDisk /dev/sda doesn't contain a valid partition table重启iscsi服务,查看存储挂载情况[root@rac1 ~]# /etc/init.d/iscsi restartLogging out of session [sid: 1, target: iqn.2007-09.jp.ne.peach.istgt:disk0, portal: 192.168.10.253,3260]Logout of [sid: 1, target: iqn.2007-09.jp.ne.peach.istgt:disk0, portal: 192.168.10.253,3260]: successfulStopping iSCSI daemon:iscsid dead but pid file exists[ OK ] iSCSI daemon: [ OK ][ OK ]Setting up iSCSI targets: Logging in to [iface: default, target: iqn.2007-09.jp.ne.peach.istgt:disk0, portal: 192.168.10.253,3260]Login to [iface: default, target: iqn.2007-09.jp.ne.peach.istgt:disk0, portal: 192.168.10.253,3260]: successful[ OK ]至此共享存储配置完成;共享存储划分分区,因为存储是做的raid5,存储容量大约在40G左右,所以划分三个主分区,作为ASM磁盘组使用,另外划分若干扩展分区,使用作为安装OCR和spfile;这里只需要在一个节点上做就可以了,因为存储是共享的。

oracle 10G rac安装亲测

oracle 10G rac安装亲测

分区,安装系统系统好后安装第二个网卡安装vmtools下载linux vmtools 包[root@localhost /]#mount dev/cdrom /media/cdromcopy 此文件到临时文件夹cp media/cdrom/mVMwareTools-8.8.4-743747.tar.gz /tmp进入tmp 文件目录并解压此文件包cd /tmptar -zxf vmware-linux-tools.tar.gzls\more /etc/sysconfig/network 修改hostnameecho ‘127.0.0.1 localhost.localdomain localhost’ >/etc/hostsvi etc/hosts1、测试网络连通性[root@localhost ~]# ping -c 2 192.168.1.117PING 192.168.1.117 (192.168.1.117) 56(84) bytes of data.64 bytes from 192.168.1.117: icmp_seq=0 ttl=64 time=12.2 ms64 bytes from 192.168.1.117: icmp_seq=1 ttl=64 time=1.08 ms--- 192.168.1.117 ping statistics ---2 packets transmitted, 2 received, 0% packet loss, time 1002msrtt min/avg/max/mdev = 1.089/6.670/12.252/5.582 ms, pipe 2 [root@localhost ~]# ping -c 2 10.0.0.2PING 10.0.0.2 (10.0.0.2) 56(84) bytes of data.64 bytes from 10.0.0.2: icmp_seq=0 ttl=64 time=2.93 ms64 bytes from 10.0.0.2: icmp_seq=1 ttl=64 time=1.02 ms--- 10.0.0.2 ping statistics ---2 packets transmitted, 2 received, 0% packet loss, time 1002msrtt min/avg/max/mdev = 1.021/1.978/2.936/0.958 ms, pipe 2 [root@localhost ~]#2、配置host文件[root@localhost ~]# cat /etc/hosts# Do not remove the following line, or various programs# that require network functionality will fail.127.0.0.1 localhost.localdomain localhost192.168.1.116 myrac1192.168.1.117 myrac2192.168.1.118 myrac1-vip192.168.1.119 myrac2-vip10.0.0.1 myrac1-priv10.0.0.2 myrac2-priv3、安装系统所需rpm包rpm –ivh *.rpm查找rpm[root@myrac1 RPMS]# find compa*.rpmcompat-db-4.1.25-9.i386.rpmcompat-gcc-32-3.2.3-47.3.i386.rpmcompat-gcc-32-c++-3.2.3-47.3.i386.rpm挂光驱[root@myrac1 /]# mount /media/cdrommount: block device /dev/hdc is write-protected, mounting read-only [root@myrac1 /]# cd /media/cdrom/RedHat/RPMS[root@myrac1 RPMS]# pwd/media/cdrom/RedHat/RPMS[root@myrac1 RPMS]#安装的rpmrpm –ivh compat-libstdc++-33-3.2.3-47.3.i386.rpmrpm –ivh gcc-3.4.4-2.i386.rpmrpm –ivh gcc-c++-3.4.4-2.i386.rpmrpm –ivh glibc-devel-2.3.4-2.13.i386.rpmrpm –ivh glibc-headers-2.3.4-2.13.i386.rpmrpm –ivh glibc-kernheaders-2.4-9.1.98.EL.i386.rpmrpm –ivh libstdc++-devel-3.4.4-2.i386.rpmrpm –ivh sysstat-5.0.5-1.i386.rpm[root@myrac2 /]# mount /media/cdrommount: block device /dev/hdc is write-protected, mounting read-only[root@myrac2 /]# cd /media/cdrom/RedHat/RPMS[root@myrac2 RPMS]# rpm -ivh compat-libstdc++-33-3.2.3-47.3.i386.rpmwarning: compat-libstdc++-33-3.2.3-47.3.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60e Preparing... ########################################### [100%] package compat-libstdc++-33-3.2.3-47.3 is already installed[root@myrac2 RPMS]# rpm -ivh gcc-3.4.4-2.i386.rpmwarning: gcc-3.4.4-2.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60eerror: Failed dependencies:glibc-devel >= 2.2.90-12 is needed by gcc-3.4.4-2.i386Suggested resolutions:glibc-devel-2.3.4-2.13.i386.rpm[root@myrac2 RPMS]# rpm -ivh gcc-c++-3.4.4-2.i386.rpmwarning: gcc-c++-3.4.4-2.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60eerror: Failed dependencies:gcc = 3.4.4-2 is needed by gcc-c++-3.4.4-2.i386libstdc++-devel = 3.4.4 is needed by gcc-c++-3.4.4-2.i386Suggested resolutions:gcc-3.4.4-2.i386.rpmlibstdc++-devel-3.4.4-2.i386.rpm[root@myrac2 RPMS]# rpm -ivh glibc-devel-2.3.4-2.13.i386.rpmwarning: glibc-devel-2.3.4-2.13.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60eerror: Failed dependencies:glibc-headers is needed by glibc-devel-2.3.4-2.13.i386glibc-headers = 2.3.4-2.13 is needed by glibc-devel-2.3.4-2.13.i386Suggested resolutions:glibc-headers-2.3.4-2.13.i386.rpm[root@myrac2 RPMS]# rpm -ivh glibc-headers-2.3.4-2.13.i386.rpmwarning: glibc-headers-2.3.4-2.13.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60e error: Failed dependencies:kernel-headers is needed by glibc-headers-2.3.4-2.13.i386kernel-headers >= 2.2.1 is needed by glibc-headers-2.3.4-2.13.i386 Suggested resolutions:glibc-kernheaders-2.4-9.1.98.EL.i386.rpm[root@myrac2 RPMS]# rpm -ivh glibc-kernheaders-2.4-9.1.98.EL.i386.rpmwarning: glibc-kernheaders-2.4-9.1.98.EL.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60e Preparing... ########################################### [100%] 1:glibc-kernheaders ########################################### [100%] [root@myrac2 RPMS]# rpm -ivh libstdc++-devel-3.4.4-2.i386.rpmwarning: libstdc++-devel-3.4.4-2.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60e Preparing... ########################################### [100%] 1:libstdc++-devel ########################################### [100%] [root@myrac2 RPMS]# rpm -ivh sysstat-5.0.5-1.i386.rpmwarning: sysstat-5.0.5-1.i386.rpm: V3 DSA signature: NOKEY, key ID db42a60e Preparing... ########################################### [100%] 1:sysstat ########################################### [100%] [root@myrac2 RPMS]#4、创建oracle账户及软件安装目录[root@myrac1 /]# groupadd -g 700 dba[root@myrac1 /]# useradd -u 500 -g dba oracle[root@myrac1 /]# passwd oracleChanging password for user oracle.New UNIX password:BAD PASSWORD: it is too simplistic/systematicRetype new UNIX password:passwd: all authentication tokens updated successfully.[root@myrac1 /]#[root@myrac1 /]# mkdir -p /oracle/product/database[root@myrac1 /]#mkdir -p /oracle/product/crs[root@myrac1 /]# chown -R oracle:dba /oracle/product/crs[root@myrac1 /]# chown -R oracle:dba /oracle/product/database[root@myrac1 /]# chmod 775 /oracle/product/database[root@myrac1 /]# chmod 775 /oracle/product/crs[root@myrac1 /]# chown -R oracle:dba /oracle[root@myrac1 /]# chmod 775 /oracle[root@myrac1 /]# ls -l /oracle/product5、配置环境变量及用户资源[root@myrac1 /]# su - oracle[oracle@myrac1 ~]$ ls[oracle@myrac1 ~]$ pwd/home/oracle[oracle@localhost ~]$ cat .bash_profile# .bash_profile# Get the aliases and functionsif [ -f ~/.bashrc ]; then. ~/.bashrcfi# User specific environment and startup programsPATH=$PATH:$HOME/binexport ORACLE_BASE=/oracleexport CRS_HOME=/oracle/product/crsexport ORACLE_HOME=/oracle/product/databaseexport PATH=$CRS_HOME/bin:$ORACLE_HOME/bin:$PATHexport ORACLE_SID=rac1unset USERNAME [oracle@localhost ~]$配置Limits.conf,限制oracle抢占资源[root@localhost security]# pwd/etc/security[root@localhost security]# cat limits.conf# /etc/security/limits.conf##Each line describes a limit for a user in the form:##<domain> <type> <item> <value>##Where:#<domain> can be:# - an user name# - a group name, with @group syntax# - the wildcard *, for default entry# - the wildcard %, can be also used with %group syntax, # for maxlogin limit##<type> can have the two values:# - "soft" for enforcing the soft limits# - "hard" for enforcing hard limits##<item> can be one of the following:# - core - limits the core file size (KB)# - data - max data size (KB)# - fsize - maximum filesize (KB)# - memlock - max locked-in-memory address space (KB) # - nofile - max number of open files# - rss - max resident set size (KB)# - stack - max stack size (KB)# - cpu - max CPU time (MIN)# - nproc - max number of processes# - as - address space limit# - maxlogins - max number of logins for this user# - priority - the priority to run user process with# - locks - max number of file locks the user can hold##<domain> <type> <item> <value>##* soft core 0#* hard rss 10000#@student hard nproc 20#@faculty soft nproc 20#@faculty hard nproc 50#ftp hard nproc 0#@student - maxlogins 1oracle soft memlock 5242880oracle hard memlock 5242880oracle soft nofile 65536oracle hard nofile 65536oracle soft nproc 2047oracle hard nproc 16384# End of file[root@localhost security]#6、编辑内核文件etc/sysctl.conf[root@localhost /]# cat /etc/sysctl.conf# Kernel sysctl configuration file for Red Hat Linux## For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and# sysctl.conf(5) for more details.# Controls IP packet forwardingnet.ipv4.ip_forward = 0# Controls source route verificationnet.ipv4.conf.default.rp_filter = 1# Do not accept source routingnet.ipv4.conf.default.accept_source_route = 0# Controls the System Request debugging functionality of the kernel kernel.sysrq = 0# Controls whether core dumps will append the PID to the core filename. # Useful for debugging multi-threaded applications.kernel.core_uses_pid = 1kernel.shmmax=2147483648kernel.sem=250 32000 100 128fs.file-max=65536net.ipv4.ip_local_port_range=1024 65000net.core.rmem_default=262144net.core.wmem_default=262144net.core.rmem_max=262144net.core.wmem_max=262144[root@localhost /]#[root@myrac1 /]# sysctl -pnet.ipv4.ip_forward = 0net.ipv4.conf.default.rp_filter = 1net.ipv4.conf.default.accept_source_route = 0kernel.sysrq = 0kernel.core_uses_pid = 1kernel.shmmax = 2147483648kernel.sem = 250 32000 100 128fs.file-max = 65536net.ipv4.ip_local_port_range = 1024 65000net.core.rmem_default = 262144net.core.wmem_default = 262144net.core.rmem_max = 262144net.core.wmem_max = 262144[root@myrac1 /]#7、配置SSH用户信任关系[oracle@myrac2 ~]$ cd[oracle@myrac2 ~]$ pwd/home/oracle[oracle@myrac2 ~]$ mkdir .ssh[oracle@myrac2 ~]$ chmod 700 .ssh[oracle@myrac2 ~]$ cd .ssh[oracle@myrac2 .ssh]$ ssh-keygen -t rsaGenerating public/private rsa key pair.Enter file in which to save the key (/home/oracle/.ssh/id_rsa):Enter passphrase (empty for no passphrase):Enter same passphrase again:Your identification has been saved in /home/oracle/.ssh/id_rsa.Your public key has been saved in /home/oracle/.ssh/id_rsa.pub.The key fingerprint is:6d:03:9d:f7:73:b3:17:04:5e:68:88:3b:57:6c:54:c2 oracle@myrac2[oracle@myrac2 .ssh]$ ssh-keygen -t dsaGenerating public/private dsa key pair.Enter file in which to save the key (/home/oracle/.ssh/id_dsa):Enter passphrase (empty for no passphrase):Enter same passphrase again:Your identification has been saved in /home/oracle/.ssh/id_dsa.Your public key has been saved in /home/oracle/.ssh/id_dsa.pub.The key fingerprint is:4c:93:1c:c8:ab:85:a2:02:06:bf:38:e7:e2:9c:97:45 oracle@myrac2[oracle@myrac2 .ssh]$ cat *.pub>authorized_keys[oracle@myrac2 .ssh]$ scp authorized_keys myrac1:/home/oracle/.ssh/keys_myrac2 The authenticity of host 'myrac1 (192.168.1.116)' can't be established.RSA key fingerprint is 00:c6:a2:01:df:5b:5c:42:22:48:8d:4f:09:7d:bc:51.Are you sure you want to continue connecting (yes/no)? yesWarning: Permanently added 'myrac1,192.168.1.116' (RSA) to the list of known hosts. oracle@myrac1's password:authorized_keys 100% 826 0.8KB/s 00:00 [oracle@myrac2 .ssh]$[oracle@myrac1 .ssh]$ lsauthorized_keys id_dsa id_dsa.pub id_rsa id_rsa.pub keys_myrac2[oracle@myrac1 .ssh]$ cat keys_myrac2>>authorized_keys[oracle@myrac1 .ssh]$ lsauthorized_keys id_dsa id_dsa.pub id_rsa id_rsa.pub keys_myrac2[oracle@myrac1 .ssh]$ scp authorized_keys myrac2:/home/oracle/.ssh/The authenticity of host 'myrac2 (192.168.1.117)' can't be established.RSA key fingerprint is 00:c6:a2:01:df:5b:5c:42:22:48:8d:4f:09:7d:bc:51.Are you sure you want to continue connecting (yes/no)? yesWarning: Permanently added 'myrac2,192.168.1.117' (RSA) to the list of known hosts. oracle@myrac2's password:authorized_keys 100% 1652 1.6KB/s 00:00 [oracle@myrac1 .ssh]$8、配置时间同步[root@myrac1 ~]# vi /etc/ntp.confserver 127.127.1.0 # local clockdudge 127.127.1.0 stratum 11broadcastdelay 0.008[root@myrac2 /]# vi /etc/ntp.confserver 192.168.1.116 prefer # local clockdriftfile /var/lib/ntp/driftbroadcastdelay 0.008[root@myrac2 /]# service ntpd restart9、修改hangcheck-timer[root@myrac2 /]# cat /etc/rc.d/rc.local#!/bin/sh## This script will be executed *after* all the other init scripts.# You can put your own initialization stuff in here if you don't# want to do the full Sys V style init stuff.touch /var/lock/subsys/localmodprobe hangcheck-timer[root@myrac2 /]# vi /etc/modprobe.confalias scsi_hostadapter mptbasealias scsi_hostadapter1 mptscsialias scsi_hostadapter2 mptspialias scsi_hostadapter3 mptsasalias scsi_hostadapter4 mptscsihalias scsi_hostadapter5 ata_piixalias eth1 pcnet32alias eth0 pcnet32[root@myrac2 /]# sync,sync,rebootGrep hangcheck /var/log/messages |tail -l10、按照系统需求对磁盘分区(裸设备+asm磁盘)[root@myrac1 ~]# fdisk /dev/sdbDevice contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only,until you decide to write them. After that, of course, the previouscontent won't be recoverable.The number of cylinders for this disk is set to 1305.There is nothing wrong with that, but this is larger than 1024,and could in certain setups cause problems with:1) software that runs at boot time (e.g., old versions of LILO)2) booting and partitioning software from other OSs(e.g., DOS FDISK, OS/2 FDISK)Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help): mCommand actiona toggle a bootable flagb edit bsd disklabelc toggle the dos compatibility flagd delete a partitionl list known partition typesm print this menun add a new partitiono create a new empty DOS partition tablep print the partition tableq quit without saving changess create a new empty Sun disklabelt change a partition's system idu change display/entry unitsv verify the partition tablew write table to disk and exitx extra functionality (experts only)Command (m for help):Command (m for help): nCommand actione extendedp primary partition (1-4)pPartition number (1-4): 1First cylinder (1-1305, default 1): 1Last cylinder or +size or +sizeM or +sizeK (1-1305, default 1305): 13 Command (m for help):Command (m for help): nCommand actione extendedp primary partition (1-4)pPartition number (1-4): 2First cylinder (14-1305, default 14): 14Last cylinder or +size or +sizeM or +sizeK (14-1305, default 1305): 26 Command (m for help):lBuilding a new DOS disklabel. Changes will remain in memory only,until you decide to write them. After that, of course, the previous content won't be recoverable.The number of cylinders for this disk is set to 1305.There is nothing wrong with that, but this is larger than 1024,and could in certain setups cause problems with:1) software that runs at boot time (e.g., old versions of LILO)2) booting and partitioning software from other OSs(e.g., DOS FDISK, OS/2 FDISK)Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help): nCommand actione extendedp primary partition (1-4)pPartition number (1-4): 1First cylinder (1-1305, default 1): 1Last cylinder or +size or +sizeM or +sizeK (1-1305, default 1305): 13 Command (m for help): nCommand actione extendedp primary partition (1-4)pPartition number (1-4): 14Value out of range.Partition number (1-4): 2First cylinder (14-1305, default 14): 26Last cylinder or +size or +sizeM or +sizeK (26-1305, default 1305):[root@myrac1 ~]# fdisk /dev/sdbDevice contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only,until you decide to write them. After that, of course, the previouscontent won't be recoverable.The number of cylinders for this disk is set to 1305.There is nothing wrong with that, but this is larger than 1024,and could in certain setups cause problems with:1) software that runs at boot time (e.g., old versions of LILO)2) booting and partitioning software from other OSs(e.g., DOS FDISK, OS/2 FDISK)Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help):[root@myrac1 ~]# fdisk /dev/sdbDevice contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only,until you decide to write them. After that, of course, the previouscontent won't be recoverable.The number of cylinders for this disk is set to 1305.There is nothing wrong with that, but this is larger than 1024,and could in certain setups cause problems with:1) software that runs at boot time (e.g., old versions of LILO)2) booting and partitioning software from other OSs(e.g., DOS FDISK, OS/2 FDISK)Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite) Command (m for help): nCommand actione extendedp primary partition (1-4)pPartition number (1-4): 1First cylinder (1-1305, default 1): 1Last cylinder or +size or +sizeM or +sizeK (1-1305, default 1305): 13 Command (m for help): nCommand actione extendedp primary partition (1-4)pPartition number (1-4): 2First cylinder (14-1305, default 14): 14Last cylinder or +size or +sizeM or +sizeK (14-1305, default 1305): 26 Command (m for help): nCommand actione extendedp primary partition (1-4)pPartition number (1-4): 3First cylinder (27-1305, default 27): 27Last cylinder or +size or +sizeM or +sizeK (27-1305, default 1305): 800 Command (m for help): nCommand actione extendedp primary partition (1-4)pSelected partition 4First cylinder (801-1305, default 801): 801Last cylinder or +size or +sizeM or +sizeK (801-1305, default 1305): 1035 Command (m for help): wThe partition table has been altered!Calling ioctl() to re-read partition table.Syncing disks.[root@myrac2 /]# fdisk -lDisk /dev/sda: 23.6 GB, 23622320128 bytes255 heads, 63 sectors/track, 2871 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesDevice Boot Start End Blocks Id System/dev/sda1 * 1 13 104391 83 Linux/dev/sda2 14 1287 10233405 83 Linux/dev/sda3 1288 2561 10233405 83 Linux/dev/sda4 2562 2871 2490075 5 Extended /dev/sda5 2562 2688 1020096 82 Linux swap Disk /dev/sdb: 10.7 GB, 10737418240 bytes255 heads, 63 sectors/track, 1305 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesDevice Boot Start End Blocks Id System/dev/sdb1 1 13 104391 83 Linux/dev/sdb2 14 26 104422+ 83 Linux/dev/sdb3 27 800 6217155 83 Linux/dev/sdb4 801 1305 4056412+ 83 Linux[root@myrac2 /]#11、配置裸设备(1、2都操作)[root@myrac1 /]# cat /etc/sysconfig/rawdevices# This file and interface are deprecated.# Applications needing raw device access should open regular# block devices with O_DIRECT.# raw device bindings# format: <rawdev> <major> <minor># <rawdev> <blockdev># example: /dev/raw/raw1 /dev/sda1# /dev/raw/raw2 8 5/dev/raw/raw1 /dev/sdb1/dev/raw/raw2 /dev/sdb2[root@myrac1 /]#[root@myrac1 /]# cd etc[root@myrac1 etc]# cd udev[root@myrac1 udev]# lsdevices permissions.d rules.d scripts udev.conf[root@myrac1 udev]# cd p*[root@myrac1 permissions.d]# ls50-udev.permissions[root@myrac1 permissions.d]# cat 50-udev.permissions[root@myrac1 permissions.d]# cat 50-udev.permissions# raw devicesram*:root:disk:0660raw/*:root:disk:0660raw*:oracle:dba:0660raw/*:oracle:dba:0660[root@myrac1 /]# service rawdevices restartAssigning devices:/dev/raw/raw1 --> /dev/sdb1/dev/raw/raw1: bound to major 8, minor 17/dev/raw/raw2 --> /dev/sdb2/dev/raw/raw2: bound to major 8, minor 1812、创建ASM逻辑磁盘[root@myrac1 /]# uname -aLinux myrac1 2.6.9-22.ELsmp #1 SMP Mon Sep 19 18:32:14 EDT 2005 i686 i686 i386 GNU/Linux [root@myrac1 /]# cd /media/cdrom[root@myrac1 cdrom]# lsoracleasm-2.6.9-22.ELsmp-2.0.3-1.i686.rpm oracleasm-support-2.0.3-1.i386.rpm oracleasmlib-2.0.2-1.i386.rpm[root@myrac1 cdrom]# rpm -ivh *.rpmPreparing... ########################################### [100%] 1:oracleasm-support ########################################### [ 33%] 2:oracleasm-2.6.9-22.ELsm########################################### [ 67%]3:oracleasmlib ########################################### [100%] [root@myrac1 cdrom]#[root@myrac1 ~]# /etc/init.d/oracleasm configureConfiguring the Oracle ASM library driver.This will configure the on-boot properties of the Oracle ASM librarydriver. The following questions will determine whether the driver isloaded on boot and what permissions it will have. The current valueswill be shown in brackets ('[]'). Hitting <ENTER> without typing ananswer will keep that current value. Ctrl-C will abort.Default user to own the driver interface []:Default group to own the driver interface []:Start Oracle ASM library driver on boot (y/n) [n]:Fix permissions of Oracle ASM disks on boot (y/n) [y]:Writing Oracle ASM library driver configuration: [ OK ]/etc/init.d/oracleasm configure[root@myrac1 init.d]# ./oracleasmUsage: ./oracleasm {start|stop|restart|enable|disable|configure|createdisk|deletedisk|querydisk|listdisks|scandisk s|status}[root@myrac1 init.d]# ./oracleasm start[root@myrac1 init.d]# ./oracleasm statusChecking if ASM is loaded: [FAILED][root@myrac1 init.d]# ./oracleasm enableWriting Oracle ASM library driver configuration: [ OK ]Loading module "oracleasm": [ OK ]Mounting ASMlib driver filesystem: [ OK ]Scanning system for ASM disks: [ OK ][root@myrac1 init.d]#[root@myrac1 init.d]# ./oracleasm createdisk vol1 /dev/sdb3Marking disk "/dev/sdb3" as an ASM disk: [root@myrac1 init.d]# cd /[root@myrac1 /]# /etc/init.d/oracleasm createdisk vol2 /dev/sdb4Marking disk "/dev/sdb4" as an ASM disk: [root@myrac1 /]#若还是创建不了votingdisk,可以采用如下解决方法:[root@myrac1 /]# cat /etc/selinux/configSELINUX=permissiveSELINUXTYPE=targeted[root@myrac1 /]# selinux代表安全增强linux,有三个值enforcing记录日志且阻止程序运行,permissive记录警告日志允许程序运行,disable关闭selinux策略。

Oracle_RAC_10g安装文档

Oracle_RAC_10g安装文档

时间服务器; 10.130.170.50 和51目录一、准备工作 (1)二、设置Vmware环境 (2)三、安装linux系统 (9)四、配置Linux环境 (9)五、配置第2台节点Node2 (15)六、配置ClusterWare安装环境 (16)七、安装Clusterware (19)八、安装Database软件 (27)九、创建数据库和ASM实例 (31)十、安装过程中遇到的问题 (43)1、系统启动到“Sendmail”和“sm-client”时需要等待很久的时间 (43)2、在配置hosts文件时,输入了错误的IP地址造成node1和node2无法互相ping通 (43)3、在执行“runcluvfy.sh”进行安装clusterware前进行检验时,提示没有执行权限 (43)4、在执行“runcluvfy.sh”进行安装clusterware前进行检验时,出现下面的错误,这些错误是oracle的bug (43)5、安装Clusterware时遇到的错误:时钟不同步,同步时钟后点击Yes即可 (44)6、在安装Clusterware时,在第二个节点执行Root.sh时报的错误:Failure at final check of Oracle CRS stack.10 (44)7、在安装Clusterware时,在node2节点执行root.ssh时报错信息: (44)8、执行srvctl命令是报如下错误的解决办法 (45)9、在安装Clusterware,在node2节点执行root.sh时报:Error 0(Native:listNetInterfaces:[3])错误 (45)11、ORA-04031:unable to allocate 540bytes of shared memory ("shared Pool","declare (48)12、配置VNC (48)13、在虚拟机上安装配置VMware tools (49)5)、Read hat as4 裸设备配置 (50)一、准备工作所谓工欲善必先利其器,要在vmware 下做linux 系统的oracle rac ,我们也需要准备好相关的装备。

vmware+linux+oracle10g rac全过程(5)

vmware+linux+oracle10g rac全过程(5)

vmware+linux+oracle10g rac全过程(5) - 安装clusterware来自:/Linux/2011-02/31976p32.htm2010-08-10 17:44接下来是clusterware的安装clusterware的安装在主节点上运行,所以我们接下来要做的是启动主节点RAC1,打开FTP功能,把clusterware软件传上去,然后以oracle用户的身份来执行整个安装过程,请看截图:RAC1重启之后,第三块网卡意外的丢失了动态IP地址,这里临时赋予他一个静态IP地址,和之前的地址保持一样。

上传clusterware_linux32.zip安装介质后,以unzip命令对这个文件进行解压缩,解压完成之后得到clusterware这个文件夹。

将clusterware整个文件夹的属主和权限按照oracle用户的要求进行修改。

注销当前窗口,以oracle用户登陆,这样整个环境变量就挂靠在oracle户头下了。

在安装之前,通常要检查当前的环境,命令如下:[oracle@rac1 cluvfy]$ /data/rhel5/clusterware/cluvfy/runcluvfy.sh stage -pre crsinst -n rac1,rac2 -verbose在这个过程中,系统可能会报错,比如说什么包需要安装啊,swap区过小啊,这些东西统统不用管他们,跳过即可。

这里说明一下,ORACLE有时候报的错莫名其妙,牛头不对马嘴,比如说前段时间我在HP环境下配置ORACLE RAC,在加载裸设备ocr的时候,系统报错说赋予ocr的权限和属主有问题,建议查清后再说。

仔细检查之后,权限跟属主一点问题没有,结果是因为共享卷组没有激活导致,这想起来就很气人了,有这样忽悠群众的吗?所以ORACLE下的报错不必较真,就像这里一样,经过一番检查,他认为你试验环境没有达标,但你硬要往下做他也拿你没招,典型的吃硬不吃软。

vmware+linux+oracle10g rac全过程(6)

vmware+linux+oracle10g rac全过程(6)

vmware+linux+oracle10g rac全过程(6) - 安装database来自:/Linux/2011-02/31976p32.htm2010-08-10 17:55clusterware软件安装结束,在各自节点也看到了CRS进程,下面继续database数据库软件的安装过程,因为这个过程比较简单,这里就简要奉上截图:1,上传10201_database_linux32.zip到“ly_media”文件系统,以unzip命令解压database软件,赋予正确的权限和属主,再以oracle身份登陆进行安装:2,弹出oracle安装界面:3,点击“next”:4,oraInventory仍然使用系统默认的路径,点击“next”:5,选择企业版安装方式,点击“next”:6,选择ORACLE数据库的安装路径,点击“next”:7,选中两个节点,点击“next”:8,按惯例,执行系统级检查:9,在“warning”和“not executed”的小方框里面打勾,点击“next”:10,这里只安装database软件,实例在后期安装:11,下面是安装过程,因为在虚拟机+linux操作系统+oracle数据库安装程序同时运行,内存消耗比较大,所以这个过程比较长:12,在安装进行到尾声的时候,在弹出来的对话框中按要求执行几个脚本程序,和clusterware安装阶段类似:这个地方要注意一下,系统提示要在RAC1上以root执行orainstRoot.sh这个脚本,对RAC2没有要求。

但没有要求并不等于不需要做,先来看看RAC1下执行orainstRoot.sh都执行了什么步骤:可见这一步主要是给oraInventory目录赋予正确的权限和属主,即使系统没有要求,我们也需要到RAC2上执行类似的操作,给与oraInventory 目录真确的权限和属主,否则在最后阶段会有报错信息。

11,分别到各个节点执行root.sh脚本:12,点击“next”进行退出,database软件部分安装结束:数据库软件安装完成之后,接下来要做的是给两个节点配置listener,也就是监听。

使用VMWARE搭建ORACLE RAC

使用VMWARE搭建ORACLE RAC
买女装,到 /
买女装,到 /
192.168.114.120 node1-vip
192.168.114.121 node2-vip
安装虚拟机,配置环境
节点 1 以 ORACLE 用户登陆: #cat .profile #!/bin/bash umask 022 ORACLE_BASE=/opt/oracle/orabase;export ORACLE_BASE ORACLE_SID=ossdb1;export ORACLE_SID export ORACLE_HOME=/opt/oracle/product/database export CRS_HOME=/opt/oracle/product/crs
oracle@node1:~/.ssh> ssh node2 cat /opt/oracle/.ssh/id_rsa.pub >>authorized_keys
oracle@node1:~> scp authorized_keys node2:/opt/oracle/.ssh/ The authenticity of host 'node2 (192.168.114.111)' can't be established. RSA key fingerprint is 8c:4e:76:ed:4c:51:0b:a1:f8:f2:9d:a7:97:3b:ec:24. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added 'node2,192.168.114.111' (RSA) to the list of known ho sts.

Oracle 10g RAC安装与配置(ppt 32页)

Oracle 10g RAC安装与配置(ppt 32页)

共享文件系统(NTFS、EXT3)
维护方便
大型数据库不推荐使用
ASM( Oracle 10g新技术)
维护方便,性能较可靠
13
二、CRS安装升级
CRS安装 1、root用户执行rootpre.sh脚本 2、CRS_HOME路径 3、规划VIP地址 4、root用户执行
/home/oracle/oraInventory/orainstRoot.sh和 $CRS_HOME/root.sh脚本 5、VIP配置BUG
Server Mode All Initialization Parameters:……
26
建库
5、Database Storage 控制文件 路径、冗余、参数 表空间 路径、大小、参数 数据文件 路径、大小、参数 Redo log Groups 路径、大小、组数、成员数
27
建库
7
系统环境
硬件环境 硬件服务器: CPU(32bit、64bit|Intel-Itanium、AMD) 内存(32bit system Oracle可寻址内存4G, SGA 1.7G) 其他:存储、网卡等 网络环境:双网卡、心跳线、网络带宽等
8
系统环境
软件环境 系统版本: 需要经过Oracle认证 系统包:
30
Q&A
谢谢!
31
Oracle 10g RAC安装配置注意事项
1) 系统时间同步 2) 主机名命名(长度、特殊符号等) 3) 共享磁盘(划分、共享方式等) 4) OCR DISK和VOTING DISK读写属性 5) Root用户执行root.sh脚本 6) VIP配置BUG 7) 操作系统补丁包(不要太低或太高,要合理) 8) 操作系统经过认证 9) CRS和数据库软件升级 10) Redo log groups

Linux虚拟机Vmvware下配置ORACLE(ASM)RAC 10G

Linux虚拟机Vmvware下配置ORACLE(ASM)RAC 10G

使用VMware Server 在Oracle Enterprise Linux 上安装Oracle RAC 10g作者:Vincent Chan使用虚拟机在Oracle Enterprise Linux 上免费试用Oracle 真正应用集群10g第2 版2007 年1 月发表于10 月份Oracle OpenWorld 2006 上推介的Oracle 坚不可摧的Linux 旨在为Red Hat Linux 提供企业级支持服务,更快地修复错误,以及显著降低支持价格。

此外,Oracle 自己的Enterprise Linux(基于包含额外错误修补的Red Hat Advanced Server 第4 版(Update 4))提供免费下载。

因此,现在可以通过VMware Server(VMware 提供的一个免费虚拟环境)在家用电脑上免费使用运行在Red Hat Advanced Server 上的Oracle 真正应用集群(RAC) 10g。

VMware Server 允许您在一台物理计算机上运行多个操作系统。

每个虚拟机都是一个独立的操作环境,并带有一组自己的虚拟组件,如磁盘、处理器和内存。

虚拟技术在计算环境中十分有用,它允许您在同一物理主机上独立地开发和测试软件以防止数据或软件损坏。

VMware 软件广泛地用于服务器整合,以降低总拥有成本并加快应用程序开发和测试周期。

在本指南中,您将了解如何安装和配置两个在Enterprise Linux 和VMware Server 上运行Oracle RAC 10g第2 版的节点。

注意,本指南仅用于教学/评估目的;Oracle 及其他供应商不会为本配置提供支持。

本指南分为以下几个部分:1. 硬件要求和概述2. 配置第一个虚拟机3. 在第一个虚拟机上配置Enterprise Linux4. 创建并配置第二个虚拟机5. 配置Oracle 自动存储管理(ASM)6. 配置Oracle 集群文件系统(OCFS2)7. 安装Oracle 集群件8. 安装Oracle 数据库10g第2 版9. 探索RAC 数据库环境10. 测试透明应用程序故障切换(TAF)11. 数据库备份与恢复12. 探索Oracle 企业管理器(OEM) 数据库控制台13. 常见问题1. 硬件要求和概述在本指南中,您将安装32 位Linux 客户操作系统。

VMWARE下WINDOWS2008ORACLE10GRAC安装

VMWARE下WINDOWS2008ORACLE10GRAC安装

VMware虚拟机下Windows 2008实现Oracle 10g RAC系统构建1.测试环境说明在一台cpu为双核2.8GHZ,内存为3G的普通pc机上,安装虚拟机,通过虚拟机模拟两台windows2008server服务器,在这两台服务器上构建oracle rac。

2.安装VMWARE虚拟机软件本机安装的是VMware Workstation 7.0,安装步骤省略3.创建Windows 2008 Server虚拟机选择typical,点击Next选择windows2008server的安装文件路径,点击Next输入管理员账号的密码:oracle,点击Next 选择虚拟机的存储路径,点击Next设置硬盘大小为25G,点击Next 点击Finish虚拟机在初始化选择WINDOWS SERVER 2008 企业版免激活,点击Next进入安装等待界面,时间较长4.配置WINDOWS2008服务器安装完成后,会自动重启,点击热键ctrl+alt+insert ,输入密码:oracle右键-个性化-将计算机等图标在桌面显示出来在vm-settings,为虚拟机再增加一个网卡网卡类型选择NAT修改计算机名为:RAC1在网络设置中找到需要设置的两块网卡将两块网卡分别重命名为:PUBLIC和PRIVATEPUBLIC网卡设置如下:PRIVATE网卡设置如下关闭windows防火墙修改hosts文件文件内容修改如下:打开命令行,输入diskpart在DISKPART>提示符下输入:AUTOMOUNT ENABLE 设置完成后,需要重启计算机5.通过STARWIND创建共享磁盘Starwind安装略去,此版本为5.2点击add host ,host地址为127.0.0.1,点击ok增加了一个localhost的服务器点击connect,输入密码:starwind点击add target输入target Alias为:disk,点击下一步选择new disk ,点击下一步选择Basic Virtual,点击下一步选择Image File Device ,点击下一步选择create new virtual disk,点击下一步输入磁盘路径,,点击下一步勾选Asynchronous mode和Allow multiple current Iscsi connection上(clustering),点击下一步选择Normal,点击下一步点击下一步点击完成一块大小为10G的磁盘就增加好了将刚才安装好的虚拟机(rac1)复制一份到win2008srv2目录,然后打开将虚拟机名修改为RAC2选择I copyIt登录系统后,修改计算机名为:RAC2修改PRIVATE网卡的配置如下:修改PUBLIC网卡的配置如下:在网络管理的高级设置中将PUBLIC网卡放置在最上面(两台服务器都需要此设置)在服务器管理中选择磁盘管理,显示如下:点击管理工具-iSCSI发起程序点击发现点击添加,IP为:192.168.100.1(就是上面安装Starwind那台计算机的IP),点击确定点击目标,勾选计算机启动时自动还原此连接点击卷和设备,点击自动配置会自动增加我们在Starwind中增加的磁盘DISK刷新磁盘管理,可以看到新增加了一块磁盘,右键点击联机在图形界面无法将磁盘1设置为扩展分区,我们改在命令行下执行在命令行下先输入:diskpart,再输入:list,再输入:select disk 1,再输入:create part ext 在磁盘管理中刷新一下,磁盘1已经为扩展分区,我们点击新建简单卷大小选择100M选择不分配驱动器或驱动器路径,点击下一步选择不用格式化这个卷,点击下一步点击完成同样的方法再增加两个100M和一个6000M的磁盘测试网络:ping rac2Net use \\rac2\c$测试网络:ping rac2-priv pingrac2-vip在RAC2上测试网络:ping rac1Net use \\rac1\c$测试网络:ping rac12-priv ping rac1-vip在RAC2服务器上点击管理工具-iSCSI发起程序点击添加,输入192.168.100.1,点击确定点击目标- 勾选选择计算机启动时自动还原此连接选择卷和设备,点击自动配置点开磁盘管理,把磁盘1联机将自动增加的逻辑磁盘去掉盘符运行中输入REGEDIT,登录注册表在注册表界面点击连接网络注册表输入RAC1点击确定后出现如下显示,表示远程也可以访问RAC1的注册表停止服务MSDTC,并将服务设置为手动启动6.安装ORACLE CRS.在crs安装光盘cluvfy目录下输入:runcluvfy stage –post hwos –n rac1,rac2 –verbose,测试是否具备安装oracle crs的条件打开oracle crs安装光盘,点击setup.exe,点击下一步点击下一步点击添加,输入:rac2 ,rac2-priv,rac2-vip,点击下一步点击编辑,将public的端口类型改为公用点击编辑,将磁盘1设置为ocr盘,将磁盘4设置为表决盘,点击确定点击安装点击下一步点击退出验证crs安装成果,在crs_home路径下输入:crs_stat –t,如下图显示,目标及状态全是ONLINE 表示正常,没有任何问题在命令行输入VIPCA,点击下一步选择public,点击下一步。

VM Workstation 10搭建oracle10g RAC手册

VM Workstation 10搭建oracle10g RAC手册

一,实验环境计算机:笔记本一台,I5 CPU,8G内存,250G SSD虚拟机:VMware Workstation 10系统:rhel-server-5.4-x86_64-dvd.isoOracle:10201_clusterware_linux_x86_64.cpio.gz10201_database_linux_x86_64.cpio.gz远程连接及上传工具:SecureCRT 7.2学习之初也尝试过搭建10G的RAC,但是由于经验不足,忙活了几天几夜,没有成功,最后果断放弃了,又是买书,又是查看资料,为了学习RAC,我买了两本张晓明的《大话ORACLE RAC》,《大话ORACLE GRID》,第一本讲的是oracle10g的RAC,第二本将的是oracle11g的RAC,第一本书我很仔细的看了,不懂得地方也经过查找资料,做了注解,收获颇丰。

这次模拟没有按照网上先配置一个节点,在复制节点,为了更接近真实环境,我直接建了两台虚拟机,这样就模拟了两个节点。

共享存储放在节点rac1中,在rac2的启动文件中配置一下就OK了,具体步骤后面详解。

虚拟机安装linux操作系统的步骤就省略了,这个网上很多教程。

虚拟机中系统装好后两个网卡一个是NAT模式,一个是HOST-ONLY模式,NAT对应本地机的NET8网卡,HOST-ONLY对应本地机的NET1网卡,根据下面配置后,在本地就可以通过CRT远程连接虚拟机中的Linux系统了。

配置vm中的NAT模式对应的网段。

配置本地的NET8对应的IP。

Linux系统中这样配置,就可以通过NAT方式连接外网了。

也可以通过这种方式通过CRT远程连接LINUXHOST-ONLY的vm网段配置本地NET1网络连接的配置这样配置后就可以通过CRT远程连接linux了。

①,RAC 网络规划节点1 节点2 主机名Rac1 Rac2Public NIC Eth0 Eth0Private NIC Eth1 Eth1Public IP 192.168.2.100/rac1 192.168.2.101/rac2Private IP 10.10.10.100/rac1-priv 10.10.10.101/rac2-priv VIP 192.168.2.100/rac1-vip 192.168.2.201/rac2-vip ②,共享存储规划(SSD空间不多,没有细分,一共划了四个分区)文件类别RAW ASM磁盘组OCR /dev/raw/raw1 /(200M)V oteDisk /dev/raw/raw2 /(200M)DATA DATA /(4G) Flash Recovery Area FRA /(2G)③,共享存储划分LUN Rac1 Rac2LUN1 (200M) /dev/sdb1 /dev/sdb1LUN2 (200M) /dev/sdc1 /dev/sdc1LUN3 (4G) /dev/sdd1 /dev/sdd1LUN4 (2G) /dev/sde1 /dev/sde1二,实施1,设置共享存储因为我把存储都配置在RAC1节点中,所以要在两个节点都要配置,Rac1节点配置信息:修改rac10ga.vmx (rac10ga虚拟机目录下)disk.locking = "false"diskLib.dataCacheMaxSize = "0"diskLib.dataCacheMaxReadAheadSize = "0"diskLib.DataCacheMinReadAheadSize = "0"diskLib.dataCachePageSize = "4096"diskLib.maxUnsyncedWrites = "0"scsi1:0.deviceType = "disk"scsi1:1.deviceType = "disk"scsi1:2.deviceType = "disk"scsi1:3.deviceType = "disk"RAC2节点配置信息修改rac10gb.vmx (rac10gb虚拟机目录下)disk.locking = "false"diskLib.dataCacheMaxSize = "0"diskLib.dataCacheMaxReadAheadSize = "0"diskLib.DataCacheMinReadAheadSize = "0"diskLib.dataCachePageSize = "4096"diskLib.maxUnsyncedWrites = "0"scsi1:0.deviceType = "disk"scsi1:1.deviceType = "disk"scsi1:2.deviceType = "disk"scsi1:3.deviceType = "disk"scsi1.present = "TRUE"scsi1.virtualDev = "lsilogic"scsi1:0.present = "TRUE"scsi1:0.fileName = "D:\Virtual Machines\rac10ga\ocr.vmdk"scsi1:1.present = "TRUE"scsi1:1.fileName = "D:\Virtual Machines\rac10ga\vote.vmdk"scsi1:2.present = "TRUE"scsi1:2.fileName = "D:\Virtual Machines\rac10ga\data.vmdk"scsi1:3.present = "TRUE"scsi1:3.fileName = "D:\Virtual Machines\rac10ga\fra.vmdk"scsi1:0.redo = ""scsi1:1.redo = ""scsi1:2.redo = ""scsi1:3.redo = ""经过上面的配置后,出来fileName路径不同,其他配置都相同,RAC2节点中的filaName 路径只想RAC1节点中的路径就OK了,在RAC1中这个filaName参数没有前面“D:\Virtual Machines\rac10ga\”路径。

vmware上oracle rac搭建步骤

vmware上oracle rac搭建步骤

Vmware +Oracle 11g rac搭建一、vmware初始化创建(2台最小化安装)swap分区大小> 3G提示:不建议使用一台配置好后通过克隆得到第二台服务器,因为这样网络配置和一些信息容易出问题,另外2台更加接近正式情况。

二、虚拟机的配置(2台机器执行)1、关闭防火墙(2台机器执行)1)iptables关闭[root@localhost ~]# service iptables stopiptables: Flushing firewall rules: [ OK ]iptables: Setting chains to policy ACCEPT: filter [ OK ]iptables: Unloading modules: [ OK ][root@localhost ~]# chkconfig iptables off[root@localhost ~]#2)关闭selinux[root@localhost ~]# vi /etc/sysconfig/selinux[root@localhost ~]# egrep -v "^#|^$" /etc/sysconfig/selinuxSELINUX=disabledSELINUXTYPE=targeted[root@localhost ~]#2、配置本地yum源[root@localhost ~]# cd /etc/yum.repos.d/[root@localhost yum.repos.d]# lspublic-yum-ol6.repo[root@localhost yum.repos.d]# vi base.repo[root@localhost yum.repos.d]# lsbase.repo public-yum-ol6.repo[root@localhost yum.repos.d]# cat base.repo[base]name=basebaseurl=file:///mnt/cdrom[root@localhost ~]# mkdir -p /mnt/cdrom3、配置共享存储1)规划:10G=1G(ocr/voting)+6G(DATA)+3G(BACKUP)通过命令创建vmware共享磁盘如图2)将共享磁盘添加虚拟机配置文件,让虚拟机识别共享(注意需要关闭虚拟机)scsi1.present = "TRUE"scsi1.virtualDev = "lsilogic"scsi1.sharedBus = "virtual"scsi1:1.present = "TRUE"scsi1:1.mode = "independent-persistent"scsi1:1.filename = "E:\vmOS\vstorage\sharedisk11g.vmdk"scsi1:1.deviceType = "plainDisk"disk.locking = "false"diskLib.dataCacheMaxSize = "0"diskLib.dataCacheMaxReadAheadSize = "0"diskLib.DataCacheMinReadAheadSize = "0"diskLib.dataCachePageSize = "4096"diskLib.maxUnsyncedWrites = "0"到虚拟机的相关路径目录,打开虚拟机启动文件Ora11g_rac1.vmx / Ora11g_rac2.vmx, 在最后空白处添加这几段内容(一定要最后) ,如果添加有问题将导致虚拟机无法启动,请仔细检查和修改。

vmware+linux+oracle10g rac全过程(1)

vmware+linux+oracle10g rac全过程(1)

vmware+linux+oracle10g rac全过程(1) - 安装和配置vmware2010-08-10 17:00来自:/Linux/2011-02/31976p32.htm实验环境:笔记本一台(2GB内存,320GB硬盘)Vmware Server 1.0.6版Linux Enterprise 5.1版Oracle 10g for linux(10.2.0.1)前言:最开始的实验环境其实不是这样的,虚拟机用的是vmware workstation,用了一段时间之后发现用vmware workstation版本建不了共享磁盘,也就没法构建ORACLE RAC实验环境,所以把vmware workstation换成了vmware server2.0。

装完vmware server2.0之后连启动web界面都成问题,重装仍然如此,无奈之下启用了vmware server1.0.6版本。

在使用哪一款linux操作系统也几经选择,开始用的是linux enterprise 4.0版本,到建立共享磁盘的时候始终有问题,过不去,后来在ITPUB意外的发现了君三思的学习笔记《手把手教你用VMware在linux下安装oracle10g RAC》,看他在里面用的是linux 5.1版本的操作系统,为了实验过程顺利一些,我也采用了这个版本的操作系统。

在使用介质的时候也碰到些小问题,搭建ORACLE RAC需要用到的两个重要介质,一是clusterware,也就是oracle集群软件,一是oracle software for linux,可能是网络的因素,在下载完10201_database_linux32.zip这个文件并上传到linux操作系统中却非常意外的发现无法解压,究其原因可能是下载得不够健全,一部分字节出了问题,导致整个文件都不能用,于是只有重新下载,非常消耗时间。

在这个实验过程中,碰到很多问题,有的是和虚拟机相关的,有的是和linux操作系统相关的,有的是和oracle数据库相关的,因为这众多的问题出现,导致实验进度过长,从开始准备到实验最终完成花了大概两个星期时间,光重装操作系统就不下五次。

相关主题
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

Vmware workstation安装oracle 10g RAC操作说明书编制:长安铃木信息系统课王川2012-5-17目录1 事前准备 (4)1.1相关软件: (4)1.2安装前规划: (4)1.2.1 双机环境 (4)1.2.2 命名 (5)2 安装 (5)2.1配置虚拟机 (5)2.2安装操作系统 (13)2.3配置1#节点环境 (20)2.4创建共享磁盘 (22)2.5创建2#机器 (23)2.6建立时间同步服务 (26)2.7建立用户等效性。

(28)2.8磁盘分区 (31)2.9配置RAW设备 (31)2.10创建ASM磁盘 (32)3 正式安装 (34)3.1安装ORACLE RAC (34)3.2安装数据库软件(ASM) (44)3.3创建数据库 (48)文档版本记录版本编号变更内容变更人日期Vmware workstation安装oracle 10g RAC操作说明书1事前准备1.1 相关软件:1、虚拟机:Vmware workstation 8.0.1 build-5289922、OS:Enterprise-R4-U8-x86_64-dvd.ISO3、Oracle soft:(1)10201_database_linux_x86_64.cpio <数据库安装>(2)p6810189_10204_Linux-x86-64 <升级包>(3)10201_clusterware_linux_x86_64.cpio.gz <集群>/technetwork/database/10201linx8664soft-092456.html?ssSourceSiteId=otncn4、终端操作:SecureCRT5、文件上传:WinSCP6、X Windows1.2 安装前规划:1.2.1双机环境RAC 1#节点RAC 2#节点HOSTNAME kei1 kei2Public IP Address (eth0)192.168.11.111 192.168.11.112Vip IP Address (eth0)192.168.11.113 192.168.11.114Private IP Address(eth1)192.168.56.111 192.168.56.112ORACLE RAC SID kei1 kei2集群实例名称keiOCR(oracle集群注册表)/dev/raw/raw1 /dev/sdb1 500M/dev/raw/raw1 /dev/sdc1 500M 表决磁盘(voting disk)/dev/raw/raw3 /dev/sdd1 500MASM/dev/sde1 10G VOL1 for Oracle Data/dev/sdf1 10G VOL2 for Oracle Data/dev/sdg1 5G VOL3 for flash_recovery_area/dev/sdh1 5G VOL4 for flash_recovery_area 数据库备份/dev/sdi1 20G (mkfs -t ext3 /dev/sdh1)1.2.2命名ORACLE_BASE=/u01/ oracle /product/appASM_HOME=/oracle/product/10.2.0/asmORA_CRS_HOME=/oracle/product/10.2.0/crs ORACLE_HOME=/u01/ oracle /product/app/10.2.0/db_1 2安装2.1 配置虚拟机(1)新建虚拟机,选择“高级”→“下一步”。

(2)选择8版本。

(3)如下选择操作系统。

(4)如下所示,填写虚拟机名称和位置。

、(5)内存1G。

(6)先不要添加网卡。

(7)创建第一块磁盘,作为系统盘60G。

(8)重命名虚拟磁盘名称。

(9)完成后进行定制,点击编辑虚拟机设置,首先添加第一块网卡,作为公共和VIP。

(10)选择NAT。

请事先查看本机的NAT虚拟网卡地址段再配置。

(11)接着添加第二块网卡,步骤与上相同,不过在网络连接处选择host-only。

作为私有IP。

(12)网卡添加完成。

(13)添加第一块硬盘,作为1/2块OCR磁盘。

(14)如下选择。

(15)容量500M。

(16)路径如下配置。

(17)完成,选择高级。

(18)设置虚拟设备节点为1:0。

(19)新增2/2块虚拟磁盘,方式与上相同,名称为ocr2.vmdk,节点为SCSI 1:1。

(20)添加1/2块voting 磁盘,500M,名称voting1.vmdk,SCSI 1:2。

(21)添加2/2块voting 磁盘,500M,名称voting2.vmdk,SCSI 1:3。

(22)添加1/4块ASM磁盘,10G,名称asm1.vmdk,SCSI 1:4。

(23)添加2/4块ASM磁盘,10G,名称asm2.vmdk,SCSI 1:5。

(24)添加3/4块ASM磁盘,5G,名称asm3.vmdk,SCSI 1:6。

(25)添加4/4块ASM磁盘,5G,名称asm4.vmdk,SCSI 1:7。

(26)添加1块备份磁盘,20G,名称back.vmdk,SCSI 2:0。

(27)最后结果如下:2.2 安装操作系统(1)虚拟机的光驱中加载ISO文件Enterprise-R4-U8-x86_64-dvd.iso(2)打开虚拟机电源进入OS安装界面。

(3)安装选择英文。

(4)分区方式如下选择。

(5)其他磁盘先不要创建分区。

(6)只编辑ETH0的IP地址和网关。

HOSTNAME: (7)关闭防火墙和SELinux。

(8)选择自定义安装包。

(9)选择SSH,TELNET,FTP,ORACLEASM,X WINDOW的包进行安装即可。

(10)正式开始安装。

(11)重启。

(12)ROOT用户登录后,安装VMware Tools。

(13)输入命令init 6重启,安装系统完成。

2.3 配置1 #节点环境(1)修改hosts。

127.0.0.1 localhost#public192.168.11.111 kei1192.168.11.112 kei2#private192.168.56.111 kei1-priv192.168.56.112 kei2-priv#virtual192.168.11.113 kei1-vip192.168.11.114 kei2-vip(2)vi /etc/security/limits.conf* s oft nproc 2047* h ard nproc 16384* s oft nofile 1024* h ard nofile 65536(3)vi /etc/pam.d/loginsession required /lib/security/pam_limits.so(4)cat /etc/selinux/config[root@kei-1 ~]# cat /etc/selinux/config# This file controls the state of SELinux on the system.# SELINUX= can take one of these three values:# enforcing - SELinux security policy is enforced.# permissive - SELinux prints warnings instead of enforcing.# disabled - SELinux is fully disabled.SELINUX=disabled# SELINUXTYPE= type of policy in use. Possible values are:# targeted - Only targeted network daemons are protected.# strict - Full SELinux protection.SELINUXTYPE=targeted(5)service iptables status[root@kei-1 ~]# service iptables statusFirewall is stopped.(6)vi /etc/modprobe.confoptions hangcheck-timer hangcheck_tick=30 hangcheck_margin=180(7)立即生效modprobe -v hangcheck-timer(8)创建目录并赋权[root@kei-1 u01]# mkdir app[root@kei-1 u01]# mkdir app/oracle[root@kei-1 u01]# mkdir app/oracle/product[root@kei-1 u01]# mkdir app/oracle/product/10.2.0[root@kei-1 u01]# mkdir app/oracle/product/10.2.0/asm[root@kei-1 u01]# mkdir app/oracle/product/10.2.0/crs[root@kei-1 u01]# mkdir app/oracle/product/10.2.0/db_1chown -R oracle:oinstall /u01(9)chkconfig rsh on(10)chkconfig rlogin on(11)[root@kei-1 10.2.0]# service xinetd reloadReloading configuration: [ OK ](12)切换oracle用户[root@kei-1 10.2.0]# su - oracle(13)编辑环境变量[oracle@kei-1 ~]$ vi .bash_profile# Oracle Settingsexport PS1="`/bin/hostname -s`-> "export EDITOR=viexport TMP=/tmpexport TMPDIR=$TMPexport ORACLE_BASE=/u01/app/oracle/product/10.2.0export ASM_HOME=/u01/app/oracle/product/10.2.0/asmexport ORA_CRS_HOME=/u01/app/oracle/product/10.2.0/crsexport ORACLE_HOME=/u01/app/oracle/product/10.2.0/db_1export ORACLE_SID=kei1export PATH=$ORA_CRS_HOME/bin:$ORACLE_HOME/bin:/usr/sbin:$PATHexport LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/libexport CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib export NLS_LANG= AMERICAN_AMERICA.ZHS16GBKalias sqlplus="kei sqlplus"alias rman="kei rman"stty erase ^Humask 022if [ $USER = "oracle" ]; thenif [ $SHELL = "/bin/ksh" ]; thenulimit -p 16384ulimit -n 65536elseulimit -u 16384 -n 65536fifi(14)source .bash_profile(15)init 0 关机。

相关文档
最新文档