π§ Why Internals Matter
When performance drops, SQL alone is not enough.
You need to inspect:
Storage layout
Sessions
Memory usage
ποΈ GBase Storage Structure
GBase organizes data into:
Dbspace β logical storage
Chunk β physical file
Page β smallest unit
π οΈ Inspect Storage with onstat -d
onstat -d
This shows:
Dbspace info
Chunk paths
Free space usage
Example output includes dbspace and chunk statistics
π Check Active Sessions
onstat -g ses
Use this to:
Identify long-running queries
Detect memory-heavy sessions
β οΈ Kill Problematic Sessions
onmode -z
π¬ Deep Inspection with oncheck
oncheck -pt database:table
This allows:
Page-level inspection
Row storage verification
π§ͺ Typical Debug Workflow
Detect slow query
Check sessions
Analyze storage
Inspect physical pages
β‘ Key Insight
GBase provides low-level observability, which many databases hide.
π You can debug at the storage layer
π Not just at SQL level
Final Thoughts
If SQL is your interface, onstat is your microscope.
π It reveals whatβs really happening
π Helps pinpoint bottlenecks
π Enables deep optimization
Top comments (0)