确保工作空间创建于正确的表空间下,从而可以进行适当的数据存储并减缓磁盘争用情况。使用之前修改的 DBTUNE 配置,可以在 Oracle SQL*Plus 或 Oracle SQL Developer 中运行以下脚本示例。
Connect to the BISDB database.
sqlplus bis/bisadmin@bisdb
List the tables and the corresponding tablespace.
SELECT TABLE_NAME, TABLESPACE_NAME, STATUS FROM USER_TABLES ORDER BY 1;
List the indexes by table and tablespace.
SELECT INDEX_NAME, TABLE_NAME, TABLESPACE_NAME, STATUS FROM USER_INDEXES ORDER BY 2,1;
List large objects (LOB) by table.
SELECT * FROM USER_LOBS WHERE SEGMENT_NAME LIKE 'SYS_LOB%' ORDER BY TABLE_NAME;
If any tables or indexes are stored in the wrong tablespace, then ALTER TABLE and ALTER INDEX can be used to change the tablespace (see the following SQL syntax).
ALTER TABLE <table_name> MOVE TABLESPACE <tablespace_name>;
ALTER INDEX <index_name> REBUILD TABLESPACE <tablespace_name>;
如果正在移动大对象 (LOB),则读取 Oracle MetaLink Doc ID:130814.1,“如何将 LOB 数据移动到其他表空间。”