Friday, 30 September 2016

Oracle Database 12C Release 1 Installation on Linux


Oracle 12c (Oracle 12.1.0.1) has been released and is available for download . Oracle 12C Installation steps are almost  same as  that  of   Oracle 10g and 11g Installations  . Oracle  12c  is  available  for  64 bit . Here , we will see step-by-step Installation of Oracle 12C database .  

Step  1 :  Oracle S/W Installation
We can download Oracle 12c  s/w from e-delivery or from OTN .  Below are Link

http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html
https://edelivery.oracle.com/EPD/Download/get_form?egroup_aru_number=16496132


Step 2 :  Hardware Requirements 
Oracle Recommand the following requirement for installation . 
RAM     =  2GB of RAM or more
Swap    = 1.5 times of RAM if RAM less than 2 GB , equal to size of RAM is RAm size is more than 2GB
Disk Space      = More than 6.4 GB for Enetrprise Edition .
Tmp directory  =  Minimum 1GB of  free space


Step 3 :  Hardware Verifications 
[root@server1 ~]# grep  MemTotal   /proc/meminfo
MemTotal:      3017140 kB

[root@server1 ~]# grep  SwapTotal   /proc/meminfo
SwapTotal:     4105420 kB

[root@server1 ~]# df  -h  /tmp
Filesystem            Size    Used     Avail     Use%     Mounted on
/dev/sda1              46G   19G      25G       44%          /

[root@server1 ~]# df  -h 
Filesystem            Size       Used     Avail      Use%      Mounted on
/dev/sda1              46G      19G       25G       44%          /
tmpfs                    1.5G       0          1.5G       0%           /dev/shm
/dev/hdc              3.4G       3.4G        0        100%         /media/RHEL_5.3 x86_64 DVD

[root@server1 ~]#  free
                  total           used           free           shared    buffers     cached
Mem:       3017140     715376    2301764          0       109776     384096
-/+ buffers/cache:        221504    2795636
Swap:      4105420          0         4105420

[root@server1 ~]# uname  -m 
x86_64

[root@server1 ~]# uname  -a 
Linux   server1.example.com      2.6.18-128.el5 #1    SMP    Wed    Dec 17 11:41:38 EST   2008    x86                                                                                        
_64 x86_64 x86_64      GNU/Linux


Step 4 :  Packages Verifications 
The  following  packages  are  required  for  the  Oracle  Installation , so  make  sure  all  the  packages are installed .

make-3.81
binutils-2.17.50
gcc-4.1.2                       (x86_64)
gcc-c++-4.1.2               (x86_64)
compat-libcap1              (x86_64)
compat-libstdc++-33     (x86_64)
glibc-2.5-58                   (x86_64)
glibc-devel-2.5               (x86_64)
libgcc-4.1.2                    (x86_64) 
libstdc++-4.1.2               (x86_64)  
libstdc++-devel-4            (x86_64)  
libaio-0.3.106                  (x86_64)
libaio-devel-0.3               (x86_64) 
ksh 
sysstat  
unixODBC  
unixODBC-devel
Execute  the  below command  as  root  to  make  sure  that  we  have  all  this  rpms  installed. If  not installed,  then  download  them   from  appropriate  linux  site or  we will  find  the  package from  the Red Hat Enterprise Linux 5 DVD . For example , 
# rpm  -qa  | grep  glib* 

The  above  command  will  display  all  the  installed  packages,  name  starting  with   glib,  similarly  we  can  check  for  all  others  packages . If  any of  the  above  packages  are  not  installed, run  the  following command:
rpm  -ivh  
.i386.rpm


Steps 5  :  Kernel Parameters
Add the below kernel Parameters in the  /etc/sysctl.conf  file

fs.file-max = 6815744
kernel.sem = 250 32000 100 128
kernel.shmmni = 4096
kernel.shmall = 1073741824
kernel.shmmax = 
2147483648
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576
fs.aio-max-nr = 1048576
net.ipv4.ip_local_port_range = 9000 65500
After  adding these  lines  to  /etc/sysctl.conf , run  the  below command  as  root  to  make  them  enabled.
 #  sysctl   -p 


Step 6 :  Edit the /etc/security/limits.conf file
To  improve the  performance  of   the  software  on  Linux  systems, we  must  increase  the  following  shell limits   for  the  oracle  user . Add  the  following  lines  to the  /etc/security/limits.conf  file :

oracle    soft  nproc  2047
oracle    hard  nproc  16384
oracle    soft  nofile  1024
oracle    hard  nofile  65536
Where  "nproc"  is  the maximum  number  of  processes  available to  the  user  and  "nofiles"  is  the  number  of  open  file  descriptors.


