Thursday, April 11, 2019

How to get full database size on oracle database 18c ?

Question : How to get full database size on oracle database 18c ?

Answer : Use below queries to get oracle database size details.

Query :  

select round(sum(bytes/1024/1024/1024)) "total database size in GB" from sm$ts_avail;

select round(sum(bytes/1024/1024/1024)) "total database size in GB" from sm$ts_used;

select round(sum(bytes/1024/1024/1024)/2) "total database size in GB" from sm$ts_free;

Output : 
SQL> select round(sum(bytes/1024/1024/1024)) "total database size in GB" from sm$ts_avail;

total database size in GB
-------------------------
                     4598

SQL> select round(sum(bytes/1024/1024/1024)) "total database size in GB" from sm$ts_used;

total database size in GB
-------------------------
                     3230

SQL> select round(sum(bytes/1024/1024/1024)/2) "total database size in GB" from sm$ts_free;

total database size in GB
-------------------------
                      684

No comments:

Post a Comment

How can I restore Cassandra snapshots?