You can monitor chunks for the following information:
This information allows you to track the disk space used by chunks, monitor chunk I/O activity, and check for fragmentation.
You can use the following command-line utilities to obtain information about chunks.
The onstat -d utility lists all dbspaces and the following information for the chunks within those spaces.
The dbspace flags indicate whether a dbspace is mirrored. The chunk flags provide the following information:
Sample output for onstat -D, which displays the same information plus two additional fields, appears in Figure 69. For descriptions of the onstat -d flags, see the utilities chapter in the IBM Informix: Administrator's Reference.
The onstat -D option displays the same information as onstat -d, plus the number of pages read from the chunk (in the page Rd field).
Figure 69 shows sample output.
Dbspaces address number flags fchunk nchunks flags owner name 40d100 1 1 1 1 N informix rootdbs 40d144 2 2 2 1 M informix cookedspace 40d188 3 10 3 1 N B informix cookedblob 3 active, 10 total Chunks address chk/dbs offset page Rd page Wr pathname 40c274 1 1 0 146 4 /home/server/root_chunk 40c30c 2 2 0 1 0 /home/server/test_chunk 40c8fc 2 2 0 36 0 /home/server/test_mirr 40c3a4 3 3 0 4 0 /home/server/blob_chunk 3 active, 10 total
The onstat -g iof option displays the number of reads from each chunk and the number of writes to each chunk. If one chunk has a disproportionate amount of I/O activity against it, this chunk might be a system bottleneck. This option is useful for monitoring the distribution of I/O requests against the different fragments of a fragmented table. Figure 70 shows sample output.
... AIO global files: gfd pathname totalops dskread dskwrite io/s 3 raw_chunk 38808 27241 11567 6.7 4 cooked_chk1 7925 5660 2265 1.4 5 cooked_chk2 3729 2622 1107 0.6
To list the contents of the reserve pages, execute onutil CHECK RESERVED.
To obtain the physical layout of information, execute onutil CHECK SPACE.
The following information is displayed:
The tables within a chunk are listed sequentially. This output is useful for determining the extent of chunk fragmentation. If the database server is unable to allocate an extent in a chunk despite an adequate number of free pages, the chunk might be badly fragmented.
Query the syschunks table to obtain the status of a chunk. The following columns are relevant.
The syschkio table contains the following columns.