Gavinsoorma.com



Notes on how to create an Oracle Linux 6.8 VM on VirtualBox for the Oracle RAC 12c Workshop Download and install VirtualBox the Linux 6 Update 8 software from the Oracle Software Delivery Cloud Oracle VirtualBox and create the VM rac01 The machine will be created with a 40 GB root partition and 4.3 GB memory allocation. Note: this assumes available machine memory to be 16 GB.If 8 GB RAM is only available, set the VM memory size to 2500 MB.Check subnet for Host-Only adapter is 192.168.56Mount the Linux installation software using the .iso file we downloaded earlierConfigure Network AdaptersWe will use 3 network adapters for the VM network:One to communicate with the host directly from client (like putty) One for host to host internal communication (RAC Interconnect)One for external internet connectivity (to download RPMs via yum)Note – on some machines to get internet connectivity from VM we need to use NAT instead of Bridged Adapter.Configure shared foldersThe shared folder will enable us to copy any downloaded files like software between our local machine and the VM. In this case I have shared the drive and directory C:\software. Files in this directory will be visible in the Linux VM in the /media/sf_software location. The share name is ‘software’.Ensure it is set to Auto-mount.Install the Linux 6 Update 8 Operating SystemNote – use the Right Ctrl key to navigate out of the VM installation screen if required.Click on Yes, discard any dataNetworksEnter hostname rac01.localdomain and click on Configure Network Highlight System eth0 entry and click on Edit…Ensure to check the box Connect automatically and clink on the IPV4 Settings tab.Change the Method to Manual from Automatic (DHCP) and click on AddEnter the IP address for the rac01 VM public network – 192.168.56.100. Enter Netmask and Gateway as shown and click Apply…Highlight System eth1 entry and click on Edit…Change the Method to Manual from Automatic (DHCP) and click on AddEnter the IP address for the rac01 VM private network – 192.168.10.100. Enter Netmask and Gateway as shown and click Apply…Ensure to check the box Connect automaticallyRegion and Time Zone SettingRoot Password (keep a note!)Click Format Click Write changes to disk Click on Customize now Select all the options in the Desktops groupSelect option Internet BrowserSelect option Development toolsClick RebootClick No thanks, I’ll connect later.Install VirtualBox Guest AdditionsRun as root # yum update Click OKEnable sharing of Clipboard and Drag and Drop Configure the rac01 VM for Oracle Grid Infrastructure 12c Installation Ensure internet connectivityInstall the oracle-rdbms-server-12cR2-preinstall RPM[root@rac01 ~]# yum install oracle-database-server-12cR2-preinstall -yLoaded plugins: refresh-packagekit, security, ulninfoSetting up Install ProcessResolving Dependencies--> Running transaction check---> Package oracle-database-server-12cR2-preinstall.x86_64 0:1.0-3.el6 will be installed……Installed: oracle-database-server-12cR2-preinstall.x86_64 0:1.0-3.el6 Dependency Installed: compat-libcap1.x86_64 0:1.10-1 compat-libstdc++-33.x86_64 0:3.2.3-69.el6 ksh.x86_64 0:20120801-37.el6_9 libaio-devel.x86_64 0:0.3.107-10.el6 CompleteInstall the oracleasm-support RPM# [root@rac01 ~]# yum install oracleasm-supportLoaded plugins: refresh-packagekit, security, ulninfoSetting up Install ProcessResolving Dependencies--> Running transaction check---> Package oracleasm-support.x86_64 0:2.1.10-4.el6 will be installed--> Finished Dependency ResolutionDependencies Resolved============================================================================================================================================================== Package Arch Version Repository Size==============================================================================================================================================================Installing: oracleasm-support x86_64 2.1.10-4.el6 public_ol6_latest 76 kTransaction Summary==============================================================================================================================================================Install 1 Package(s)Total download size: 76 kInstalled size: 225 kIs this ok [y/N]: yDownloading Packages:oracleasm-support-2.1.10-4.el6.x86_64.rpm | 76 kB 00:00 Running rpm_check_debugRunning Transaction TestTransaction Test SucceededRunning Transaction Installing : oracleasm-support-2.1.10-4.el6.x86_64 1/1 Verifying : oracleasm-support-2.1.10-4.el6.x86_64 1/1 Installed: oracleasm-support.x86_64 0:2.1.10-4.el6 Complete!Download and install the oracleasmlib RPM.[root@rac01 ~]# cd /media/sf_software/ [root@rac01 sf_software]# ls *asm*oracleasmlib-2.0.12-1.el6.x86_64.rpm[root@rac01 sf_software]# rpm -ivh oracleasmlib-2.0.12-1.el6.x86_64.rpm Preparing... ########################################### [100%] 1:oracleasmlib ########################################### [100%][root@rac01 sf_software]#Create the grid user [root@rac01 sf_software]# /usr/sbin/groupadd -g 54331 asmadmin[root@rac01 sf_software]# /usr/sbin/groupadd -g 54332 asmdba[root@rac01 sf_software]# /usr/sbin/groupadd -g 54333 asmoper[root@rac01 sf_software]# /usr/sbin/useradd -g oinstall -G asmdba,dba,asmadmin,asmdba,asmoper,vboxsf gridConfigure ASMlib[root@rac01 sf_software]# /usr/sbin/oracleasm configure -iConfiguring 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 []: gridDefault group to own the driver interface []: asmadminStart Oracle ASM library driver on boot (y/n) [n]: yScan for Oracle ASM disks on boot (y/n) [y]: Writing Oracle ASM library driver configuration: done[root@rac01 sbin]# /usr/sbin/oracleasm initCreating /dev/oracleasm mount point: /dev/oracleasmLoading module "oracleasm": oracleasmConfiguring "oracleasm" to use device physical block sizeMounting ASMlib driver filesystem: /dev/oracleasm[root@rac01 sbin]# /usr/sbin/oracleasm statusChecking if ASM is loaded: yesChecking if /dev/oracleasm is mounted: yesCreate the directory for the 12c Grid Infrastructure installation[root@rac01 sf_software]# cd /[root@rac01 /]# mkdir u01[root@rac01 /]# cd u01[root@rac01 u01]# mkdir app[root@rac01 u01]# chown grid:oinstall appConfigure the oracle and grid OS user accounts[root@rac01 u01]# /usr/sbin/usermod -g oinstall -G dba,asmadmin,asmdba,vboxsf oracle [root@rac01 u01]# passwd oracleChanging password for user oracle.New password: BAD PASSWORD: it is based on a dictionary wordBAD PASSWORD: is too simpleRetype new password: passwd: all authentication tokens updated successfully.[root@rac01 u01]# passwd gridChanging password for user grid.New password: BAD PASSWORD: it is based on a dictionary wordBAD PASSWORD: is too simpleRetype new password: passwd: all authentication tokens updated successfully.Configure /etc/hosts file[root@rac01 u01]# vi /etc/hosts127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4192.168.56.100 rac01.localdomain rac01192.168.56.101 rac02.localdomain rac02Check the network IPs are correct via ifconfigNote that the IP entry for eth2 will differ as this is the IP of your internet provider.[root@rac01 u01]# ifconfigeth0 Link encap:Ethernet HWaddr 08:00:27:ED:5A:42 inet addr:192.168.56.100 Bcast:192.168.56.255 Mask:255.255.255.0 inet6 addr: fe80::a00:27ff:feed:5a42/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:32 errors:0 dropped:0 overruns:0 frame:0 TX packets:13 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:2880 (2.8 KiB) TX bytes:1008 (1008.0 b)eth1 Link encap:Ethernet HWaddr 08:00:27:1D:A8:8B inet addr:192.168.10.100 Bcast:192.168.10.255 Mask:255.255.255.0 inet6 addr: fe80::a00:27ff:fe1d:a88b/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:18 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:0 (0.0 b) TX bytes:1308 (1.2 KiB)eth2 Link encap:Ethernet HWaddr 08:00:27:EF:D8:C1 inet addr:10.1.1.24 Bcast:10.1.1.255 Mask:255.255.255.0 inet6 addr: fe80::a00:27ff:feef:d8c1/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:2199 errors:0 dropped:0 overruns:0 frame:0 TX packets:68 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:368359 (359.7 KiB) TX bytes:11124 (10.8 KiB)lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:12 errors:0 dropped:0 overruns:0 frame:0 TX packets:12 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:720 (720.0 b) TX bytes:720 (720.0 b)Set Security Enhanced Linux (SELINUX) to disabled as we are not enabling any firewall traffic[root@rac01 u01]# vi /etc/selinux/configSELINUX=disabledStop NTP daemon(if they are running) as we will be using Cluster Time Synchronization Service instead[root@rac01 u01]# service ntpd stopShutting down ntpd: [FAILED][root@rac01 u01]# chkconfig ntpd off[root@rac01 u01]# mv /etc/ntp.conf /etc/ntp.conf.orig[root@rac01 u01]# rm /var/run/ntpd.pidrm: cannot remove `/var/run/ntpd.pid': No such file or directoryDisable Firewall[root@rac01 ~]# service iptables stopiptables: Setting chains to policy ACCEPT: filter [ OK ]iptables: Flushing firewall rules: [ OK ]iptables: Unloading modules: [ OK ][root@rac01 ~]# chkconfig iptables offEdit /etc/resolv.conf[root@rac01 rpm]# cat /etc/resolv.conf # Generated by NetworkManagersearch localdomainnameserver 10.1.1.1Change to[root@rac01 rpm]# vi /etc/resolv.conf # Generated by NetworkManageroptions timeout:3 search localdomain rac.localdomainnameserver 192.168.56.102[root@rac01 rpm]# chattr +i /etc/resolv.conf[root@rac01 app]# nslookup rac01Server:192.168.56.102Address:192.168.56.102#53Name:rac01.localdomainAddress: 192.168.56.100[root@rac01 app]# nslookup rac-gnsServer:192.168.56.102Address:192.168.56.102#53Name:rac-gns.localdomainAddress: 192.168.56.150Configure limits.conf file[root@rac01 ~]# vi /etc/security/limits.conforacle soft nproc 2047oracle hard nproc 16384oracle soft nofile 1024oracle hard nofile 65536grid soft nproc 2047grid hard nproc 16384grid soft nofile 1024grid hard nofile 65536grid soft stack 10240oracle soft stack 10240Shutdown the VM[root@rac01 rpm]# shutdown -h nowCreate a backup .ova file Click on Export Clone the rac01 VM and create the second VM rac02Ensure we do not check the box to Reinitialize the MAC address!Change the hostname[root@rac01 ~]# vi /etc/sysconfig/networkNETWORKING=yesHOSTNAME=rac02.localdomain# oracle-rdbms-server-12cR1-preinstall : Add NOZEROCONF=yesNOZEROCONF=yes[root@rac01 ~]# hostname rac02.localdomainEdit and Update the Network IP addresses on the cloned VMSystem > Preferences > Network Connections menu Original MAC address Change the original MAC address by replacing last two characters with ‘00’. Click Apply…Change the public IP address from 192.168.56.100 to 192.168.56.101.Similarly change the MAC address for eth1 and eth2 and also the private IP address for eth1 as shown.Rename 70-persistent-net.rules file as it will be regenerated on next VM start[root@rac01 ~]# cd /etc/udev/rules.d[oracle@rac01 rules.d]$ mv 70-persistent-net.rules 70-persistent-net.rules.oldShutdown the cloned VM[root@rac01 rules.d]# shutdown -h nowDisable the 3rd network adapter as we will not need external internet connectivity from the cloned rac02 VMFor Adapter 1 and Adapter 2 update the MAC address replacing the last two characters with ‘00’Disable the Adapter 3 for rac01 VM as well as we do not need any internet connectivity anymoreStart both rac01 and rac02 VMsConnect as root and check connectivity between both rac01 and rac02 for both the public as well as private networksConnect to rac02 and carry out the same ‘ping’ check to confirm connectivity with rac01.Also confirm the network IPs on rac02. ................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download