Thumbs up for this topic! To calculate Total Space Used on all filesystems, into single aggregate DCI:
Code Select
UsedSpaceTotal=0;
foreach (dci : FindAllDCIs($node,"FileSystem.Used*") )
{
dciValue = GetDCIValue($node,dci->id);
if ( dciValue == null ) continue; // To skip in case of errors
UsedSpaceTotal+=dciValue;
}
return UsedSpaceTotal;