Friday, January 31, 2014

Step by Step Oracle public yum server configutation

Oracle public yum server configutation

Step 1 :

Download and copy the appropriate yum configuration file in place, by running the following commands as root:

Oracle Linux 4, Update 6 or Newer

# cd /etc/yum.repos.d
# wget http://public-yum.oracle.com/public-yum-el4.repo

Oracle Linux 5

# cd /etc/yum.repos.d
# wget http://public-yum.oracle.com/public-yum-el5.repo

Oracle Linux 6

# cd /etc/yum.repos.d
# wget http://public-yum.oracle.com/public-yum-ol6.repo

Oracle VM 2

# cd /etc/yum.repos.d
# wget http://public-yum.oracle.com/public-yum-ovm2.repo


Step2 :

Enable the appropriate repository by editing the yum configuration file

    Open the yum configuration file in a text editor
    Locate the section in the file for the repository you plan to update from, e.g. [el4_u6_base]
    Change enabled=0 to enabled=1


Step 3:

[root@muthu yum.repos.d]# yum list unixODBC
Loading "security" plugin
el5_latest                100% |=========================| 1.4 kB    00:00
primary.xml.gz            100% |=========================|  18 MB    00:06
el5_latest: ################################################## 12671/12671
Installed Packages
unixODBC.x86_64                          2.2.11-7.1             installed
unixODBC.i386                            2.2.11-7.1             installed
Available Packages
unixODBC.x86_64                          2.2.11-10.el5          el5_latest
unixODBC.i386                            2.2.11-10.el5          el5_latest
[root@muthu yum.repos.d]#

Wednesday, January 29, 2014

Step by Step to Enable/Disable the Oracle Lable Security

How to Enable/Disable the Oracle Lable Security:


SQL> select INSTANCE_NAME, HOST_NAME, STARTUP_TIME, STATUS, to_char(sysdate, 'DD-MON-YYYY HH24:MI:SS') as current_date from gv$instance;

INSTANCE_NAME
----------------
HOST_NAME
----------------------------------------------------------------
STARTUP_TIME       STATUS       CURRENT_DATE
------------------ ------------ -----------------------------
PROD
hostname.domain.com
12-JAN-14          OPEN         29-JAN-2014 14:06:31


SQL> SELECT VALUE FROM V$OPTION WHERE PARAMETER = 'Oracle Label Security';

VALUE
----------------------------------------------------------------
FALSE

SQL> exit

[orprod@##### trace]$ chopt enable lbac

Writing to /u01/PROD/oracle/db/tech_st/11.2.0/db_1/install/enable_lbac.log...
/usr/bin/make -f /u01/PROD/oracle/db/tech_st/11.2.0/db_1/rdbms/lib/ins_rdbms.mk lbac_on ORACLE_HOME=/u01/PROD/oracle/db/tech_st/11.2.0/db_1
/usr/bin/make -f /u01/PROD/oracle/db/tech_st/11.2.0/db_1/rdbms/lib/ins_rdbms.mk ioracle ORACLE_HOME=/u01/PROD/oracle/db/tech_st/11.2.0/db_1

[orprod@##### trace]$ chopt disable lbac

Writing to /u01/PROD/oracle/db/tech_st/11.2.0/db_1/install/disable_lbac.log...
/usr/bin/make -f /u01/PROD/oracle/db/tech_st/11.2.0/db_1/rdbms/lib/ins_rdbms.mk lbac_on ORACLE_HOME=/u01/PROD/oracle/db/tech_st/11.2.0/db_1
/usr/bin/make -f /u01/PROD/oracle/db/tech_st/11.2.0/db_1/rdbms/lib/ins_rdbms.mk ioracle ORACLE_HOME=/u01/PROD/oracle/db/tech_st/11.2.0/db_1

[orprod@##### trace]$sqlplus "/as sysdba"

SQL*Plus: Release 11.2.0.3.0 Production on Wed Jan 29 14:15:25 2014

Copyright (c) 1982, 2011, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, Oracle Label Security,
OLAP, Data Mining and Real Application Testing options

SQL> SELECT VALUE FROM V$OPTION WHERE PARAMETER = 'Oracle Label Security';

VALUE
----------------------------------------------------------------
TRUE

SQL>

Wednesday, January 8, 2014

ORA-00845: MEMORY_TARGET not supported on this system



SQL> ALTER SYSTEM SET SGA_TARGET=8G scope=spfile;

System altered.

SQL> alter system set SGA_MAX_SIZE=8G scope=spfile;

System altered.

SQL> startup nomount
ORA-01078: failure in processing system parameters
ORA-00838: Specified value of MEMORY_TARGET is too small, needs to be at least 7184M
SQL> exit

SQL> alter system set memory_target=8208M scope=spfile;

System altered.

SQL> alter system set memory_max_target=8208M scope=spfile;

System altered.

SQL> startup nomount
ORA-00845: MEMORY_TARGET not supported on this system
SQL> exit
Disconnected


$ df -h |grep /dev/shm
Filesystem            Size  Used Avail Use% Mounted on
tmpfs                 7.4G  176M  7.2G   3% /dev/shm

FIX:-

$ mount -o remount,size=9G /dev/shm


$ df -h |grep /dev/shm
Filesystem            Size  Used Avail Use% Mounted on
tmpfs                 9.0G  8.2G  851M  91% /dev/shm


SQL> show parameter sga;

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
lock_sga                             boolean     FALSE
pre_page_sga                         boolean     FALSE
sga_max_size                         big integer 8G
sga_target                           big integer 8G