MAXDATAFILES和db_files的关系

DB:10.2.0.5

OS:windows 2008 64 bit


MAXDATAFILES和db_files都是设定datafile数量的上限值。MAXDATAFILES是在controlfile里的,而db_files是在初始化文件里面设定的。

那datafiles的上限值到底是由谁决定呢,

1 查看contrifle的MAXDATAFILES

select records_total,records_used from v$controlfile_record_section where type = 'DATAFILE'

records_total  records_used

45                   44

show parameter db_files

200

再添加两个datafile,系统并没有报错,发现controlfile自动扩展了

alter tablespace SMTRTIDX add datafile 'E:\oradata\sfcdb\SMTRTIDX02.dbf' size 10m
Mon Apr 14 20:39:20 China Standard Time 2014
Completed: alter tablespace SMTRTIDX add datafile 'E:\oradata\sfcdb\SMTRTIDX02.dbf' size 10m
Mon Apr 14 20:39:26 China Standard Time 2014
alter tablespace SMTRTIDX add datafile 'E:\oradata\sfcdb\SMTRTIDX03.dbf' size 10m
Expanded controlfile section 4 from 45 to 90 records
Requested to grow by 45 records; added 1 blocks of records

Completed: alter tablespace SMTRTIDX add datafile 'E:\oradata\sfcdb\SMTRTIDX03.dbf' size 10m


但是如果db_files达到上限就无法再增加datafiles了


SQL> alter tablespace TBSXXWB add datafile 'E:\oradata\sfcdb\TBSXXWB02.dbf' size
 10m;
alter tablespace TBSXXWB add datafile 'E:\oradata\sfcdb\TBSXXWB02.dbf' size 10m
*
ERROR at line 1:

ORA-00059: maximum number of DB_FILES exceeded



数据库中真正的最大的datafiles 的个数由DB_FILES 参数决定,虽然控制文件中也有限制,但是这个控制文件中的限制参数会自动的增加,直到到达DB_FILES的值

参考:



单击此项可添加到收藏夹转到底部转到底部

2013-4-11PROBLEM
为此文档评级通过电子邮件发送此文档的链接在新窗口中打开文档可打印页

Problem Description
-------------------

The "alert.log" file shows the following message:

    kccrsz: expanded controlfile section 4 from 17 to 18 records
            number of logical blocks in section remains at 2
    Completed: alter tablespace tb1 add datafile


Solution Description
--------------------

Starting in Oracle8 the controlfile is automatically expanded. 
A new datafile is added beyond the maxdatafiles limited specified
in the control file.  

This also happens if new records are added to the "log_history" section of 
the control files and there are no entries that could be replaced.  

The routine that performs the expansion writes this message to the alert log. 
The messages specifies the section that was expanded and the amount of 
the expansion. Please note that this message cannot be turned off.

The automatic expansion only occurs up to the limit of the "init.ora" parameter
"DB_FILES".
  

References:
-----------

Server SQL Reference: create controlfile



Additional Search Words
-----------------------

kccrsz controlfile expanded


单击此项可添加到收藏夹转到底部转到底部

2013-4-11PROBLEM
为此文档评级通过电子邮件发送此文档的链接在新窗口中打开文档可打印页

Problem Description
-------------------

The "alert.log" file shows the following message:

    kccrsz: expanded controlfile section 4 from 17 to 18 records
            number of logical blocks in section remains at 2
    Completed: alter tablespace tb1 add datafile


Solution Description
--------------------

Starting in Oracle8 the controlfile is automatically expanded. 
A new datafile is added beyond the maxdatafiles limited specified
in the control file.  

This also happens if new records are added to the "log_history" section of 
the control files and there are no entries that could be replaced.  

The routine that performs the expansion writes this message to the alert log. 
The messages specifies the section that was expanded and the amount of 
the expansion. Please note that this message cannot be turned off.

The automatic expansion only occurs up to the limit of the "init.ora" parameter
"DB_FILES".
  

References:
-----------

Server SQL Reference: create controlfile



Additional Search Words
-----------------------

kccrsz controlfile expanded

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值