After the SmartIO feature is configured, you can verify that the cache area is present and that caching is occurring.
For a VxFS cache area, the sfcache list command shows the caching mode for the file or directory. If the mode is not explicitly set, the file or directory inherits the caching mode of the mount point. If the mode is explicitly set for a file or directory, that value persists across remounts. The displayed caching mode may differ from the mode that is enabled for the mount point. The writeback mode is not enabled unless the file system is mounted in writeback mode. If a file or directory is set to writeback mode, but the file system is mounted in another mode, the file or directory inherits the caching mode of the mount point.
To verify and monitor the cache area
# sfcache list
For example, a single-node VxFS cache area displays output as follows:
NAME TYPE SIZE ASSOC-TYPE STATE DEVICE sfcachearea_2 VxFS 9.96g AUTO ONLINE ssd0_0
For a cluster file system with writeback enabled, if you issue the sfcache list command just after you mount with writeback enabled (and before any read caching has happened), the output shows the space used in cache as 1.0 GB. Cache reflection is configured, with a local log and a remote log that each have a log size of 512 MB.
# sfcache list sfcachearea_2
Cachearea: sfcachearea_2 Assoc Type: AUTO Type: VxFS Size: 9.96g State: ONLINE Layout: CONCAT Number of Columns: 0 /dev/vx/dsk/cachedg/ssdvol: FSUUID SIZE MODE MOUNTPOINT 5dfe4a52805b0b003c7600002cde6d2ce70300005dfe4a52 551.0 MB writeback /mnt1 5efe4a52eb76000041760000a0dec33fe70300005efe4a52 39.0 MB read /mnt2 5efe4a524a86050046760000b485af64e70300005efe4a52 551.0 MB writeback /mnt3
The output displays information about the cache configuration and attributes.
# sfcache list /mnt1
/mnt1: READ CACHE WRITEBACK MODE PINNED NAME 39.0 MB 0 KB writeback yes /mnt1/dir 39.0 MB 0 KB writeback yes /mnt1
# sfcache stat sfcachearea_2
TYPE: VxFS NAME: sfcachearea_2 Cache Size: 9.97 GB Cache Utilization: 1.133 GB (11.37 %) File Systems Using Cache: 3 Writeback Cache Use Limit: 8 GB Writeback Flush Timelag: 10 s Read Cache Writeback Hit Ratio Data Read Data Written Hit Ratio Data Written Total: 0.00 % 0 KB 195.0 MB 100.00 % 78.0 MB /mnt1: 0.00 % 0 KB 78.0 MB 100.00 % 39.0 MB /mnt2: 0.00 % 0 KB 39.0 MB 0.00 % 0 KB /mnt3: 0.00 % 0 KB 78.0 MB 100.00 % 39.0 MB
The output displays statistics for the cached data.
# sfcache stat /mnt1
Cache Size: 9.97 GB Cache Utilization: 551.0 MB ( 5.40 %) Read Cache Writeback Hit Ratio Data Read Data Written Hit Ratio Data Written /mnt1: 0.00 % 0 KB 78.0 MB 100.00 % 39.0 MB
syslogto verify whether writeback mode caching is enabled.
You should see a line such as the following in the
vxfs: msgcnt 4 writeback caching is enabled for /dev/vx/dsk/testdg/vol1
If writeback mode caching is disabled for a particular file system, you would see a line such as the following in the
vxfs: msgcnt 9 writeback caching is disabled for /dev/vx/dsk/testdg/vol1