Data Segment Statuses
You can check the status of your system segment groups by querying thesys.segment_groups system catalog table. For details, see System Catalog.
This table describes the states for data segments.
Recovery Considerations
If a segment has the DAMAGED or MISSING status, queries can proceed by reconstructing the data on demand using the remaining erasure-coded data in the segment group. Having a non-INTACT status means that input or output (I/O) performance is significantly reduced. To restore full performance, you need to run a segment rebuild task. Segment rebuilding is not automatic. The system administrator must manually invoke it. A segment rebuild fails, and data is lost completely if the number of segments with the DAMAGED status in a segment group exceeds the parity width of the storage space. To avoid data loss:- Provision the parity width of the storage space at or above the number of expected concurrent node failures.
- Rebuild damaged or permanently missing segments as soon as possible.
Checking for Abnormal Segments
You can find any segments that need a rebuild by querying for segment groups with an abnormal status. Examples Finding Faulty Segment Groups This example query finds any segment groups with the DAMAGED or MISSING status.SQL
Text
SQL
Text
Starting a Segment Rebuild Task
A user with System Administrator privileges can start a segment rebuild using theCREATE TASK TYPE REBUILD SQL statement. You cannot cancel a segment rebuild task after it is started.
Most commonly, a rebuild task repairs all damaged or missing segments across the system.
Example
Create a rebuild task.
SQL
Advanced Rebuild Commands
Rebuild tasks can also execute on specific Foundation Nodes or clusters. For information on fine-tuning rebuild tasks, see CREATE TASK.Checking Rebuild Task Status
Monitor the status of current and past segment rebuild tasks from thesys.subtasks system catalog table. For details, see System Catalog.
SQL

