加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

Oracle审计相关对象的迁移

发布时间:2020-12-12 13:31:03 所属栏目:百科 来源:网络整理
导读:目录 创建审计用的表空间 在线迁移 查询结果 在日常的数据库维护中,经常出现因为数据库登录审计的功能启动,导致system表空间被用满.从而出现异常,一般建议把aud$相关对象迁移到其他表空间,从而避免system被用完的风险. 步骤如下: 创建审计用的表空间 [emai

目录

  • 创建审计用的表空间
  • 在线迁移
  • 查询结果

在日常的数据库维护中,经常出现因为数据库登录审计的功能启动,导致system表空间被用满.从而出现异常,一般建议把aud$相关对象迁移到其他表空间,从而避免system被用完的风险.
步骤如下:

创建审计用的表空间

[email?protected]> create tablespace audit_data logging datafile ‘/oracle/oradata/kyeupdbfs/audit_data.dbf‘
  2  size 20m autoextend off extent management local segment space management auto;

Tablespace created.

在线迁移

[email?protected]> alter table aud$ move tablespace audit_data;

Table altered.

[email?protected]> alter table audit$ move tablespace audit_data;

Table altered.

[email?protected]> alter table audit_actions move tablespace audit_data;

Table altered.

[email?protected]> alter index i_audit rebuild online tablespace audit_data;

Index altered.

[email?protected]> alter index i_audit_actions rebuild online tablespace audit_data;

Index altered.

查询结果

``` select table_name,tablespace_name from dba_tables where table_name like ‘%AUD%‘; select index_name,tablespace_name from dba_indexes where table_name like ‘%AUD%‘; select table_name,tablespace_name from dba_tables where tablespace_name=‘AUDIT_DATA‘; select index_name,tablespace_name from dba_indexes where tablespace_name=‘AUDIT_DATA‘;

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读