RAC Attack - Oracle Cluster Database at Home/Create DB

Prev: RAC Install



Create Database (e)
  1. Create DB


Next: Rolling Patches



  1. ASM Databases Only: Login to a terminal as the oracle user. Use the oenv macro to set your environment for the SID +ASM1. Then, type asmca to launch ASMCA.

    collabn1:/home/oracle[RAC1]$ oenv
    SIDs here are: grid +ASM1 
    ORACLE_SID = [RAC1] ? +ASM1
    The Oracle base for ORACLE_HOME=/u01/grid/oracle/product/11.2.0/grid_1
      is /u01/app/oracle
     
    collabn1:/home/oracle[+ASM1]$ asmca
    


  2. ASM Databases Only: Verify that both diskgroups are mounted. If you have jumpstarted or rebooted, then the BACKUP diskgroup may be dismounted. To mount it, right click then choose Mount on All Nodes. Click EXIT to close the ASM Configuration Assistant.

    RA-asmca-dgmount.png


  3. Type ". oraenv" to setup the environment. Leave the default SID and enter /u01/app/oracle/product/11.2.0/db_1 for the ORACLE_HOME. Then type dbca to launch the Database Configuration Assistant.

    RA-dbca-splash.png
  4. At the first prompt, choose Real Application Clusters Database and click NEXT.

    RA-dbca-db-type.png
  5. Choose to CREATE A DATABASE then click NEXT to continue.

    RA-dbca-operations.png
  6. Select GENERAL PURPOSE OR TRANSACTION PROCESSING then click NEXT to continue.

    RA-dbca-template.png
  7. Choose Admin-Managed Database, Set the global database name to RAC.vm.ardentperf.com and select all cluster nodes. Then click NEXT to continue.

    RA-dbca-name.png
  8. Do not configure Enterprise Manager (there's probably not enough memory here). Uncheck it and click the Automatic Maintenance Tasks tab.

    RA-dbca-em.png
  9. Disable the automatic maintenance tasks (they can really tax the CPU on your laptop...) After unchecking the box, click NEXT to continue.

    RA-dbca-tasks.png
  10. Set all passwords to racattack and click NEXT to continue. Choose YES to continue even though Oracle doesn't like the password.

    RA-dbca-password.png
  11. Choose a Storage Type depending on which track of the RAC Attack lab you're doing.

    Oracle ASM Shared Filesystem
    Choose a Storage Type of Automatic Storage Management (ASM).

    RA-dbca-storage-asm.png
    Choose a Storage Type of Cluster File System.

    RA-dbca-storage-cfs.png
  12. Configure Oracle Managed Files.

    Oracle ASM Shared Filesystem
    Choose ORACLE MANAGED FILES and type +DATA for the database area. Then click NEXT to continue.

    RA-dbca-dbarea-asm.png
    Choose ORACLE MANAGED FILES and type /u51/oradata for the database area. Then click NEXT to continue.

    RA-dbca-dbarea-cfs.png
  13. Configure a Flash Recovery Area.

    Oracle ASM Shared Filesystem
    Choose to SPECIFY FLASH RECOVERY AREA and type +BACKUP as the destination. Increase the size to 3000 MBytes. Do not enable archiving and choose NEXT to continue.

    RA-dbca-fra-asm.png
    Choose to SPECIFY FLASH RECOVERY AREA and type /u52/oradata as the destination. Increase the size to 3000 MBytes. Do not enable archiving and choose NEXT to continue.

    RA-dbca-fra-cfs.png
  14. Choose to install the sample schemas. After checking the box, click NEXT to continue.

    RA-dbca-sample-schemas.png
  15. Bump the memory target up to 400MB and do not check Automatic Memory Management. Skip the other tabs and click NEXT to continue.

    RA-dbca-memory.png
  16. Accept the default storage settings and click NEXT to continue.

    RA-dbca-storage.png
  17. Go ahead and generate scripts (in the default location), but leave Create Database option checked. the Click FINISH to begin database creation.

    RA-dbca-creation-options.png
  18. Review the summary, then click OK to continue.

    RA-dbca-summary.png
  19. DBCA will inform you after it generates the scripts. Click OK to continue with database creation.

    RA-dbca-scripts.png


    RA-dbca-inprogress.png
  20. When database creation is complete a summary window will appear. Click EXIT to close the installer.

    RA-dbca-finished.png


    RA-dbca-sqlplus-confirm-open.png
  21. One last thing: edit /etc/oratab on both nodes and replace the DB name with the Instance name. Also edit the bash_profile on node 2 and set the instance name to RAC2.

    [oracle@collabn1 ~]$ vi /etc/oratab
    RAC1:/u01/app/oracle/product/11.1.0/db_1:N
    


    [oracle@collabn1 ~]$ ssh collabn2
    [oracle@collabn2 ~]$ vi /etc/oratab
    RAC2:/u01/app/oracle/product/11.1.0/db_1:N
    
    [oracle@collabn2 ~]$ vi /home/oracle/.bash_profile
    export ORACLE_SID=RAC2
    



Last modified on 5 April 2013, at 05:47