CTmetrics monitors disk and application status and outputs a stream of related metrics data such as disk storage usage.

Usage:

CTmetrics outputs the following channels:

  • DataSpace: an estimate of the amount of data in this source (bytes); either reported for the whole CloudTurbine source folder or on a source-by-source basis (if the “-i” command line flag has been specified)
  • DiskSpace: an estimate of the disk space taken up by the source folder; this estimate accounts for the physical sector size (blocks) the system uses for writing out data files (based on the specified diskBlockSize, which defaults to 4096 bytes); DiskSpace is either reported for the whole CloudTurbine source folder or on a source-by-source basis (if the “-i” command line flag has been specified)
  • FreeSpace: an estimate of the free space on the disk partition where the CloudTurbine data resides; this is the free space reported by the Java method java.io.File.getFreeSpace()

DataSpace is not equal to DiskSpace because operating systems write data to file in blocks.  For example, if the CT data files being written to disk are small compared to the block size, there will be a significant gap between these parameters (with DiskSpace larger than DataSpace).  Microsoft Windows users can see the difference between these values by right-clicking on a folder or file in File Explorer and selecting Properties; both “Size” (the corollary of DataSpace) and “Size on disk” (the corollary of DiskSpace) are presented.  Linux users can see this difference by listing a folder or file using “ls -l” (DataSpace) versus “du -h” (DiskSpace).