In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly introduces how to expand Oracle database space, which has certain reference value. Interested friends can refer to it. I hope you will gain a lot after reading this article. Let Xiaobian take you to understand it together.
The method/steps are as follows:
1. Query the table space corresponding to the user, we can see Oracle for different database users
select username, default_tablespace, temporary_tablespacefrom dba_users;
2. Query the corresponding data file of the user and the size of the data file
select tablespace_name, file_id, file_name,round(bytes/(1024*1024),0) total_spacefrom dba_data_filesorder by tablespace_name;
3. According to the table space corresponding to the user in 1.2 and the size of the table space, you can check the current usage percentage through the following statement. If the used space is no longer within the following query range, it proves that this space is full. There is no remaining space in the SQL below. We can see that one space has reached 95%.
SELECT a.tablespace_name "tablespace name",total "tablespace size",free "tablespace remaining size",(total - free) "Tablespace usage size",total /(1024 * 1024 * 1024) "Tablespace size",free /(1024 * 1024 * 1024) "Remaining Size of Tablespace (G)",(total - free) /(1024 * 1024 * 1024) "Tablespace usage size",round ((total - free) / total, 4) * 100 "Usage %"FROM (SELECT tablespace_name, SUM(bytes) freeFROM dba_free_spaceGROUP BY tablespace_name) a,(SELECT tablespace_name, SUM(bytes) totalFROM dba_data_filesGROUP BY tablespace_name) bWHERE a.tablespace_name = b.tablespace_name ;
4. At this point we execute the spatial augmentation statement. Increase 95% usage from 1800 MB to 3000 MB
alter database datafile '/u2/oracle/PLM_SD_data' resize 3000m
After successful amplification, as shown in the figure below
5. At this time, the execution of the space utilization query statement yields the following results, and you can see that the space expansion is successful.
6. Finally, we query whether the space has become 3000M through SQL statements.
Of course, in order to prevent insufficient space, resulting in exceptions, you can also set the space to automatically extend. However, I do not recommend using this function, because it may lead to unlimited space spread.
Thank you for reading this article carefully. I hope that the article "Oracle Database Space is Full How to Expand Space" shared by Xiaobian will be helpful to everyone. At the same time, I hope that everyone will support you a lot and pay attention to the industry information channel. More relevant knowledge is waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.