Saturday, October 2, 2010

adstrtal.sh: exiting with status 1

This is one of the messages i got while starting APPS tier of e-business suite.
I am new to this thing, so checked a few things. Logged onto the database , and tried to connect with apps user which was quite successful. Then i realized that may be listener is not up, and that was the culprit. So i started listener using command adalnctl.sh start PROD and once again started Apps tier which worked now!!

Friday, October 1, 2010

Alert tab of oracle Grid Control

We have grid control installed in one of our setups. This is quite useful as you can register all your databases here and monitor them from a centralized control. One of the good things i like about this is the alert tab. By clicking on the alert tab you can easily see all the errors coming in any of the databases whether they are ORA- errors or any other.
So another useful feature and observation from my side.

Thursday, September 30, 2010

DBMS_SCHEDULER

This is some task i did for the first time in one of my recent projects.
so just an another attempt to share my learning.
To create a scheduled job the syntax is -

begin
sys.dbms_scheduler.create_job(job_name => 'test_job',
job_type => 'PLSQL_BLOCK',
job_action => 'BEGIN DBMS_STATS.gather_schema_stats(''ABC''); END;',
repeat_interval => 'FREQ=DAILY;BYHOUR=21;BYMINUTE=45;BYSECOND=0',
start_date => sysdate,
job_class => 'DEFAULT_JOB_CLASS',
comments => 'gather stats job',
auto_drop => TRUE,
enabled => TRUE);
END;

Monday, September 27, 2010

initializing oracle ASMLib driver : FAILED , Loading module "oracleasm": Unable to load module "oracleasm"

I came across this problem recently while installing Oracle RAC on one of the systems.

[root@rac1]# /etc/init.d/oracleasm configure
Configuring the Oracle ASM library driver.

This will configure the on-boot properties of the Oracle ASM library
driver. The following questions will determine whether the driver is
loaded on boot and what permissions it will have. The current values
will be shown in brackets ('[]'). Hitting without typing an
answer will keep that current value. Ctrl-C will abort.

Default user to own the driver interface [oracle]: oracle
Default group to own the driver interface [dba]: dba
Start Oracle ASM library driver on boot (y/n) [y]: y
Fix permissions of Oracle ASM disks on boot (y/n) [y]: y
Writing Oracle ASM library driver configuration: [ OK ]
Loading module "oracleasm": Unable to load module "oracleasm"
[FAILED]

The correct place to look for erorr was /var/log/messages.
here i found the error Module oracle ASM not found.

I did a rpm -qa | grep oracleasm on the system and found 3 asm packages installed.
oracleasm-2.6.9-89.EL-2.0.5-1.el4.i686.rpm,
oracleasmlib-2.0.4-1.el4.i386.rpm,
oracleasm-support-2.1.3-1.el4.i386.rpm


The following package was missing -->
oracleasm-2.6.9-89.ELsmp-2.0.5-1.el4.i686.rpm

I installed the above given package with -->

rpm -ivh oracleasm-2.6.9-89.ELsmp-2.0.5-1.el4.i686.rpm
Preparing... ########################################### [100%]
1:oracleasm-2.6.9-89.ELsm########################################### [ 100%]

afterwards again tried to configure Oracle ASM

[root@rac1]# /etc/init.d/oracleasm configure
Configuring the Oracle ASM library driver.

This will configure the on-boot properties of the Oracle ASM library
driver. The following questions will determine whether the driver is
loaded on boot and what permissions it will have. The current values
will be shown in brackets ('[]'). Hitting without typing an
answer will keep that current value. Ctrl-C will aborts.

Default user to own the driver interface [oracle]: oracle
Default group to own the driver interface [dba]: dba
Start Oracle ASM library driver on boot (y/n) [y]: y
Fix permissions of Oracle ASM disks on boot (y/n) [y]: y
Writing Oracle ASM library driver configuration: [ OK ]
Initializing the Oracle ASMLib driver [ OK ]
Scanning the system for Oracle ASMLib disks [OK]

Wednesday, September 22, 2010

RW-50016 Error: - {0} was not created during rapidinstall

ERROR LOGIN PAGE
-------------------------
checking URL = http://.:8000/OA_HTML/AppsLogin
RW-50016: Error: - {0} was not created

Finally when i thought i have solved all errors, i came across this new error at the end on installation. Now am trying to solve this one, and will post the solution as soon i come across one. Anyhow installation was smooth till now, its just this error i had come across at the end, but it took me a lot of time to complete installation since am also installing vision database for test purpose and am that too on vmware.

I tried one of the solutions that i came across on other sites, and changed the entries in /etc/hosts.
127.0.0.1 localhost

Now i started install again and one of the error that was previously coming - JSP page could not be displayed has stopped coming.

Let's hope the other error also stops coming.

I will update this post soon with some results.

Sunday, September 19, 2010

Finally all errors resolved as of now!

Finally i was able to resolve the rw error that was coming, it was actually because of the improper unzip of files that i had downloaded. Now i am going to start the installation once again , and am sure will finish things this time. I will surely paste some more details about the installation in some time

