zoukankan      html  css  js  c++  java
  • views

    common.Views

    V$DATABASE

    V$DATABASE displays information about the database from the control file.
    DBID
    Database identifier calculated when the database is created and stored in all file headers(10位)
    NAME
    数据库的名称,显示的是DB_NAME的值
    CREATED
    数据库的创建日期,如果使用CREATE CONTROLFILE重新创建控件文件,则显示重新创建控件文件的日期
    RESETLOGS_CHANGE#
    System change number (SCN) at open resetlogs
    RESETLOGS_TIME
    使用resetlogs打开数据库的时间
    PRIOR_RESETLOGS_CHANGE#
    SCN at prior resetlogs
    PRIOR_RESETLOGS_TIME
    Timestamp of prior resetlogs
    LOG_MODE
    归档模式,NOARCHIVELOG,ARCHIVELOG,MANUAL
    CHECKPOINT_CHANGE#
    Last SCN checkpointed,上次系统检查点SCN
    ARCHIVE_CHANGE#
    Database force archiving SCN. Any redo log with a start SCN below this will be forced to archive out.在这个scn之前的(比这个scn小)redolog都将会自动强制归档
    CONTROLFILE_TYPE
    控制文件类型:
    • STANDBY - 表示数据库处于备库模式
    • CLONE - Indicates a clone database
    • BACKUP | CREATED - Indicates the database is being recovered using a backup or created control file
    • CURRENT - database is available for general use

    DG架构下-主库为current,备库为standby

    CONTROLFILE_CREATED
    控制文件的创建时间
    CONTROLFILE_SEQUENCE#
    Control file sequence number incremented by control file transactions
    CONTROLFILE_CHANGE#
    Last SCN in backup control file; null if the control file is not a backup
    CONTROLFILE_TIME
    最近备份控制文件的时间; null if the control file is not a backup,最近备份控制文件的时间
    OPEN_RESETLOGS
    (NOT ALLOWED | ALLOWED | REQUIRED) 表示下次open数据库是否允许或需要resetlogs选项
    VERSION_TIME
    Version time
    OPEN_MODE
    Open mode information:
    • MOUNTED
    • READ WRITE
    • READ ONLY
    • READ ONLY WITH APPLY - 物理standby开启real-time的状态

    PROTECTION_MODE

    目前数据库运行的保护模式:
    • MAXIMUM PROTECTION - Database is running in maximized protection mode
    • MAXIMUM AVAILABILITY - Database is running in maximized availability mode
    • RESYNCHRONIZATION - Database is running in resynchronization mode
    • MAXIMUM PERFORMANCE - Database is running in maximized performance mode
    • UNPROTECTED - Database is unprotected (this normally occurs when the primary database is mounted and not open)
    PROTECTION_LEVEL
    Aggregated protection mode currently in effect for the database:
    • MAXIMUM PROTECTION - Database is running in maximized protection mode
    • MAXIMUM AVAILABILITY - Database is running in maximized availability mode
    • RESYNCHRONIZATION - Database is running in resynchronization mode
    • MAXIMUM PERFORMANCE - Database is running in maximized performance mode
    • UNPROTECTED - Database is unprotected (this normally occurs when the primary database is mounted and not open)
    Note: This column is an aggregation of the PROTECTION_MODE of all standby archive log destinations.
    REMOTE_ARCHIVE
    REMOTE_ARCHIVE_ENABLE参数的值
    ACTIVATION#
    分配给数据库实例化的编号
    SWITCHOVER#
    Number assigned to the database switchover
    DATABASE_ROLE
    Current role of the database:
    • SNAPSHOT STANDBY
    • LOGICAL STANDBY
    • PHYSICAL STANDBY
    • PRIMARY

    ARCHIVELOG_CHANGE#
    Highest NEXT_CHANGE# (from the V$ARCHIVED_LOG) for an archive log,上一次归档动作结束时的scn,也就是最新的归档日志的所记录的最后一个SCN(根据文档也就是v$archived_log里最大的next_change#)
    ARCHIVELOG_COMPRESSION
    Status of the archive log compression (ENABLED) or (DISABLED)
    SWITCHOVER_STATUS
    是否允许switchover:

    • NOT ALLOWED - 在主库上,此状态表明没有有效且启用的备库,如果第一次切换为主库,可能是这个状态,需要进行一次日志传输;在库上,此状态表示尚未从主库接收到切换请求
    • SESSIONS ACTIVE -表示数据库有活动会话,主库上杀掉连接后,就会变成to_standby状态,也可以在switchover时加上with session shutdown;在物理备库上,必须指定WITH SESSION SHUTDOWN以在此状态下执行角色转换;在逻辑备库上,可以在此状态下执行角色转换,但在所有当前事务都已提交之前,角色转换将不会完成
    • SWITCHOVER PENDING -在物理备库上,此状态表示已从主数据库接收并正在处理切换请求,在此状态下,物理备用数据库无法切换到主要角色
    • SWITCHOVER LATENT -On a physical standby database, this status indicates that a switchover request was pending, but the original primary database has been switched back to the primary role.
    • TO PRIMARY - The database is ready to switch to the primary role.
    • TO STANDBY - The database is ready to switch to either the physical or logical standby role.表示数据库没有连接,可直接切换为备库
    • TO LOGICAL STANDBY - The database has received a data dictionary from a logical standby database and is ready to switch to the logical standby role.
    • RECOVERY NEEDED -在物理备库上,此状态表示在数据库切换到主角色之前必须应用重做日志,以保持一致性;主库发出switchover,启动到mount后,SWITCHOVER_STATUS为RECOVERY NEEDED
    • PREPARING SWITCHOVER - On a primary database, this status indicates that a data dictionary is being received from a logical standby database in preparation for switching to the logical standby role. On a logical standby database, this status indicates that the data dictionary has been sent to the primary database and other standby databases.
    • PREPARING DICTIONARY - On a logical standby database, this status indicates that the data dictionary is being sent to the primary database and other standby databases in preparation for switching to the primary role.
    • FAILED DESTINATION - On a primary database, this status indicates that one or more standby destinations are in an error state.
    • RESOLVABLE GAP - On a primary database, this status indicates that one or more standby databases have a redo gap that can be automatically resolved by fetching the missing redo from the primary database or from another standby database.
    • UNRESOLVABLE GAP - On a primary database, this status indicates that one or more standby databases have a redo gap that cannot be automatically resolved by fetching the missing redo from the primary database or from another standby database.
    • LOG SWITCH GAP - On a primary database, this status indicates that one or more standby databases are missing redo due to a recent log switch.

    standalone-NOT ALLOWEDDG-primary:SESSIONS ACTIVE,standby-NOT ALLOWED
    DATAGUARD_BROKER
    Data Guard broker information:

    ENABLED - Database is part of a broker configuration and broker management of the database is enabled
    DISABLED - Database is part of a broker configuration and broker management of the database is disabled. This value is displayed if the user disabled broker management of the database or configuration, or if broker management was disabled due to a role change (for example, the old primary was disabled after a failover operation).
    the database is not part of a broker configuration.
    the broker is not running on the database.
    GUARD_STATUS
    Protects data from being changed:

    • ALL - Indicates all users other than SYS are prevented from making changes to any data in the database.
    • STANDBY - Indicates all users other than SYS are prevented from making changes to any database object being maintained by logical standby.
    • NONE - Indicates normal security for all data in the database.

    SUPPLEMENTAL_LOG_DATA_MIN
    Ensures that LogMiner (and any products building on LogMiner technology) will have sufficient information to support chained rows and various storage arrangements such as cluster tables:

    • NO - None of the database-wide supplemental logging directives are enabled
    • IMPLICIT - Minimal supplemental logging is enabled because all or a combination of primary key, unique key, and foreign key supplemental logging is enabled
    • YES - Minimal supplemental logging is enabled through an ALTER DATABASE ADD SUPPLEMENTAL LOG DATA statement

    SUPPLEMENTAL_LOG_DATA_PK
    For all tables with a primary key, indicates whether all columns of the primary key are placed into the redo log whenever an update is performed (YES) or not (NO)

    SUPPLEMENTAL_LOG_DATA_UI
    For all tables with a unique key, indicates whether all other columns belonging to the unique key are placed into the redo log if any of the unique key columns are modified (YES) or not (NO)

    FORCE_LOGGING
    Indicates whether the database is under force logging mode (YES) or not (NO)

    PLATFORM_ID
    Platform identification number of the database

    PLATFORM_NAME
    Platform name of the database

    RECOVERY_TARGET_INCARNATION#
    Incarnation number where all datafiles are recovered by the RECOVER DATABASE command

    LAST_OPEN_INCARNATION#
    Record number of the incarnation in V$DATABASE_INCARNATION that was last opened successfully

    CURRENT_SCN
    当前SCN; null表示数据库没有open,对于standby database, it is the checkpoint SCN of the mounted physical standby database during media recovery and is always less than the last applied SCN tracked in V$RECOVERY_PROGRESS.

    FLASHBACK_ON
    Possible values are as follows:

    • YES - 闪回启用
    • NO - 闪回关闭
    • RESTORE POINT ONLY - 闪回开启,但只能闪回到保证的恢复点,快照standby上显示

    SUPPLEMENTAL_LOG_DATA_FK
    For all tables with a foreign key, indicates whether all other columns belonging to the foreign key are placed into the redo log if any foreign key columns are modified (YES) or not (NO)

    SUPPLEMENTAL_LOG_DATA_ALL
    For all columns, indicates whether all the fixed-length maximum size columns of that row are placed into the redo log (YES) or not (NO)
    DB_UNIQUE_NAME
    Unique database name

    STANDBY_BECAME_PRIMARY_SCN
    SCN at which a physical standby database became a primary database. This SCN is useful for converting a failed primary database into a physical standby database after a forced failover.

    FS_FAILOVER_STATUS
    Fast-start failover status:

    • DISABLED
    • BYSTANDER
    • SYNCHRONIZED
    • UNSYNCHRONIZED
    • SUSPENDED
    • STALLED
    • LOADING DICTIONARY
    • PRIMARY UNOBSERVED
    • REINSTATE REQUIRED
    • REINSTATE FAILED
    • TARGET OVER LAG LIMIT
    • TARGET UNDER LAG LIMIT

    Note: If the value of this column is DISABLED, then the values for the FS_FAILOVER_CURRENT_TARGET, FS_FAILOVER_THRESHOLD, FS_FAILOVER_OBSERVER_PRESENT, and FS_FAILOVER_OBSERVER_HOST columns in this table are not meaningful.

    FS_FAILOVER_CURRENT_TARGET
    DB_UNIQUE_NAME of the standby that is the current FSFO target standby for the Data Guard configuration

    FS_FAILOVER_THRESHOLD
    Time (in seconds) that the observer will attempt to reconnect with a disconnected primary before attempting FSFO with the target standby

    FS_FAILOVER_OBSERVER_PRESENT
    Indicates whether the observer is currently connected to the local database (YES) or not (NO)Note: This column is consistent throughout an Oracle RAC environment; that is, if the observer is connected to any instance, then all instances will show a value of YES.

    FS_FAILOVER_OBSERVER_HOST
    Machine name that is currently hosting the observer process
    CONTROLFILE_CONVERTED
    Indicates whether the control file was implicitly converted from its original type during restore (YES) or not (NO)
    This column will be set to YES when RMAN restores a standby control file from a backup of the control file taken at the primary database or restores a backup control file from a backup taken at the physical standby database.This column will change to NO when the file names are fixed using information in the recovery catalog schema.
    PRIMARY_DB_UNIQUE_NAME
    对于备库 (Physical, Logical, or Snapshot),该列表示该备库上次接受重做数据的主库的DB_UNIQUE_NAME,如果该备库自​​上次启动后未收到任何当前重做数据,为空
    对于先前已经处于备机状态的主数据库,该列将表示数据库在充当备库时从其接收当前重做的最后一个主数据库的DB_UNIQUE_NAME,对于从未进入备机状态的主库,为null
    SUPPLEMENTAL_LOG_DATA_PL
    Indicates whether additional information is logged in the redo log (YES) or not (NO) during invocation of procedures in Oracle-supplied packages for which procedural replication is supported.

    MIN_REQUIRED_CAPTURE_CHANGE#
    Minimum REQUIRED_CHECKPOINT_SCN for all local capture processes on the database

    V$LOG

    显示控制文件里online redo logfile的信息

    GROUP#
    Log group number 
    THREAD#
    Log thread number 
    SEQUENCE#
    Log sequence number
    BYTES
    Size of the log (in bytes)
    BLOCKSIZE
    Block size of the logfile (512 or 4096),细粒度,datafile的blocksize为8192,粗粒度
    MEMBERS
    Number of members in the log group 
    ARCHIVED
    Archive status (YES) or (NO) 
    STATUS
    Log status:

      • UNUSED - Online redo log has never been written to.通常指从未被使用的日志组,即新添加的日志组
      • CURRENT - Current redo log. This implies that the redo log is active. The redo log could be open or closed.LGWR进程正把redo log buffer的日志写进日志组中,在进行实例恢复时是必须的
      • ACTIVECLEARING - Log is being re-created as an empty log after an ALTER DATABASE CLEAR LOGFILE statement. After the log is cleared, the status changes to UNUSED.
        • Log is active but is not the current log. It is needed for crash recovery. It may be in use for block recovery. It may or may not be archived
        • 活动的非当前日志,在进行实例恢复时会被用到,Active状态意味着Checkpoint尚未完成,因此该日志文件不能被覆盖,检查点没有做完的根本原因是dbwr执行的dirty buffer写出还没有执行完成,也就是说ckpt进程会等待dbwr写出数据完成,等待的过程就是表示等待将current日志中修改过的数据块信息写入到数据文件的过程,因为这些信息其实是实例恢复的时候要用到的信息,如shutdown abort时,oracle会利用redo日志中的信息对数据库进行实例恢复
        • 为刚刚完成日志切换后的状态,此时该日志组中提交的事务引起的数据改变还没有完全从DB buffer cache写入到数据文件中,因此该日志组还不能被覆盖,并且待完全写入后变为inactive状态,如果数据库为归档模式,那么是在该状态下完成归档的
      • CLEARING_CURRENT - Current log is being cleared of a closed thread. The log can stay in this status if there is some failure in the switch such as an I/O error writing the new log header.
      • INACTIVE -
        • Log is no longer needed for instance recovery. It may be in use for media recovery. It may or may not be archived.
        • INACTIVE状态的日志可以被覆盖,可以允许写入日志,如果是在归档模式下,那么此阶段证明归档已经完成

     

    DG.Views

    V$MANAGED_STANDBY

    V$MANAGED_STANDBY显示DG环境中与物理standby相关进程的当前状态信息,实例关闭后,视图就无法查询

    Column Description
    PROCESS Type of the process whose information is being reported:
    * RFS - Remote file server(standby)
    * MRP0 - Detached recovery server process(standby)
    * MR(fg) - Foreground recovery session
    * ARCH - Archiver process
    * FGRD
    * LGWR
    * RFS(FAL)(standby)
    * RFS(NEXP)
    * LNS - Network server process(primary)
    PID Operating system process identifier of the process
    STATUS Current process status:
    * UNUSED - No active process
    * ALLOCATED - Process is active but not currently connected to a primary database
    * CONNECTED - Network connection established to a primary database
    * ATTACHED - Process is actively attached and communicating to a primary database
    * IDLE - Process is not performing any activities
    * ERROR - Process has failed
    * OPENING - Process is opening the archived redo log
    * CLOSING - Process has completed archival and is closing the archived redo log
    * WRITING - Process is actively writing redo data to the archived redo log,不管什么模式下,正常lns的状态
    * RECEIVING - Process is receiving network communication
    * ANNOUNCING - Process is announcing the existence of a potential dependent archived redo log
    * REGISTERING - Process is registering the existence of a completed dependent archived redo log
    * WAIT_FOR_LOG - 启用arch模式时mrp的状态
    * WAIT_FOR_GAP - Process is waiting for the archive gap to be resolved
    * APPLYING_LOG - mrp进程的状态,物理standy启用realtime apply的状态
    CLIENT_PROCESS Identifies the corresponding primary database process:
    * Archival - Foreground (manual) archival process (SQL)
    * ARCH - Background ARCn process
    * LGWR - Background LGWR process
    CLIENT_PID Operating system process identifier of the client process
    CLIENT_DBID Database identifier of the primary database
    GROUP# Standby redo log group
    RESETLOG_ID Resetlogs identifier of the archived redo log
    THREAD# Archived redo log thread number
    SEQUENCE# Archived redo log sequence number
    BLOCK# Last processed archived redo log block number
    BLOCKS Count (in 512-byte blocks) of the last write to a redo log, or for a recovery process, the expected final read count
    DELAY_MINS Archived redo log delay interval in minutes
    KNOWN_AGENTS Total number of standby database agents processing an archived redo log
    ACTIVE_AGENTS Number of standby database agents actively processing an archived redo log

    V$DATAGUARD_STATS

    在备库上查询时显示有关DG指标的信息,主库查询无数据返回
    该视图显示在主库上产生了多少重做日志数据,但是还没有被备库所应用,所以,通过查询该视图可以基本确定如果万一主库出现崩溃,备库上将丢失多少重做日志数据;同时可以估算failover的时间(apply finish time + estimated startup time)

    NAME
    指标名称:

    • APPLY FINISH TIME - 表示在备库上完成redo apply需要的时间,从主库已接受到的但未redo apply的重做所需时间的估计;如果为null,表示正常
    • APPLY LAG - 表示通过在备库上应用主库传递过来的重做日志与主库同步所延迟的时间
    • TRANSPORT LAG - 表示在单位时间内主库上产生的重做日志还没有传输到备库上,或者主库上产生的重做日志还没有被备库应用
    • ESTIMATED STARTUP TIME - 表示启动和打开物理备库所需要的时间,该字段不适用于逻辑备库

    VALUE 指标的值
    UNIT 计量单位
    TIME_COMPUTED 物理备库的本地时间
    DATUM_TIME 在物理备库上获取元数据来估算APPLY LAG和TRANSPORT LAG两个参数值的本地时间,如果从多次查询中看到该时间值对应的APPLY LAG和TRANSPORT LAG这两个参数值保持不变,那么就说明该物理备库已经停止从主库接收到重做数据

    apply lag使用从主库定期接收的数据计算,DATUM_TIME列包含备库上次接收此数据的时间戳,TIME_COMPUTED列包含计算应用延迟指标时的时间戳,这些列中的值之间的差异应小于30秒,如果差异大于此值,则apply lag可能不准确   

    V$DATAGUARD_CONFIG

    显示用DB_UNIQUE_NAME和LOG_ARCHIVE_CONFIG初始化参数定义的惟一数据库名称
    视图的第一行列出了当前数据库的DB_UNIQUE_NAME,其他行显示LOG_ARCHIVE_CONFIG.DG_CONFIG配置的值

    Column

    Description

    DB_UNIQUE_NAME

    Unique database name

    V$DATAGUARD_STATUS

    V$DATAGUARD_STATUS displays messages recently written to the alert log or server process trace files that concern physical standby databases or redo transport services for all standby database types.

    olumn Description
    FACILITY Facility that encountered the event:
    * Crash Recovery
    * Log Transport Services
    * Log Apply Services
    * Role Management Services
    * Remote File Server
    * Fetch Archive Log
    * Data Guard
    * Network Services
    SEVERITY Severity of the event:
    * Informational - Informational message
    * Warning - Warning message
    * Error - Indicates the process has failed
    * Fatal
    * Control - An expected change in state such as the start or completion of an archival, log recovery, or switchover operation
    DEST_ID Destination ID number to which the event pertains. If the event does not pertain to a particular destination, then the value is 0.
    MESSAGE_NUM A chronologically increasing number giving each event a unique number
    ERROR_CODE Error ID pertaining to the event
    CALLOUT Reserved for future use
    TIMESTAMP Message date
    MESSAGE A text message describing the event


    V$ARCHIVE_DEST_STATUS

    显示归档重做日志目标运行和配置信息,此视图中的信息不会在实例关闭时保留

    DEST_ID
    归档dest_id

    DEST_NAME
    Log archive destination parameter name

    STATUS
    归档dest的状态:

    • VALID - 已初始化且可用
    • INACTIVE - 没有目的地信息
    • DEFERRED - 人为手动禁用
    • ERROR - 打开或复制期间出错
    • DISABLED - Disabled after error
    • BAD PARAM - 参数有错误
    • ALTERNATE - 目的地处于备用状态
    • FULL - 超出目的地的配额大小

    TYPE
    档案目的地数据库的类型:

    • LOCAL - Local to primary database
    • PHYSICAL - Physical standby
    • CROSS-INSTANCE - An instance of the primary
    • LOGICAL - Logical standby
    • SNAPSHOT - Snapshot standby database
    • DOWNSTREAM - Streams downstream capture database

    DATABASE_MODE
    归档目标数据库的当前模式:

    • STARTED - Instance started, not mounted
    • MOUNTED - Mounted
    • MOUNTED-STANDBY - Mounted standby
    • OPEN - Open read/write
    • OPEN_READ-ONLY - Open read-only

    RECOVERY_MODE
    档案目的地的当前应用模式:

    • IDLE - Managed recovery is not active
    • MANAGED - Managed recovery is active,使用arch模式同步
    • MANAGED REAL TIME APPLY - Log apply services recover redo data from standby redo logs at the same time the logs are being written to, as opposed to recovering redo from archived redo logs when a log switch occurs,已开启实时模式
    • LOGICAL REAL TIME APPLY - Real time SQL Apply
    • LOGICAL APPLY - SQL Apply

    PROTECTION_MODE
    Indicates whether the database is protected:

    • MAXIMUM PROTECTION
    • MAXIMUM AVAILABILITY
    • RESYNCHRONIZATION
    • MAXIMUM PERFORMANCE
    • UNPROTECTED

    DESTINATION
    指定归档重做日志的位置
    STANDBY_LOGFILE_COUNT
    在备库上创建的备用重做日志的数量
    STANDBY_LOGFILE_ACTIVE
    备库上处于活动状态的备用重做日志总数,里面包含主库联机重做日志信息
    ARCHIVED_THREAD#
    标识该目标上收到的最新归档重做日志的线程号

    ARCHIVED_SEQ#
    标识该目标上接收的最新归档重做日志的日志序列号
    APPLIED_THREAD#
    标识该目标上最近应用重做日志的线程号
    APPLIED_SEQ#
    标识该目标上最近应用重做日志的日志序列号

    ERROR
    显示错误文本
    SRL
    是否在备库上使用备用重做日志文件(yes)或否(no)

    DB_UNIQUE_NAME
    LOG_ARCHIVE_DEST_n参数上DB_UNIQUE_NAME属性设置的值
    SYNCHRONIZATION_STATUS
    此列可能的值:

    • CHECK CONFIGURATION - 无法与此目标同步,因为此数据库未处于MAXIMUM PROTECTION或MAXIMUM PERFORMANCE数据保护模式,或者尚未使用SYNC配置与此目标关联的LOG_ARCHIVE_DEST_n参数
    • CHECK STANDBY REDO LOG - 此目标的备用重做日志配置不正确
    • CHECK NETWORK - One or more instances of this database cannot send redo data to this destination.
    • DESTINATION HAS A GAP - This destination is missing redo data needed for synchronization with this database.
    • OK - This destination is synchronized with this database.
    • NOT AVAILABLE - Synchronization status is not available.

    SYNCHRONIZED
    可能的值:

    • YES - This destination is synchronized with the primary database.
    • NO - The destination is not synchronized with the primary database.
    • UNKNOWN - The synchronization status of this destination cannot be determined.

    GAP_STATUS
    Redo gap status:

    • NO GAP - 没有间隙.
    • LOG SWITCH GAP - Destination has not yet received all of the redo from the previous log file.
    • RESOLVABLE GAP - Destination has a redo gap that can be automatically resolved by fetching the missing redo from this database.
    • UNRESOLVABLE GAP - Destination has a redo gap that cannot be automatically resolved by fetching the missing redo from this database and there are no other destinations from which redo can be fetched.
    • LOCALLY UNRESOLVABLE GAP - Destination has a redo gap that cannot be automatically resolved by fetching the missing redo from this database. It may be possible to resolve the gap by fetching the missing redo from another destination.

    backup.VIEWS 

    V$BACKUP_SET

    V$BACKUP_SET显示控制文件中有关备份集的信息,在备份成功完成后插入备份集记录; 如果删除了,则不显示

    RECID
    备份集记录ID,对应list中的“BS Key”
    STAMP
    备份集记录戳
    SET_STAMP
    Backup set stamp,SET_STAMP和SET_COUNT唯一标识备份集,是V$BACKUP_SET表的主键,以及下表的外键:V$BACKUP_PIECE,V$BACKUP_DATAFILE,V$BACKUP_REDOLOG,V$BACKUP_CORRUPTION
    SET_COUNT
    Backup set count. 当创建新备份集时,备份集计数加1(如果备份集从未完成,则数字“丢失”),如果重新创建控制文件,则计数重置为1;因此,必须将计数与标记一起使用以唯一标识备份集;V$BACKUP_SET表的主键以及下表的外键:V$BACKUP_PIECE,V$BACKUP_DATAFILE,V$BACKUP_REDOLOG,V$BACKUP_CORRUPTION
    BACKUP_TYPE
    备份中的文件类型,如果备份包含归档重做日志,则值为L;如果是数据文件完全备份,则值为D;如果是增量备份,则值为I
    CONTROLFILE_INCLUDED
    如果备份集中包含控制文件,则为YES,否则为NO
    INCREMENTAL_LEVEL
    增量备份的级别,对于数据文件,归档日志,控制文件和spfile备份,值为NULL;对于0级增量备份,为0;对于1级增量备份,为1
    PIECES
    该备份集中备份片的数量
    START_TIME
    备份集创建时间
    COMPLETION_TIME
    备份集结束时间
    ELAPSED_SECONDS
    消耗的秒数
    BLOCK_SIZE
    备份集块的大小
    INPUT_FILE_SCAN_ONLY
    YES表示未执行实际备份,但会读取数据文件。 NO表示执行正常备份
    KEEP
    (YES/NO) 表示此备份集的保留策略是否与配置保留策略的值不同
    KEEP_UNTIL
    如果指定了KEEP_UNTIL_TIME,则表示备份变为过时的日期;如果为null,表示永不过期
    KEEP_OPTIONS
    Lists additional retention options for this backup set. Possible values are:

    • LOGS - The logs need to recover this backup are kept
    • NOLOGS - The logs needed to recover this backup will not be kept
    • BACKUP_LOGS - An archive log backup exists to support this backup set

    MULTI_SECTION
    Indicates whether or not this backup set is a multi-section backup. Valid values are YES and NO. A multi-section backup is a backup in which multiple backup pieces are produced independently in parallel by multiple channels.

    V$BACKUP_PIECE

    V$BACKUP_PIECE显示控制文件中备份片的信息,每个备份集由一个或多个备份片组成; 如果物理删除,保持记录,状态deleted改为yes

    RECID 备份片记录ID
    STAMP 备份片记录戳
    SET_STAMP Backup set stamp
    SET_COUNT Backup set count
    PIECE# 备份集中备份片的编号 (1-N)
    COPY# Indicates the copy number for backup pieces created with duplex enabled. 1 if the backup piece is not duplexed.
    DEVICE_TYPE 备份片所在的设备类型;磁盘上的备份集为DISK
    HANDLE Backup piece handle identifies the backup piece on restore
    COMMENTS 操作系统或存储子系统返回的注释;磁盘上的备份片值为NULL,该值仅供参考;不需要恢复
    MEDIA 备份片所在的median的名称,该值仅供参考,不需要恢复
    MEDIA_POOL The media pool in which the copy resides. This is the same value that was entered in the POOLoperand of the Recovery Manager BACKUP command.
    CONCUR (YES | NO) Indicates whether the piece on a media that can be accessed concurrently
    TAG 备份片的标签,在备份集级别标记,但存储在片级
    STATUS 该片的状态:A(可用),D(已删除)或X(expired)
    START_TIME Starting time
    COMPLETION_TIME Completion time
    ELAPSED_SECONDS Number of elapsed seconds
    DELETED (YES/NO)NO表示该文件仍然存在,YES表示文件已不存在,因为它已被删除
    BYTES 备份片的大小 (in bytes)
    IS_RECOVERY_DEST_FILE 表示文件是否在快速恢复区中
    RMAN_STATUS_RECID Owning V$RMAN_STATUS record ID
    RMAN_STATUS_STAMP Owning V$RMAN_STATUS record stamp
    COMPRESSED 备份片是否压缩
    BACKED_BY_VSS Whether or not the file has been backed up by Volume Shadow Copy Service (VSS). This column is reserved for internal use.
    ENCRYPTED 是否加密
    BACKED_BY_OSB A value of YES means the backup was done to Oracle Secure Backup. Otherwise, backed up by other third party tape library.

    V$BACKUP_DATAFILE

    V$BACKUP_DATAFILE显示控制文件中备份集中的控制文件和数据文件的信息

    RECID Backup datafile record ID
    STAMP Backup datafile record stamp
    SET_STAMP Backup set stamp
    SET_COUNT Backup set count
    FILE# Datafile number; set to 0 for control file
    CREATION_CHANGE# Creation system change number (SCN) of the datafile
    CREATION_TIME Creation timestamp of the datafile
    RESETLOGS_CHANGE# Resetlogs system change number (SCN) of the datafile when it was backed up
    RESETLOGS_TIME Resetlogs timestamp of the datafile when it was backed up
    INCREMENTAL_LEVEL 正常完全备份为NULL,0级增量备份为0,1级增量备份为1
    INCREMENTAL_CHANGE# All blocks changed after the incremental change number is included in this backup; 全量备份为0
    CHECKPOINT_CHANGE# All changes up to the checkpoint change number are included in this backup
    CHECKPOINT_TIME Timestamp of the checkpoint
    ABSOLUTE_FUZZY_CHANGE# Highest change number in this backup
    MARKED_CORRUPT Number of blocks marked corrupt
    MEDIA_CORRUPT Number of blocks media corrupt
    LOGICALLY_CORRUPT Number of blocks logically corrupt
    DATAFILE_BLOCKS Size of the datafile in blocks at backup time. This value is also the number of blocks taken by the datafile restarted from this backup.
    BLOCKS Size of the backup datafile (in blocks). Unused blocks are not copied to the backup.
    BLOCK_SIZE Block size
    OLDEST_OFFLINE_RANGE RECID of the oldest offline range record in this backup control file. 0 for datafile backups.
    COMPLETION_TIME Time completed
    CONTROLFILE_TYPE

    • B- Normal copies
    • S- Standby copies

    USED_CHANGE_TRACKING Indicates whether change tracking data was used to accelerate this incremental backup (YES) or whether change tracking data was not used (NO)
    BLOCKS_READ Number of blocks that were scanned while taking this backup. If this was an incremental backup, and change tracking was used to optimize the backup, then the value of this column will be smaller than DATAFILE_BLOCKS. Otherwise, the value of this column will be the same as DATAFILE_BLOCKS. Even when change tracking data is used, the value of this column may be larger than BLOCKS, because the data read by change tracking is further refined during the process of creating an incremental backup.
    USED_OPTIMIZATION 是否使用备份优化
    FOREIGN_DBID Foreign DBID of the database from which this datafile was transported. The value is 0 if the file backed up is not a foreign database file.
    PLUGGED_READONLY YES if this is a backup of a transported read-only foreign file; otherwise NO.
    PLUGIN_CHANGE# SCN at which the foreign datafile was transported into the database. The value is 0 if this file is not a foreign database file.
    PLUGIN_RESETLOGS_CHANGE# The SCN of the RESETLOGS operation for the incarnation into which this foreign file was transported. The value is 0 if this file is not a foreign database file.
    PLUGIN_RESETLOGS_TIME The time of the RESETLOGS operation for the incarnation into which this foreign file was transported. The value is 0 if this file is not a foreign database file.
    SECTION_SIZE Specifies the number of blocks in each section of a multisection backup. Value is 0 for whole file backups.
    UNDO_OPTIMIZED Indicates whether undo blocks were ignored when creating the backup datafile (YES) or not (NO)
    BLOCKS_SKIPPED_IN_CELL Number of blocks that were not backed up because they were skipped by the Exadata cell

    V$BACKUP_REDOLOG

    V$BACKUP_REDOLOG显示控制文件中备份集中的已归档日志的信息,注意,无法直接备份联机重做日志;它们必须先存档到磁盘然后备份,存档日志备份集可以包含一个或多个存档日志

    RECID Record ID for this row; it is an integer that identifies this row
    STAMP Timestamp used with RECID to uniquely identify this row
    SET_STAMP One of the foreign keys for the row of the V$BACKUP_SET table that identifies this backup set
    SET_COUNT One of the foreign keys for the row of the V$BACKUP_SET table that identifies this backup set
    THREAD# Thread number for the log
    SEQUENCE# Log sequence number
    RESETLOGS_CHANGE# Change number of the last resetlogs before the log was written
    RESETLOGS_TIME Change time of the last resetlogs before the log was written. These will be the same for all logs in a backup set.
    FIRST_CHANGE# SCN when the log was switched into. The redo in the log is at this SCN and greater.
    FIRST_TIME Time allocated when the log was switched into
    NEXT_CHANGE# SCN when the next log in this thread was switched into. The redo in the log is below this SCN.
    NEXT_TIME Time when the next log in this thread was switched into
    BLOCKS Size of the log in logical blocks including the header block
    BLOCK_SIZE Size of the log blocks in bytes
    TERMINAL Indicates whether this record corresponds to a terminal archived redo log, as defined in V$ARCHIVED_LOG (YES) or not (NO)

    V$BACKUP_FILES

    V$BACKUP_FILES显示所有RMAN备份(映像副本和备份集)和归档日志的信息,此视图模拟LIST BACKUP和LIST COPY命令,此视图要求使用DBMS_RCVMAN.SETDATABASE过程设置数据库

    PKEY 备份的主键
    BACKUP_TYPE 备份的类型:

    • BACKUP SET
    • COPY
    • PROXY COPY

    FILE_TYPE 文件类型:

    • DATAFILE
    • CONTROLFILE
    • SPFILE
    • REDO LOG
    • ARCHIVED LOG
    • COPY (for an image copy backup)
    • PIECE (for a backup piece)

    KEEP 表示备份是否具有与CONFIGURE RETENTION POLICY(YES)不同的保留策略(NO)
    KEEP_UNTIL 如果指定BACKUP ..KEEP UNTIL TIME子句,则此列显示备份过时的日期;如果为null且KEEP_OPTIONS不为null,则备份永远不会过时
    KEEP_OPTIONS KEEP options for the backup:

    • LOGS - RMAN keeps the logs needed to recover the backup
    • NOLOGS - RMAN does not keep the logs needed to recover the backup

    If this column is null, then the backup has no KEEP options and will be made obsolete based on the retention policy.
    STATUS 备份的状态:

    • AVAILABLE
    • UNAVAILABLE
    • EXPIRED
    • OTHER

    FNAME 文件名
    TAG Tag of the piece, copy, or proxy copy
    MEDIA Media ID of the piece or proxy copy
    RECID Recid of the record in the control file
    STAMP Stamp of the record in the control file
    DEVICE_TYPE 设备类型
    BLOCK_SIZE Block size for the backup (in bytes)
    COMPLETION_TIME Time when the backup completed
    COMPRESSED 备份片是否压缩;仅在FILE_TYPE为PIECE时有效,copy无法压缩
    OBSOLETE 备份片或副本是否过时;仅在FILE_TYPE为PIECE或COPY时有效
    BYTES Size of the file (in bytes)
    BS_KEY 备份集的主键(仅当BACKUP_TYPE为BACKUP SET时有效)
    BS_COUNT 控制文件记录中的备份集计数(仅当BACKUP_TYPE为BACKUP SET时有效)
    BS_STAMP 控制文件记录中设置备份集的戳记(仅当BACKUP_TYPE为BACKUP SET时有效)
    BS_TYPE 备份集的类型(仅当BACKUP_TYPE为BACKUP SET时有效):

    • DATAFILE
    • ARCHIVED LOG

    BS_INCR_TYPE 备份集的增量类型(仅当BACKUP_TYPE为BACKUP SET时有效)
    BS_PIECES 备份集中的备份片数(仅当BACKUP_TYPE为BACKUP SET时有效)
    BS_COPIES 备份集的副本数量(仅当FILE_TYPE为PIECE且BACKUP_TYPE为BACKUP SET时有效)
    BS_COMPLETION_TIME 备份集的完成时间(仅当BACKUP_TYPE为BACKUP SET时有效)
    BS_STATUS 备份集的状态(仅当BACKUP_TYPE为BACKUP SET时有效):

    • AVAILABLE
    • UNAVAILABLE
    • EXPIRED
    • OTHER - 备份集的部分备份片没有统一的状态(即一些是可用的,有些则不可用)

    BS_BYTES 备份集中所有备份片大小的总和(仅当BACKUP_TYPE为BACKUP SET时有效)
    BS_COMPRESSED 表示备份集的备份是否压缩;仅在BACKUP_TYPE为BACKUP SET时有效
    BS_TAG 备份集的标签,如果备份片具有不同的标签,则所有片的标签被连接并用逗号分隔,仅在BACKUP_TYPE为BACKUP SET时有效
    BS_DEVICE_TYPE 备份集的设备类型,如果有多个设备类型,则用逗号分隔,仅在BACKUP_TYPE为BACKUP SET时有效
    BP_PIECE# 备份集内的片数(仅当FILE_TYPE为PIECE且BACKUP_TYPE为BACKUP SET时有效)
    BP_COPY# 备份集的副本数量(仅当FILE_TYPE为PIECE且BACKUP_TYPE为BACKUP SET时有效)
    DF_FILE# 数据文件的绝对文件号(仅当FILE_TYPE为DATAFILE时有效)
    DF_TABLESPACE 数据文件的表空间名称(仅当FILE_TYPE为DATAFILE时有效)
    DF_RESETLOGS_CHANGE# System change number (SCN) of the most recent RESETLOGS when the control file or datafile was created (valid only if FILE_TYPE is DATAFILE)
    DF_CREATION_CHANGE# Creation SCN of the control file or datafile (valid only if FILE_TYPE is CONTROLFILE or DATAFILE)
    DF_CHECKPOINT_CHANGE# System change number (SCN) of the most recent control file or datafile checkpoint (valid only if FILE_TYPE is CONTROLFILE or DATAFILE)
    DF_CKP_MOD_TIME Modification time in case of SPFILE, otherwise time when the control file or datafile was checkpointed (valid only if FILE_TYPE is SPFILE, CONTROLFILE, or DATAFILE)
    RL_THREAD# Redo log thread number of the archived log (valid only if FILE_TYPE is REDO LOG)
    RL_SEQUENCE# Redo log sequence number of the archived log (valid only if FILE_TYPE is REDO LOG)
    RL_RESETLOGS_CHANGE# System change number (SCN) of the most recent RESETLOGS when the record was created (valid only if FILE_TYPE is REDO LOG)
    RL_FIRST_CHANGE# First SCN of the redo log (valid only if FILE_TYPEis REDO LOG)
    RL_FIRST_TIME Time when the Oracle Database switched into the redo log (valid only if FILE_TYPE is REDO LOG)
    RL_NEXT_CHANGE# First SCN of the next redo log in the thread (valid only if FILE_TYPE is REDO LOG)
    RL_NEXT_TIME First timestamp of the next redo log in the thread (valid only if FILE_TYPE is REDO LOG)

     

     

     

  • 相关阅读:
    springMVC上传文件简单案例
    java监听器、定时器的使用
    javaweb的web.xml配置说明,初始化过程
    Linux下解决高并发socket最大连接数限制,tcp默认1024个连接
    tsung压力测试——Tsung测试统计报告说明【转】
    tsung压力测试——tcp测试tsung.xml配置模版说明
    tsung压力测试——安装
    Java同步锁——lock与synchronized 的区别【转】
    Java集合——HashMap,HashTable,ConcurrentHashMap区别
    SpringMVC源码情操陶冶-FreeMarker之web配置
  • 原文地址:https://www.cnblogs.com/guaiguaixiaoqiang/p/11321079.html
Copyright © 2011-2022 走看看