Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the steps of ORACLE incremental backup under LINUX

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

In this issue, the editor will bring you about the steps of ORACLE incremental backup under LINUX. The article is rich in content and analyzed and described from a professional point of view. I hope you can get something after reading this article.

Procedure:

1 View the operating system version

[oracle@localhost ~] $cat / proc/version

Linux version 2.6.18-164.el5 (mockbuild@x86-003.build.bos.redhat.com) (gcc version 4.1.2 20080704 (Red Hat 4.1.2-46)) # 1 SMP Tue Aug 18 15:51:48 EDT 2009

2 View the database version

SQL > select * from v$version

BANNER

Oracle Database 10g Enterprise Edition Release 10.2.0.1.0-64bit

PL/SQL Release 10.2.0.1.0-Production

CORE 10.2.0.1.0 Production

TNS for Linux: Version 10.2.0.1.0-Production

NLSRTL Version 10.2.0.1.0-Production

3 check the name of the database

SQL > show parameter db_name

NAME TYPE VALUE

-

Db_name string NACEC

4 View archive status

SQL > archive log list

Database log mode Archive Mode

Automatic archival Enabled

Archive destination USE_DB_RECOVERY_FILE_DEST

Oldest online log sequence 42

Next log sequence to archive 44

Current log sequence 44

5 format the archive log

SQL > alter system set log_archive_format='ARC%s%t%r.log' scope=spfile

6 set the storage path of the archive log

SQL > alter system set db_recovery_file_dest_size=2G

SQL > alter system set db_recovery_file_dest='/dat/DBSoftware/oracle/flash_recovery_area'

SQL > alter system set log_archive_dest_1='location=/home/FRA'

SQL > alter system set log_archive_dest_10='LOCATION=USE_DB_RECOVERY_FILE_DEST'

SQL > shutdown immediate

SQL > startup

SQL > alter system switch logfile

7 start automatic backup of control files

RMAN > configure controlfile autobackup on

New RMAN configuration parameters:

CONFIGURE CONTROLFILE AUTOBACKUP ON

New RMAN configuration parameters are successfully stored

RMAN > show controlfile autobackup

RMAN configuration parameters are:

CONFIGURE CONTROLFILE AUTOBACKUP ON

8 check whether to use spfile parameter file

SQL > show parameter spfile

NAME TYPE VALUE

-

Spfile string

The value of VALUE is empty, and the database is started with a pfile file. If there is a value, start for spfile.

Create a spfile parameter file

SQL > create spfile from pfile

File created.

SpfileSID.ora will be generated under $oracle_home/dbs/

SQL > shutdown immediate

Database closed.

Database dismounted.

ORACLE instance shut down.

SQL > startup

ORACLE instance started.

Total System Global Area 268435456 bytes

Fixed Size 1218868 bytes

Variable Size 88082124 bytes

Database Buffers 171966464 bytes

Redo Buffers 7168000 bytes

Database mounted.

Database opened.

SQL > show parameter spfile

NAME TYPE VALUE

-

Spfile string / dat/DBSoftware/oracle/product/10.2.0/db_1/dbs/spfilenacec.ora

9 use the redundancy policy of rman. Default is 7 days.

RMAN > configure retention policy to recovery window of 15 days

10 start the block change tracking file

SQL > alter database enable block change tracking using file'/ home/rob10gr2_block_change.fil'

11 create backuplevel0.rcv and backuplevel1.rcv scripts under / home/NACEC/BackupDatabase/

Backuplevel0.rcv content:

# script.:bakuplevel0.rcv

# creater:liu shiming

# date:2010/6/28

# desc:backup level0 database datafile in archive with rman

# connect database

#! / bin/bash

Export ORACLE_BASE=/home/DBSoftware/oracle

Export ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1

Export ORACLE_SID=NACEC

Export PATH=/home/DBSoftware/oracle/product/10.2.0/db_1/bin:$PATH

Rman target/ 'executable'

Job_action= >'/ dat/DBData/oradata/scripts/backuplevel0.sh'

Repeat_interval= > 'freq=weekly;byday=WED,SUN;byhour=01;byminute=00')

End

/

Exec dbms_scheduler.enable ('nacec_job0')

Begin

Dbms_scheduler.create_job (

Job_name= > 'job1_nacec'

Job_type= > 'executable'

Job_action= >'/ dat/DBData/oradata/scripts/backuplevel1.sh'

Repeat_interval= > 'freq=weekly;byday=MON,TUE,THU,FRI,SAT;byhour=01;byminute=00')

End

/

Exec dbms_scheduler.enable ('job1_nacec')

These are the steps of ORACLE incremental backup under LINUX shared by Xiaobian. If you happen to have similar doubts, please refer to the above analysis to understand. If you want to know more about it, you are welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report