Home » RDBMS Server » Backup & Recovery » MAXPIECESIZE configuration not working (Oralce 11gR2,11.2.0.1.0,RHEL 5)
MAXPIECESIZE configuration not working [message #486658] Sat, 18 December 2010 01:45 Go to next message
jimit_shaili
Messages: 237
Registered: June 2006
Location: India, Ahmedabad
Senior Member
Dear Friends

I'm using rman for my production db backup. i have set following parameter and script for my full database backup. i have configure the maxpiecesize = 2g,but still in some cases files goes over 2g.Below is my scripts for rman and output from OS files.
RMAN > #Allocation all channel
replace script allocate_channel {
allocate channel d11 type disk;
allocate channel d12 type disk;
allocate channel d13 type disk;
} 

replaced script allocate_channel

RMAN > # Releases all channels
replace script release_channel {
release channel d11;
release channel d12;
release channel d13;
}

replaced script release_channel

RMAN > # Backs up the control file
replace script backup_controlfile {
execute script allocate_channel;
backup
format '/home/wbrman/backup/rman_CTL__%d.%U.bak'
(current controlfile);
execute script release_channel;
}

replaced script backup_controlfile

RMAN > # Back up the archived log files, and deletes them once the backup has successfully completed.
replace script backup_archivelog {
sql 'alter system archive log current';
execute script allocate_channel;
backup
filesperset 10
format '/home/wbrman/backup/rman_ARC__%d.%U.bak'
(archivelog all delete input);
execute script release_channel;
}

replaced script backup_archivelog

RMAN> # Backs up the whole database. The database must be mounted and opened.
replace script backup_datafile {
execute script allocate_channel;
backup full tag backup_db filesperset 4
format '/home/wbrman/backup/rman_DF_%d.%U.bak'
(database);
execute script release_channel;
}

replaced script backup_datafile

RMAN> #Full Backup
replace script backup_fulldb {
execute script backup_controlfile;
execute script backup_datafile;
execute script backup_archivelog;
}

replaced script backup_fulldb


Output of configuration parameter

RMAN> show all;

RMAN configuration parameters for database with db_unique_name WBDATA are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
[b]CONFIGURE CHANNEL DEVICE TYPE DISK MAXPIECESIZE 2 G;[/b]
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE COMPRESSION ALGORITHM 'BASIC' AS OF RELEASE 'DEFAULT' OPTIMIZE FOR LOAD TRUE ; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/ora11gsoft/odb/OH1/dbs/snapcf_wbdata.f'; # default


Output of os files where backup taken
[oracle1@WBH-DB1 backup]$ ll -ltrh
total 5.9G
-rw-r----- 1 oracle1 oinstall 9.3M Dec 18 11:43 rman_CTL__WBDATA.1flvs4ee_1_1.ba
k
-rw-r----- 1 oracle1 oinstall 803M Dec 18 11:45 rman_DF_WBDATA.1hlvs4ei_1_1.bak
-rw-r----- 1 oracle1 oinstall 9.3M Dec 18 11:45 rman_DF_WBDATA.1jlvs4iq_1_1.bak
-rw-r----- 1 oracle1 oinstall 2.6G Dec 18 11:46 rman_DF_WBDATA.1glvs4ei_1_1.bak
-rw-r----- 1 oracle1 oinstall 2.6G Dec 18 11:47 rman_DF_WBDATA.1ilvs4ei_1_1.bak
-rw-r----- 1 oracle1 oinstall  15M Dec 18 11:47 rman_ARC__WBDATA.1klvs4ma_1_1.bak
-rw-r----- 1 oracle1 oinstall 2.5K Dec 18 11:47 rman_ARC__WBDATA.1llvs4ma_1_1.bak


Please clear my dought why it is creating files more than 2g,although i have configure maxpiecesize to 2 g;

Regards

Jimit
Re: MAXPIECESIZE configuration not working [message #486660 is a reply to message #486658] Sat, 18 December 2010 02:01 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10694
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
You have overlapping allocation channels (one in configuration that you set to 2G and other that overwrites in your script).
Re: MAXPIECESIZE configuration not working [message #486663 is a reply to message #486660] Sat, 18 December 2010 02:18 Go to previous messageGo to next message
jimit_shaili
Messages: 237
Registered: June 2006
Location: India, Ahmedabad
Senior Member
Dear Mahesh

should i need to alter my allocation channel script like this below. please reply,i'm right or wrong and also suggest me that,Is above script is proper for full database backup, or suggest me some RMAN scripts collection website (i've created above through the help of oracle documentation and one of the site) from which i can develop my own.

RMAN> replace script allocate_channel {
allocate channel d11 type disk maxpiecesize 2g;
allocate channel d12 type disk maxpiecesize 2g;
allocate channel d13 type disk maxpiecesize 2g;
} 
starting full resync of recovery catalog
full resync complete
replaced script allocate_channel


Regards

Jimit
Re: MAXPIECESIZE configuration not working [message #486664 is a reply to message #486663] Sat, 18 December 2010 02:25 Go to previous messageGo to next message
jimit_shaili
Messages: 237
Registered: June 2006
Location: India, Ahmedabad
Senior Member
Dear Mahesh

I've tried your suggestion and it is working fine, it was my conceptual mistake. Thanks for help. Please provide some help on incremental rman backup scripts.

Regards

Jimit
Re: MAXPIECESIZE configuration not working [message #486665 is a reply to message #486663] Sat, 18 December 2010 02:30 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10694
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
>>Is above script is proper for full database backup
May be. May not be. Backups are never an issue.
Recovery will most probably be (always assume that there will be a problem).
Only way to certify your backup policy is to test it by
restoring/recovering from backupsets, with different scenarios or atleast whatever your SLAs claim.
Test it, document it and do it in a regular but random interval/scenario.
And Oracle documntation/Metalink is the best place to learn.

First try. See if the suggestion works. Who knows? Smile
First try to get rid of manual allocation and see if it works.


Re: MAXPIECESIZE configuration not working [message #486666 is a reply to message #486664] Sat, 18 December 2010 02:33 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10694
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
>>Please provide some help on incremental rman backup scripts.
What exactly?
Everything is in documentation.
http://download.oracle.com/docs/cd/E11882_01/backup.112/e10642/rcmbckba.htm#i1034163
Re: MAXPIECESIZE configuration not working [message #486667 is a reply to message #486664] Sat, 18 December 2010 02:35 Go to previous messageGo to next message
jimit_shaili
Messages: 237
Registered: June 2006
Location: India, Ahmedabad
Senior Member
Dear Mahesh,

One more thing i need to clearify myself why there is a difference in backup files size and actual files size. Here listed below both the output from os.(I considered the that tempfiles and archived log files size) and I did not use any compression parameter explicitly.

Output of full database backup taken from RMAN
[oracle1@WBH-DB1 backup]$ ll -ltrh
[b]total 5.9G[/b]
-rw-r----- 1 oracle1 oinstall 9.3M Dec 18 13:49 rman_CTL__WBDATA.1mlvsbrk_1_1.bak
-rw-r----- 1 oracle1 oinstall 804M Dec 18 13:50 rman_DF_WBDATA.1olvsbro_1_1.bak
-rw-r----- 1 oracle1 oinstall 9.3M Dec 18 13:51 rman_DF_WBDATA.1qlvsbug_1_1.bak
-rw-r----- 1 oracle1 oinstall 2.0G Dec 18 13:52 rman_DF_WBDATA.1nlvsbro_1_1.bak
-rw-r----- 1 oracle1 oinstall 2.0G Dec 18 13:52 rman_DF_WBDATA.1plvsbro_1_1.bak
-rw-r----- 1 oracle1 oinstall 535M Dec 18 13:52 rman_DF_WBDATA.1nlvsbro_2_1.bak
-rw-r----- 1 oracle1 oinstall 553M Dec 18 13:52 rman_DF_WBDATA.1plvsbro_2_1.bak
-rw-r----- 1 oracle1 oinstall  94K Dec 18 13:53 rman_ARC__WBDATA.1rlvsc27_1_1.bak
-rw-r----- 1 oracle1 oinstall 2.5K Dec 18 13:53 rman_ARC__WBDATA.1tlvsc28_1_1.bak
-rw-r----- 1 oracle1 oinstall 2.8M Dec 18 13:53 rman_ARC__WBDATA.1slvsc27_1_1.bak


Output of actual database files
[oracle1@WBH-DB1 data]$ ll -ltrh 
total 8.6G
-rw-r----- 1 oracle1 oinstall  11M Dec  7 22:02 tea_temp01.dbf
-rw-r----- 1 oracle1 oinstall  11M Dec  7 22:03 inventory_temp01.dbf
-rw-r----- 1 oracle1 oinstall  11M Dec  7 22:03 production_temp01.dbf
-rw-r----- 1 oracle1 oinstall  11M Dec  7 22:03 office_temp01.dbf
-rw-r----- 1 oracle1 oinstall  11M Dec 18 10:20 temp01.DBF
-rw-r----- 1 oracle1 oinstall 101M Dec 18 13:53 redo03a.log
-rw-r----- 1 oracle1 oinstall 101M Dec 18 13:53 redo01a.log
-rw-r----- 1 oracle1 oinstall 530M Dec 18 13:53 tea_index01.dbf
-rw-r----- 1 oracle1 oinstall 1.5G Dec 18 13:53 tea_data01.dbf
-rw-r----- 1 oracle1 oinstall 203M Dec 18 13:53 system01.dbf
-rw-r----- 1 oracle1 oinstall 595M Dec 18 13:53 production_index01.dbf
-rw-r----- 1 oracle1 oinstall 1.3G Dec 18 13:53 production_data01.dbf
-rw-r----- 1 oracle1 oinstall 122M Dec 18 13:53 office_index01.dbf
-rw-r----- 1 oracle1 oinstall 203M Dec 18 13:53 office_data01.dbf
-rw-r----- 1 oracle1 oinstall 574M Dec 18 13:53 inventory_index01.dbf
-rw-r----- 1 oracle1 oinstall 734M Dec 18 13:53 inventory_data01.dbf
-rw-r----- 1 oracle1 oinstall 791M Dec 18 13:53 history01.dbf
-rw-r----- 1 oracle1 oinstall  93M Dec 18 13:59 sysaux01.dbf
-rw-r----- 1 oracle1 oinstall 1.9G Dec 18 14:04 undotbs01.dbf
-rw-r----- 1 oracle1 oinstall 101M Dec 18 14:04 redo02a.log
-rw-r----- 1 oracle1 oinstall 9.3M Dec 18 14:04 control01.ctl


In my case actual size almost 2.6g more than backup from rman. please clearify my dought.

Regards

Jimit
Re: MAXPIECESIZE configuration not working [message #486668 is a reply to message #486667] Sat, 18 December 2010 02:44 Go to previous message
Mahesh Rajendran
Messages: 10694
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
http://download.oracle.com/docs/cd/E11882_01/backup.112/e10642/glossary.htm#i432341
Previous Topic: Log file in ORACLEXE\APP\ORACLE\FLASH_RECOVERY_AREA\XE\ONLINELOG got deleted
Next Topic: backups and DBID
Goto Forum:
  


Current Time: Wed Mar 03 06:37:24 CST 2021