Step 7  :  Create User and Groups 
Starting  with  Oracle  Database  12c , we  can  create  new  administrative  privileges  that  are  more  task-specific  and  less  privileged  than  the  OSDBA/SYSDBA  system privileges  to support specific administrative  privileges  tasks  required  for  everyday  database  operation. Users  granted  these  system privileges  are  also  authenticated  through operating system group membership .

We  do  not  have to  create  these  specific  group  names, but  during  installation we  are  prompted  to provide  operating  system  groups  whose  members  are  granted  access  to  these  system  privileges.  we  can  assign  the same  group  to  provide  authentication  for  these  privileges, but  Oracle  recommends  that we  should  provide  a  unique  group  to  designate each  privileges.

i .) The OSDBA group (typically, dba)  :  This group identifies operating system user accounts that have database administrative privileges (the SYSDBA privilege).
#groupadd  -g  501  dba  
ii .) The Oracle Inventory Group (oinstall) :  This group owns the Oracle inventory that is a catalog of all Oracle software installed on the system. A single Oracle  Inventory group is required for all installations of Oracle software on the system.
groupadd  -g  502  oinstall  
iii .) The OSOPER group for Oracle Database (typically, oper)  :  This  is an optional  group. We  create  this  group  if  we  want  a separate  group of  operating  system  users  to  have a  limited  set  of database  administrative  privileges  for  starting  up  and shutting  down the  database  (the SYSOPER privilege). 
groupadd  -g  503  oper  

iv .) The OSBACKUPDBA group for Oracle Database (typically, backupdba)  :   Create this group if we  want a  separate  group of  operating  system  users  to  have a  limited  set  of database backup and recovery related administrative privileges (the SYSBACKUP privilege).
# groupadd   -g   504   backupdba 
v .) The OSDGDBA group for Oracle Data Guard (typically, dgdba)  :   Create  this  group  if  we want  a  separate  group of  operating  sytsem  users to  have a  limited  set of   privileges  to  administer  and monitor  Oracle Data Guard  (the SYSDG privilege).
# groupadd   -g   505   dgdba 
vi .) The OSKMDBA group for encyption key management (typically, kmdba)   :  Create  this  group if  we  want  a  separate group  of  operating  sytem  users  to have a  limited  set  of  privileges  for encryption  key  management  such  as Oracle  Wallet  Manager  management  (the SYSKM privilege).
#  groupadd   -g   506   kmdba  
vii .) The OSDBA group for Oracle ASM (typically, asmdba) :   The  OSDBA  group  for  Oracle ASM can  be  the  same group u sed as  the OSDBA  group  for  the database, or we  can  create a separate OSDBA group for Oracle ASM to provide administrative access to Oracle ASM instances .
# groupadd  -g  507   asmdba 
viii .) The OSASM group for Oracle ASM Administration (typically, asmadmin)  :  Create  this  group as  a  separate group if  we  want  to  have  separate  administration  privileges  groups  for  Oracle  ASM and Oracle  Database  administrators. Members  of  this  group  are  granted  the  SYSASM  system privileges  to  administer  Oracle ASM  .
 groupadd  -g   508   asmoper
ix .)  The OSOPER group for Oracle ASM (typically, asmoper)  :   This is an optional group. Create this group  if  we  want  a separate  group of  operating  system  users  to  have  a limited  set  of  Oracle instance  administrative  privileges  (the SYSOPER for ASM privilege),  including starting up and stopping the  Oracle  ASM  instance . By default ,  members of  the OSASM group  also  have all privileges granted by the SYSOPER for ASM  privilege.
groupadd   -g   509  asmadmin 

x . ) Create Oracle user  :
useradd -u 54321 -g oinstall -G dba,asmdba,backupdba,dgdba,kmdba  oracle
#passwd oracle
<>
The  -u  option  specifies  the  user  ID. Using  this  command  flag  is optional  because the system can provide  with  an  automatically  generated  user  ID  number. However,  Oracle  recommends  that  we should specify a number. We must note the user ID number because we need it during preinstallation.


Step 8 :  Creating oracle directories 
As  per  OFA, oracle base directory has  the  path  :  /mount_point/app/oracle_sw_owner  where mount_point   is  the mount  point directory  for  the  file system  that  will  contain  the  Oracle software . I have  used  /u01  for  the mount point  directory. However, we  could  choose  another  mount point directory,  such  as  /oracle or /opt/soft.
# mkdir -p /u01/oracle/product/12.1.0/db_1
# chown -R oracle:oinstall /u01
chmod -R 777 /u01


