background preloader

Tablespaces

Facebook Twitter

Max size of datafiles. Data files are not exactly unlimited in size, so the term "Unlimited" refers to the ceiling your datafile is able to reach, and it depends on the Oracle Block Size.

Max size of datafiles

To find the absolute maximum file size multiply block size by 4194303. This is the actual maximum size. You may want to read the Metalink Note:112011.1. A datafile cannot be oversized, otherwise it could get corrupted. Let's say if your database is 8k blocks that means that one file can not exceed approximately 34GB (34,359,730,176 bytes) without having database corruption. Sizing datafiles is a matter of manageability, it depends on your storage, the amount of space allocated in a single managed storage unit. Reclaiming Unused Space in Datafiles. There are a number of scenarios that can lead to unused space in datafiles.

Reclaiming Unused Space in Datafiles

The two most common I see are: A lack of housekeeping/maintenance means that one or more tables have grown excessively. After the data is pruned the datafiles contain unused space that needs to be reclaimed. One or more segments (tables, partitions or indexes) have been moved to another tablespace leaving empty areas in the datafiles that previously held them. In this article I will discuss a few of the ways of reclaiming this unused space.

Note. Setup Test Environment Before we can look at the solutions we need to create a test environment so we can clearly see the problem. CONN / AS SYSDBA -- Create a tablespace and user for the test. We can see both table segments are made up of multiple extents, each extent being made up of multiple blocks. Enterprise Manager gives us a nice image of the contents of the tablespace by doing the following: Click on the "Server" tab. Identify Tablespaces with Free Space Export/Import. Reducing datafile size to recover free space – Oracle Database 10g « IN ORACLE MILIEU … At time, we want to recover some space from database just to allocate the same to some other tablespace or to return it back to OS disk.

Reducing datafile size to recover free space – Oracle Database 10g « IN ORACLE MILIEU …

This situation arises many times. And many time we hit with error “ORA-03297: file contains used data beyond requested RESIZE value“. The concept is simple and many of you must be knowing, but just putting in a simpler words. HWM (high watermark) of a tablespace ? How many times have you thought of calculating HWM (high watermark) of a tablespace as a DBA ?

HWM (high watermark) of a tablespace ?

Have you ever found out that a tablespace is overallocated in a database, as compared to the data being used in it ? In such a case, you'd want to reduce the wasted space & resize the tablespace to a smaller size, although greater than the current usage. How to adjust the high watermark in ORACLE 10g – ALTER TABLE SHRINK « lutz hartmann as sysdba. Hanging around in my hotel in Chicago because it is raining, I have been cruising around in the OTN forums which inspired me to write something about the High Watermark and the Oracle 10gR1 New Feature SEGMENT SHRINKING.

How to adjust the high watermark in ORACLE 10g – ALTER TABLE SHRINK « lutz hartmann as sysdba

The High Watermark is the maximum fill-grade a table has ever reached. Above the high watermark are only empty blocks. These blocks can be formatted or unformatted. First let’s have a look at the question when space is allocated - when you create a table at least one extent (contiguous blocks) is allocated to the table - if you have specified MINEXTENTS the number of MINEXTENTS extents will be allocated immedaitely to the table - if you have not specified MINEXTENTS then exactely one extent will be allocated (we will look at extent sizes later in another post). Immediately after creation of the segment (table) the high watermark will be at the first block of the first extent as long as there are no inserts made.

High Watermark (was White watermark)" Submitted on 15-Oct-2007 15:43 UTC Last updated 22-Apr-2013 18:55 You Asked What is the main purpose of white watermark and in a case secnario where all the records have been deleted and we try to lookup that table why does the data is looked untill it reaches to an end of whte watermark and we said...

High Watermark (was White watermark)"

I believe you mean "high watermark" The database doesn't know what is on a block unless and until...... It goes to the block. So, when you delete the information, the block is still "a block", it is just a block that once had active rows - but no longer does. And when you full scan the table - we have to read all blocks that at any time contained data - because - they could contain data now. Suppose you deleted all but ONE row - we have to look in every block (unless of course we use an index) to see if that row is on a given block. <quote src=expert oracle database architecture> High-water Mark This is a term used with table segments stored in the database. Figure 10-1. Oracle: Tablespace verwalten.

Konfiguration von Tablespaces[Bearbeiten] Nach der Installation von Oracle gibt es nur den SYSTEM-Tablespace (bei Oracle Version < 10g), ab Oracle Version 10g gibt es mind. den SYSTEM und den SYSAUX Tablespace.

Oracle: Tablespace verwalten

Es ist empfehlenswert, die System-Daten und die Anwendungsdaten in getrennten Tablespaces zu speichern. Reclaiming Unused Space in Datafiles.