Archive

Archive for August, 2011

Grid Infrastructure alert.log shows messages:PRVF-5408 and PRVF-5416

August 16, 2011 Leave a comment

Grid Infrastructure alert.log shows messages:


2011-08-14 21:39:17.387
[client(8090)]CRS-10051:CVU found following errors with Clusterware setup : PRVF-5408 : NTP Time Server "maggie.cpp-grou" is common only to the followin
g nodes "davis"
PRVF-5408 : NTP Time Server "10.0.0.1" is common only to the following nodes "cruz"
PRVF-5416 : Query of NTP daemon failed on all nodes

if you run the following command


$ cluvfy comp clocksync -n all -verbose

....
....
Result: Clock synchronization check using Network Time Protocol(NTP) passed

Oracle Cluster Time Synchronization Services check passed

Verification of Clock Synchronization across the cluster nodes was successful.

As ntp is setup correctly as shown in above cluvfy output you can ignore this warning.

Categories: Oracle Rac

ORA-19606: Cannot copy or restore to snapshot control file

August 5, 2011 1 comment

When trying to delete obsolete backups, rman includes the snapshot control file, and so spits out
ORA-19606: Cannot copy or restore to snapshot control file


RMAN> CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u01/flash/flashback_recovery_area/CCHPRD/snapcf_cchprd1.f';

RMAN> show all;
RMAN> delete noprompt obsolete;

RMAN retention policy will be applied to the command
RMAN retention policy is set to redundancy 1
using channel ORA_DISK_1
using channel ORA_DISK_2
Deleting the following obsolete backups and copies:
Type Key Completion Time Filename/Handle
-------------------- ------ ------------------ --------------------
Control File Copy 53 08-MAY-10 /u01/app/oracle/product/11.2.0/dbhome_1/dbs/snapcf_cchprd1.f
deleted control file copy control file copy
file name=/u01/app/oracle/product/11.2.0/dbhome_1/dbs/snapcf_cchprd1.f RECID=53 STAMP=718455816
Deleted 1 objects

Categories: Oracle

Export Import Table Stats from UAT system into Production

August 4, 2011 Leave a comment

steps to export table stats from one system to another

UAT SYSTEM

Unlock the stats on the customer  table


exec dbms_stats.unlock_table_stats(ownname => scott, tabname => 'CUSTOMER');

Oracle will gather stats via the overnight or weekend job window

create table for Exports of customer table stats


execute dbms_stats.create_stat_table(ownname= 'scott', stattab= 'backup_stats_uat');

Import the stats from the customer table and indexes


exec dbms_stats.import_table_stats(ownname=>'scott', tabname=>'customer', statown=>'scott', stattab=>'backup_stats_uat', cascade=>true);

Use datapump to export the table


expdp system tables=scott.backup_stats_uat directory=oraexp dumpfile=backup_stats_uat.dmp logfile=backup_stats_uat.log

Transfer the file to the production system

PRODUCTION SYSTEM

unlock stats on table scott.customer


exec dbms_stats.unlock_table_stats(ownname => scott, tabname => 'customer')

Import the table backup_stats_uat using the backup_stats_uat.dmp


impdp system tables=scott.backup_stats_uat directory=data_pump_dir dumpfile=backup_stats_uat.dmp logfile=imp_backup_stats_uat.log

Once table is imported /import the table and index stats


exec dbms_stats.import_table_stats(ownname=>'scott', tabname=>'customer', statown=>'scott', stattab=>'backup_stats_uat', cascade=>true);

drop the backup_stats_uat table


execute dbms_stats.drop_stat_table(ownname= 'npp', stattab= 'backup_stats_uat');

If you need to regress the stats


exec dbms_stats.restore_table_stats ('scott','customer',sysdate-1);

 

 

 

Categories: Uncategorized