Oracle tablespaces (tablespace), segments (segment), disk partitions (extent), and blocks are the allocation units used by Oracle to save database objects.
A segment is a database object that consumes storage space, such as tables, indexes, and rollback segments. When you create a table, a table segment is created. When you create a partition table, a segment is created for each partition. When you create an index, an index segment is created, objects that consume storage space are stored in a single segment, including rollback segments, temporary segments, clustering segments, and index segments. A segment can have disks from many inaccessible data files.
The segment itself is composed of one or more disk areas. The Disk Area continuously allocates space in the file. Each segment starts at least one disk area, some objects may need at least two disk zones (such as rollback segments ). Each disk is not necessarily adjacent.
A disk is composed of blocks. A block is the smallest unit for space allocation in Oracle. It is an oracle disk read/write object. The blocks in Oracle usually have three common sizes: 2 K, 4 K, 8 K.
A segment is composed of one or more disk areas, and a disk area is composed of some continuously allocated blocks.
A tablespace is a container that stores segments. Each segment exactly belongs to a tablespace. A tablespace can have multiple segments. All the disk partitions of a given segment are in the tablespace related to the segment.
The level of storage in Oracle is as follows:
1. A database consists of one or more tablespaces.
2. a tablespace consists of one or more data files. A tablespace contains segments.
3. A segment consists of one or more disk partitions. The segments exist in the tablespace, but many data files can exist in the tablespace.
4. The Disk Area is a continuous block group on the disk. A disk area is in a tablespace and is always in a single file in the tablespace.
5. blocks are the smallest allocation units in the database, and blocks are the smallest I/O units used by the database.