Step 9 :  Setting Oracle Enviroment 
Edit  the  /home/oracle/.bash_profile  file and  add  following  lines:
su - oracle
$ vi  .bash_profile
export TMP=/tmp
export TMPDIR=$TMP
export ORACLE_BASE=/u01/oracle
export ORACLE_HOME=$ORACLE_BASE/product/12.1.0/db_1
export PATH=/usr/sbin:$PATH
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib


Step 10  :   Check firewall and Selinux  
Make sure Selinux be either disable or permissive . Check "/etc/selinux/config" file and make following changes .
SELINUX=permissive
Once ,Selinux value is set than restart the server or or run the below command
setenforce Permissive

If  Firewall is enabled ,we need to disable it . we can disable by using below command
service iptables stop
chkconfig iptables off


Step 11 :  Finally run the runInstaller for Installation of  Oracle 12c release 1

https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhtQKXrhmTvVwD_xu88GB_1ZzDAiY6gT5fmuxeGOaQXPEbSpBZYuLQRHY4jVccW57q2VMIshcSk7sXXkQXdzLGKTaOvbD6RFsPtwEPFe1Kz6UvP3Fv_W1lvyK78JyNBY4xkKwh6aVO_qaX6/s640/000001.PNG


Once ,  runInstaller get initaited , OUI get invoked and rest are interative graphical console .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg-CxI3Y21PykwGd68YLY8cm1AeaBnMTMllHIiffdUe0eCnVLNVB0YOwjaH23oqfDF_DIiUXSrdjnEiyoQtgWrso4qjDwnQq7i7kYpiAyyonX1bo4HR5JZXOlhh1SuOqsUZi0IC5UQ1qaLc/s640/1.PNG

Click next and proceed forward .

https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhzrRjTUiGo0Ul11eIGq1g_1nU1zSyXZMPZ_mgMH3hUhykr2ALPpQw0bT_4-JxSdMhVNhIgXsgVtE-2zU2R5K2gAZyBkHsDUO81aA9pgZe8R49rUbbuRP-VNHFPJp3Kj2FajV2h8N-yLYLY/s640/2.PNG

Click  on "Yes"  button and proceed .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHjZwdmXr3SG6UntqD3V_UW3i3CyRZ3nzzep5TO3SNQSRpDG_ujvndreY6KEuZNrHVpAgXrtmQUS3g0-uOOFQOJn-avJ6cM64QCQuf6hxCyMILPTe5GtiYGWF42C9xBJHhdZi1394WI25A/s640/4.PNG

Select "Skip Software Updates" option and click on next button .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj5gk9CEwrCklGe0SU28bo1Ohrwkt0R9Ul1iyePxBl8JYnIgmyEcb4D2uEHAF1B3rHDQzwBRRYIvwqgiF0sneFGkxvr3LJVm9b9ORX_eGxOlRpCQ02AvqqnkiG1Kkr4VdlEzqMHfy9O3Pga/s640/4_1.PNG

Select  "Create and configure a database" option and click on next button
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjj6xZP7Ky5Vk1UWeaZFRzN5JuFOxBkQzC8jXT1g8QMVU6NqjMAr-usDUZMwK_YZUMcrmAyQWahMpxnS4agw1P53gM2OKuuOepX0CPowGctm6zur9SR7YUV_ZAJ6R0PE7bDWNeGWS_lfFhe/s640/5.PNG

Here , I selected the "Desktop Class" option . Click on next button
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhq5vV_NNTznuHtPiZB8ao9NdhPQpOiN0ZxKVVXclogHYoMNuIubDztAvZoftmdyVvoqAAWZN7MYSDhihmREse00k4F6NQmDfWhNZU39dlteS63hdyhbyE0BmO3VThvMFQ4sXWzn0CfMVE2/s640/6.PNG

Enter the Administrative Password and click next
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjHDPJ_biX3cbph-65WOo0EJHnHVbU7XS1UgNosmHEHC8kasK61jRHCT8YL2BT0Gkz3zIzmyKlS8HVJkvJ6AKf62ccJwD_9zFwot9DuqD-XVUOV8z6bRSB5_yvo2D25ljfQdPN0esB4k7P_/s640/7.PNG

Click on "Yes" option and proceed forward
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj4PObb00dyOs-5FMwucAdX0A0vwnol7aP6vpFmNlgJMV7o8dzPsPkcy4ybBaVclc79VbvR5VvPCGKp0BeKSPwc2pggnZn2FDyYqNtIHOPZ0tO8R0TGQ_3QqsWTanybbtCG2BQOTVjISGDk/s640/8.PNG

