《ORACLE DBA基础培训教程:从实践中学习ORACLE DBA》 读书笔记

来源:互联网 发布:实战型锋卫训练场淘宝 编辑:程序博客网 时间:2024/05/17 06:49

《ORACLE DBA基础培训教程:从实践中学习ORACLE DBA》

oerr帮助ORA-XXXX错误

[oracle@dd ~]$ oerr
Usage: oerr facility error

Facility is identified by the prefix string in the error message.
For example, if you get ORA-7300, "ora" is the facility and "7300"
is the error.  So you should type "oerr ora 7300".

If you get LCD-111, type "oerr lcd 111", and so on.
[oracle@dd ~]$ oerr ora 1555
01555, 00000, "snapshot too old: rollback segment number %s with name \"%s\" too small"
// *Cause: rollback records needed by a reader for consistent read are
//         overwritten by other writers
// *Action: If in Automatic Undo Management mode, increase undo_retention
//          setting. Otherwise, use larger rollback segments
[oracle@dd ~]$ oerr ora 600
00600, 00000, "internal error code, arguments: [%s], [%s], [%s], [%s], [%s], [%s], [%s], [%s]"
// *Cause:  This is the generic internal error number for Oracle program
//         exceptions.  This indicates that a process has encountered an
//         exceptional condition.
// *Action: Report as a bug - the first argument is the internal error number
[oracle@dd ~]$


内存缓冲区顾问
SQL> select id,name,block_size,advice_status from v$db_cache_advice;                                                   

        ID NAME                 BLOCK_SIZE ADV
---------- -------------------- ---------- ---
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON
         3 DEFAULT                    8192 ON

21 rows selected.

SQL>
SQL> alter system set db_cache_advice=off;                                                                             

System altered.

SQL> select id,name,block_size,advice_status from v$db_cache_advice;                                                   

        ID NAME                 BLOCK_SIZE ADV
---------- -------------------- ---------- ---
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF
         3 DEFAULT                    8192 OFF

21 rows selected.


SQL> EXECUTE DBMS_SPACE_ADMIN.TABLESPACE_MIGRATE_FROM_LOCAL('TBALESPACENAME'); ---------表空间转换
SQL> EXECUTE DBMS_SPACE_ADMIN.TABLESPACE_MIGRATE_TO_LOCAL('TBALESPACENAME');---------表空间转换


OMF来管理表空间
alter system set db_create_file_dest='/opt/oracle/';


 

原创粉丝点击