Wednesday, September 15, 2010

rw-20003 while installing E-business 12i suite on linux

Today i recieved the above error while installing E-Business suite on Linux. anyhow i searched on google and found a link to metalink note No.802195.1
It seems like there is some corruption in the files that i have downloaded for installation. so i have to run the md5 checksum file given in this note with the cds that i have downloaded. Am doing the same.
I downloaded this file and placed it in the directory where i had staged all my components.
then i ran -->

$md5sum --check md5sum_Linux32.txt > md5sum_result.txt

This is going to take some time. so will have to wait for the output.

Sunday, July 4, 2010

Oracle Data Pump 10g

Recently i worked on Oracle data pump for second time. Its actually a feature of oracle database that helps to export data in a faster manner, i had earlier worked on this in one of my previous projects, but recently used it to export somewhat bigger table in the database.
This method of exporting data is much faster that simple imp and exp.

I will just outline some simple steps to use this great utility -

First of of all we need to create a Dump directory -

In my case i create this directory at the location /backup/dpump_dir

SQL> Create directory exp_dir as '/backup/dpump_dir';

Then we need to grant read,write access to the users that are exporting data on this directory.

SQL> grant read,write on exp_dir to user1;

Now we are all set to start datapump export , we will use -

$expdp username/password DIRECTORY=exp_dir DUMPFILE=exp1.dmp LOGFILE=exp1l.og FULL=y PARALLEL= 10

Also to export a single table we can use -

$ expdp username/password DIRECTORY=exp_dir DUMPFILE=user1.dmp LOGFILE=user1l.log TABLES=TABLENAME PARALLEL=10

This will export a single table

For more information use EXPDP help=y on dollar prompt

Now to check your jobs you can write-

sql> select * from dba_datapump_jobs

From here you can view the name of your job.

To kill currently running job we can first find session name from above and then use -

expdp username/password attach=JOB_NAME
Afterwards we get a prompt

Export >
Export > Kill_job
Are you sure you wish to stop this job ([y]/n): y

Again we can check with -->

SQL> select * from dba_datapump_jobs
no rows selected

Friday, June 11, 2010

High Version Count In AWR

One day while reading AWR reports, i hav seen a section named Sql by high version count.
This was something new for me and i had cehcked the defination on other sites and found that this is mainly caused due to bind mismatch. Although the application is using Bind variables, but still sqls are not gettinsg shared due to this bind mismatch.
Anyhow we came across a new event that can be set to tackle this problem -
'10503 trace name context forever, level '

Friday, April 23, 2010

spooling sql output to excel

sometime it is required to spool sql output to excel file, i learned a new way to do this and it is very simple and handy. just posing an example below, this was told to me by one on my friends who is a dba and i have also seen such examples on otn website as well.
you just need to connect to sqlplus and use following :-
SQL>set markup html on;
SQL>spool 'c:\test.xls'
SQL>select empno,deptno from scott.emp;

SQL> SPOOL OFF;


SQL> SET MARKUP HTML OFF;


SQL>

Its an easy way...

Wednesday, April 14, 2010

More About Real Application Clusters

This is in continuation with my previous post , one thing i forgot to mention is that in RAC environment database resides on SAN, hence in the event of failure on any node , database is still available for other nodes to access. Here there are three types of network connection available, first is interconnect (This is the connection that is used as heartbeat and to transfer data blocks), second is VIP(Virtual Ip Address) that is accessed by users, and other is a physical Ip. Interconnects are heartbeats that play an important role in manging the cluster,if primary node is unable to communicate with secondary node through interconnects then the second node is evicted from the cluster or it reboots. Sometime later i will surely put some screenshots of how to install RAC on Vmware, for those who are new to this it is advisable to install on Vmware, and have a feel of the cluster environment.

Friday, April 9, 2010

So what is Oracle Real Application Clusters??

From some time i was thinking of writing about some basic stuff regarding RAC.
RAC stands for Real Application Cluster , which in plain term means a Database working in Cluster mode,now hope most of you are familier with the term CLUSTER, otherwie just do a google, am sure you will find good pages on this. Since this database works in cluster minimum of 2 nodes are required to operate. So what benefits does this provides!! First of all RAC is an active-active cluster, this means both the nodes of Oracle cluster can access the database simultaneously.Hence in the event of failure if one node goes down, the database can still be accessed from the second node. So you can give 99% uptime..:-)
Second benefit is that it also provides for feature such as load balancing, in this case if we have 4000 users accessing a database, they will be evenly distributed on both the nodes, i.e 2000 users on each node. This helps in utilizing system resources of both the nodes and also easing of CPU utilization. In some other post i will surely write about some really good scenario that i have come across in the environments i have managed..and will also try to explain more about RAC..

Sunday, January 24, 2010

events in oracle DB

When i was very new to database, i always used to wonder why are there so many events in database and what is the use of all these..:-)..but now i really understand why are they there. In fact most of the times , when you feel like checking health of the database, just check out the event at that point of time and also at peak load.
The view v$session is a great place to start, the column event gives you event being faced by a particular session. This has helped me a lot..:-)