Oracle Tutorial: ORA-01653 error Solution

Source: Internet
Author: User

  1. ---- Query table space usage ---
  2. SELECT UPPER(F. TABLESPACE_NAME)"Tablespace name",
  3. D. TOT_GROOTTE_MB"Tablespace size (MB )",
  4. D. TOT_GROOTTE_MB-F. TOTAL_BYTES"Used space (M )",
  5. TO_CHAR (ROUND (D. TOT_GROOTTE_MB-F. TOTAL_BYTES)/D. TOT_GROOTTE_MB * 100,2 ),'1970. 99')"Usage ratio",
  6. F. TOTAL_BYTES"Free Space (M )",
  7. F. MAX_BYTES"Maximum block (M )"
  8. FROM(SELECTTABLESPACE_NAME,
  9. ROUND (SUM(BYTES) // (1024*1024), 2) TOTAL_BYTES,
  10. ROUND (MAX(BYTES)/(1024*1024), 2) MAX_BYTES
  11. FROMSYS. DBA_FREE_SPACE
  12. GROUP BYTABLESPACE_NAME) F,
  13. (SELECTDD. TABLESPACE_NAME,
  14. ROUND (SUM(DD. BYTES)/(1024*1024), 2) TOT_GROOTTE_MB
  15. FROMSYS. DBA_DATA_FILES DD
  16. GROUP BYDD. TABLESPACE_NAME) D
  17. WHERED. TABLESPACE_NAME = F. TABLESPACE_NAME
  18. ORDER BY4DESC;
 
  1. ---- Query table space usage ---
  2. SELECT UPPER(F. TABLESPACE_NAME)"Tablespace name",
  3. D. TOT_GROOTTE_MB"Tablespace size (MB )",
  4. D. TOT_GROOTTE_MB-F. TOTAL_BYTES"Used space (M )",
  5. TO_CHAR (ROUND (D. TOT_GROOTTE_MB-F. TOTAL_BYTES)/D. TOT_GROOTTE_MB * 100,2 ),'1970. 99')"Usage ratio",
  6. F. TOTAL_BYTES"Free Space (M )",
  7. F. MAX_BYTES"Maximum block (M )"
  8. FROM(SELECTTABLESPACE_NAME,
  9. ROUND (SUM(BYTES) // (1024*1024), 2) TOTAL_BYTES,
  10. ROUND (MAX(BYTES)/(1024*1024), 2) MAX_BYTES
  11. FROMSYS. DBA_FREE_SPACE
  12. GROUP BYTABLESPACE_NAME) F,
  13. (SELECTDD. TABLESPACE_NAME,
  14. ROUND (SUM(DD. BYTES)/(1024*1024), 2) TOT_GROOTTE_MB
  15. FROMSYS. DBA_DATA_FILES DD
  16. GROUP BYDD. TABLESPACE_NAME) D
  17. WHERED. TABLESPACE_NAME = F. TABLESPACE_NAME
  18. ORDER BY4DESC;
SQL code
  1. -- Check whether the tablespace can be automatically expanded.
  2. SELECTT. TABLESPACE_NAME, D. FILE_NAME,
  3. D. AUTOEXTENSIBLE, D. BYTES, D. MAXBYTES, D. STATUS
  4. FROMDBA_TABLESPACES T, DBA_DATA_FILES D
  5. WHERET. TABLESPACE_NAME = D. TABLESPACE_NAME
  6.  ORDER BYTABLESPACE_NAME, FILE_NAME;
 
  1. -- Check whether the tablespace can be automatically expanded.
  2. SELECTT. TABLESPACE_NAME, D. FILE_NAME,
  3. D. AUTOEXTENSIBLE, D. BYTES, D. MAXBYTES, D. STATUS
  4. FROMDBA_TABLESPACES T, DBA_DATA_FILES D
  5. WHERET. TABLESPACE_NAME = D. TABLESPACE_NAME
  6.  ORDER BYTABLESPACE_NAME, FILE_NAME;
SQL code
  1. -- Modify the extension mode of tablespace files:
  2. ALTER DATABASE
  3. DATAFILE'/U01/Oracle/oradata/orcl/ccen01.dbf'AUTOEXTEND
  4. ON NEXT50 M MAXSIZE UNLIMITED
 
  1. -- Modify the extension mode of tablespace files:
  2. ALTER DATABASE
  3. DATAFILE'/U01/oracle/oradata/orcl/ccen01.dbf'AUTOEXTEND
  4. ON NEXT50 M MAXSIZE UNLIMITED
The query solution on the internet is as follows:
1. Enable the tablespace Extension function;

2. Increase the tablespace space;

3. Add data files to the tablespace;

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.