Oracle 11gR2 2-node RAC on VMware Workstation 8 – Part IV

Time Required: 20 minutes

Class Materials:

  • none

Next we need to create the Oracle user account, OS groups and mount point.

The Oracle software will be installed and owned by the oracle user account. In additional several OS groups are created that allow other non oracle OS users privileged access to the database and grid resources.

Login as root and create the user oracle account and the OS groups:

[root@localhost ~]# groupadd dba
[root@localhost ~]# groupadd oinstall
[root@localhost ~]# groupadd asmdba
[root@localhost ~]# groupadd asmadmin
[root@localhost ~]# useradd -g oinstall -G dba,asmdba,asmadmin oracle

Now set the password for the oracle user. Since this is development, I suggest we stick with “oracle”.

[root@localhost ~]# passwd oracle
Changing password for user oracle.
New UNIX password: 
BAD PASSWORD: it is based on a dictionary word
Retype new UNIX password: 
passwd: all authentication tokens updated successfully.

Now we create a directory into which the oracle software will be installed. We need to set this new directory to be owned by oracle:

[root@localhost ~]# mkdir /u01
[root@localhost ~]# mkdir /u01/app
[root@localhost ~]# chown oracle:dba /u01/app

Now we can log into our new oracle account and configure the bash profile:

[root@localhost ~]#  su - oracle
[oracle@localhost ~]$  vi ~/.bash_profile

Add the following lines to the profile script:

TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
ORACLE_HOSTNAME=`hostname`; export ORACLE_HOSTNAME
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_TERM=xterm; export ORACLE_TERM
PATH=/usr/sbin:$PATH; export PATH
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH

if [ $USER = "oracle" ]; then
  if [ $SHELL = "/bin/ksh" ]; then
    ulimit -p 16384
    ulimit -n 65536
  else
    ulimit -u 16384 -n 65536
  fi
fi

Our VM now has all the necessary RPMs, Kernel settings and Oracle account privileges to load Oracle 11gR2.

You might consider another clone of your VM at this point, or at least a snapshot to fall back to in the event of problems.

Article Quick Navigation
Previous Step Main Index Next Step
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s