Oracle 参数 ROLLBACK_SEGMENTS 官方解释,作用,如何配置最优化建议

本站中文解释

ROLLBACK_SEGMENTS参数用于指定回滚段的列表,用以存储事务的回滚信息。该参数可指定多个回滚段,回滚段的名称和大小需要在用户创建回滚段之前进行设置,ROLLBACK_SEGMENTS参数的多个值之间用”,”分隔。

设置ROLLBACK_SEGMENTS参数的步骤如下:

1、 首先,用户需要计算所有应用程序可能执行的最大事务数,然后根据此计算出回滚段数量。一般情况下,每10个并发事务将需要一个回滚段。

2、然后,需要为每个回滚段创建一个存储空间,一般来说,回滚段的最佳大小为10MB。

3、在执行以上步骤之后,就可以设置ROLLBACK_SEGMENTS参数了,在设置参数之前,用户需要确定哪几个回滚段需要完成事务,最后以字符串的形式进行设置,用“,”分隔多个回滚段的参数值,如“RB1,RB2,RB3”。

4、最后,可以使用SQL语句来验证是否正确设置了ROLLBACK_SEGMENTS参数,可以使用“SHOW PARAMETER ROLLBACK_SEGMENTS”语句来查看参数的设置情况。

官方英文解释

ROLLBACK_SEGMENTS allocates one or more rollback segments by name to this instance.

Property Description

Parameter type

String

Syntax

ROLLBACK_SEGMENTS =

(segment_name [, segment_name] ... )

Default value

If you do not specify this parameter, the instance uses public rollback segments by default, unless the UNDO_MANAGEMENT initialization parameter is set to AUTO. In that case, the ROLLBACK_SEGMENTS parameter is ignored and automatic undo management is used.

Modifiable

No

Modifiable in a PDB

Yes

Range of values

Any rollback segment names listed in DBA_ROLLBACK_SEGS except SYSTEM

Basic

No

Oracle RAC

Multiple instances must have different values.

If you set this parameter, the instance acquires all of the rollback segments named in this parameter, even if the number of rollback segments exceeds the minimum number required by the instance (calculated as TRANSACTIONS / TRANSACTIONS_PER_ROLLBACK_SEGMENT).

You cannot change the value of this parameter dynamically, but you can change its value and then restart the instance. Although this parameter usually specifies private rollback segments, it can also specify public rollback segments if they are not already in use.

To find the name, segment ID number, and status of each rollback segment in the database, query the data dictionary view DBA_ROLLBACK_SEGS.

When UNDO_MANAGEMENT is set to AUTO, ROLLBACK_SEGMENTS is ignored.

See Also:

  • Oracle Real Application
    Clusters Administration and Deployment Guide
    for information on setting this parameter in an Oracle RAC environment

  • “DBA_ROLLBACK_SEGS”


数据运维技术 » Oracle 参数 ROLLBACK_SEGMENTS 官方解释,作用,如何配置最优化建议