Friday, February 18, 2011

Oracle Access Manager Installation

Secured Coding Standards

Identity Management Certifications & Trainings

Linux Commands

  • find / -name "filename.extn"
  • find . -name "filename.extn"
  • grep *pattern* filename
  • du -sh *
  • df -k
  • top (command to see process)
  • ps -eaf | grep keyword
  • cat /etc/
  • rm -rf directory-name (delete folder recursively and forcefully)
  • uname -a (to know os details)
  • cat /etc/redhat-release (to know red hat version)
  • rpm -qf /etc/redhat-release (to know the OEL version)
  • rpm -ivh package-name.rpm
  • scp /home/oracle/Desktop/WebLogicServer11gR1_10.3.4.zip oradb@remote.machine.host.name:/home/oradb/
  • sudo su -

Weblogic Logs

$BEA_HOME/user_projects/domains/base_domain/config/fmwconfig/servers/logger.xml
$BEA_HOME/user_projects/domains/base_domain/servers/new_ManagedServer_1/logs
/new_ManagedServer_1.log

How to increase no. of sessions in oracle database?

If you are increasing sessions parameter you should consider increasing processes and transactions parameter as well.

Here is the formula you can use to determine their values.
processes=x
sessions=x*1.1+5
transactions=sessions*1.1

E.g.
processes=500
sessions=555
transactions=610


Commands:-
sqlplus "/as sysdba"
or
sqlplus '/as sysdba'


sql> show parameter sessions
sql> show parameter processes
sql> show parameter transactions

sql> alter system set processes=500 SCOPE=SPFILE;
sql> alter system set sessions=555
SCOPE=SPFILE;
sql> alter system set transactions=610
SCOPE=SPFILE;

and Restart the database.

Oracle DB 11g Uninstallation

In order to uninstall Oracle Database 11g go to "deinstall" directory in $ORACLE_HOME:

echo
$ORCALE_HOME

/u01/app/oracle/product/11.2.0

cd $ORACLE_HOME/dbhome_1/deinstall

#run deinstall script (none a graphical):
sh deinstall



Source: http://www.emarcel.com/emarcel/database/114-uninstalldb11g

Connecting Remote DB - SQL Command

sqlplus sys/oracle@:/ as sysdba
eg:sqlplus sys/oracle@10.20.30.40:1521/orcl.idc.raza.com as sysdba

Oracle Auto DB Startup setup

I was able to configure the Auto DB start successfully following this link AutomatingDatabaseStartupAndShutdownOnLinux in DIT box and now every thing seems to be working fine..

Just an overview of what I have done, in 4 steps...as it may help

Step1 : edit file "/etc/oratab" and set the restart flag to Y for DB instance "orcldit"

orcldit:
/home/platform-idc/app/platform-idc/product/11.2.0/dbhome_3:Y

Step2.
Created a dbora file under /etc/init.d as the root user
#!/bin/sh
# chkconfig: 345 99 10
# description: Oracle auto start-stop script.
#
# Set ORA_HOME to be equivalent to the $ORACLE_HOME
# from which you wish to execute dbstart and dbshut;
#
# Set ORA_OWNER to the user id of the owner of the 
# Oracle database in ORA_HOME.
 
ORA_HOME=/home/platform-idc/app/platform-idc/product/11.2.0/dbhome_3
 
ORA_OWNER=platform-idc
 
if [ ! -f $ORA_HOME/bin/dbstart ]
then
    echo "Oracle startup: cannot start"
    exit
fi
 
case "$1" in
    'start')
        # Start the Oracle databases:
        # The following command assumes that the oracle login 
        # will not prompt the user for any values
        su - $ORA_OWNER -c "$ORA_HOME/bin/dbstart $ORA_HOME"
        touch /var/lock/subsys/dbora
        ;;
    'stop')
        # Stop the Oracle databases:
        # The following command assumes that the oracle login 
        # will not prompt the user for any values
        su - $ORA_OWNER -c "$ORA_HOME/bin/dbshut $ORA_HOME"
        rm -f /var/lock/subsys/dbora
        ;;
esac


Step 3. chmod 750 /etc/init.d/dbora

Step 4. chkconfig --add dbora ........

After that restarted the linux and could see during the linux boot up the DB instance is also gets started...From 10g onwards the dbstart will in turn start the TNSlinstener, so we do NOT explicitly need to start that.

---------------------------------------Other ----------------------------------------------------

We had some issues with EM/DBconsole and had to redo this to get that up..
re-configure em completely

emctl stop dbconsole 
emca -repos drop 
emca -repos create 
emca -deconfig dbcontrol db 
emca -config dbcontrol db