Click on next button
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihakcC0MqVqDMCxIHq2tWh9o3NeFBeBnabAgSIgDjDztJ7SpIMCF424AM71cCG4FvSftGd2IV53SJ0jtjRPL_-Kv7P1Do0bWkZ5S_Sos6eVjAxzGNy9ojduGl1S9rN7V_8omUi8rwhx1OC/s640/9.PNG

Make sure all the prerequisite must be successfull and passed  .
 
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgak155-tVWN7h1Reo06HofB72hZvGNpVTdxEFicIL877gYgi9TiuOfySf2ItN7UcsYdZwfJWAg1LmKTY_d4KIcUYXx6iFF0CRM4k59fYZdAIozANld8f1KITP7Y8niI0pChLlc9902ujbi/s640/13.PNG

Summary page displays all the locations and database information . Click next
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgxHIBigFlIgiuBbS_MJ9bWSyoh_JupgrDFiEKiJyfcuRl3XWHUoZwpwmlaovW7jXG3wNDxNBSrEknHQciAb-V3qbgGEhNonI2L0x4hbLoz-Xqu__j5Bpx65n0W5Qw4bKGxsGEwp6l56tCx/s640/14.PNG

Oracle Database Installation in process
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgC9bCev0u1qSvmYSKjr_7AJEWB1YKXq347s7wv-y1Ancbl12HOIWcdKD4jSGLmZavmOSuE-5-3ULZkXhl7KWpJQpO2nqJivS_xcrQuL9GgpRp6SS0R773nWTDBcpZIegHcTLfvT_X4EB5N/s640/15.PNG

Execute the configurations scripts from root
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhA6s-Rf8GYLVxdTBpqVt3apI6b1YHVsrtaq_ot5NSRLrNHEQ15kW8ap2DsquiXi7rWOfMhVTT1GPafx9H3mp_2mUQdj2mQFQ3rUYMIHIpaRdeCveSIzox2gF7QnfHtSoyC_y3nzIH4uFx8/s640/16.PNG

Run the scripts from root .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgW5AcPtiy7UvQ0hglPPA7SykmJPSoo_LKjpCcFu0ycB9pIGa5Gy3r4Byer2da2Y9oU_9uRx_jihdzT0CX24QfLNMx67TU5th4wdnPFXRILG4kb2n26-__O1G0SWtq9xIBxwBSmaisQpUB8/s640/17.png

Oracle Database in process
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZW8uXkXksy9QbUwgZUnhdEUHqXUDUfbHmEU46gFQ_kteYMIkNnmr-6AGFTcwBplVB_nALy2RmSTO5z5V_JDAyTjszCLDLBqfsTBd7tYmiVcQkMPvkbxcg7r4ZPBZ_HmomFwwe9t_vW4CG/s640/18.PNG

Database creation in process .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPBkS4pa84tYPci5iVtFV9QuuiQj8_dbYGhsmIjYBVqt-882Gmit5W3Ogoco9CDLbaypz0V3fi4WYxICb9ol-3bUzDmr6KZqHoyqd8ciMtBsHs2plaleueOMreFPgzB8ziuwO_erMtYgSD/s640/19.PNG

Database creation in process .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhAi9094-a05qNd-kFGlKch3Ul3TC5qZNghJ2_GRCKrF7rmiqQ476vvWmR_Z4CXTSJVhSF1xTkJ90Ny2Mktr4FPe1pZPTwepe7cPvfzaIzSu_qnZEUiNBWjhiyIx82ZAvOHiQ2729tsOAov/s640/20.PNG

https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiPIikRSr8ed_IuzwjTtrlkRFRDfVyJapW1fbFkR2812ldnvpd1UM6Nr4YRkOzMHzgijaMsZIrrM1ayMJGcKZobd4ftDOaSKhqg2ZnK_qYPMoiCDKTZqfRtY8E9TfgE_GrB4URSRbzVT94E/s640/21.PNG

Database Creation complted .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiYuupcepyYW_lP6N2juUVhtsADIUXn_eQuhXpnB227ux0-Bope9sADvOQnrtchSMMVTqODyftg3DNty1tlrfu1Quu0RnJAjgFCW4hFikD1cRgOkV_kUWjDi0UMDjZrgVwMIsNdREA7N-eQ/s640/22.PNG

Installation of Oracle database was successfull .
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjK6SeLzbTyvyv0O1plZyHsFUrPkG1s6p5d5AJ_Wwi-IDDi3pMSh6Z9kOGU788nCZwn8b3mzxTSilX44PZPEZYFn5wn6UbbfRxpl7ZreYvK0tWeVDZhFTh2Cohmpxt-Ouzet8854L_-BFsy/s640/23.PNG

Finally connected  with Oracle 12c database .


No comments:

Post a Comment