<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[DCI question]]></title><description><![CDATA[<p dir="auto">Is it possible to setup a threshold based on multiple DCI values ?  So if I have four DCI's and I want to sum the values provided by all four and only trigger and alarm if the sum of those four DCI values is &gt;= 50   </p>
<p dir="auto">Thanks</p>
]]></description><link>https://forum.netxms.org/topic/4242/dci-question</link><generator>RSS for Node</generator><lastBuildDate>Fri, 13 Nov 2026 12:16:03 GMT</lastBuildDate><atom:link href="https://forum.netxms.org/topic/4242.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 22 Jan 2016 01:23:38 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to DCI question on Wed, 03 Feb 2016 00:30:03 GMT]]></title><description><![CDATA[<p dir="auto">Thanks,  Ive read the hints but wasnt sure how it pertained to triggering events weather the script needed to return a boolean or value  but from your script i see it needs to return a boolean in order to generate the event ... Thanks for your help</p>
]]></description><link>https://forum.netxms.org/post/19091</link><guid isPermaLink="true">https://forum.netxms.org/post/19091</guid><dc:creator><![CDATA[gmonk63]]></dc:creator><pubDate>Wed, 03 Feb 2016 00:30:03 GMT</pubDate></item><item><title><![CDATA[Reply to DCI question on Wed, 03 Feb 2016 00:15:23 GMT]]></title><description><![CDATA[<p dir="auto">I really recommend reading the script hints, they are available since 2.0+.<br />
Regarding reading another DCI, see this:<br />
<a href="https://wiki.netxms.org/wiki/NXSL:GetDCIValueByDescription" rel="nofollow ugc">https://wiki.netxms.org/wiki/NXSL:GetDCIValueByDescription</a><br />
<a href="https://wiki.netxms.org/wiki/NXSL:GetDCIValueByName" rel="nofollow ugc">https://wiki.netxms.org/wiki/NXSL:GetDCIValueByName</a></p>
<p dir="auto">Here is an example... this is a threshold on disk % usage, depending on the size of the disk.<br />
If disk is smaller then 1GB - 80% threshold.<br />
1GB-1TB - 90% threshold.<br />
1TB+ - 95% threshold.</p>
<pre><code>storageSize = AgentReadParameter($node, "FileSystem.Total(" . $dci-&gt;instance . ")");
if (storageSize == null)
  return false;

if (storageSize &lt; 1099511627776) {
  // for storageSize under 1TB
  if (storageSize &lt; 1073741824) {
    // for storageSize under 1GB, 80%
    usageThreshold  = 80;
  } else {
    // for storageSize between 1GB and 1TB, 90%
    usageThreshold  = 90;
  }
} else {
  // for storageSize above 1TB, 95% threshold
  usageThreshold  = 95;
}

if ($1 &gt; usageThreshold)
  return true;

return false;
</code></pre>
]]></description><link>https://forum.netxms.org/post/19090</link><guid isPermaLink="true">https://forum.netxms.org/post/19090</guid><dc:creator><![CDATA[tomaskir]]></dc:creator><pubDate>Wed, 03 Feb 2016 00:15:23 GMT</pubDate></item><item><title><![CDATA[Reply to DCI question on Wed, 03 Feb 2016 00:08:37 GMT]]></title><description><![CDATA[<p dir="auto">Does any one  have any examples of a dci threshold script ? Im trying to trigger a threshold event but only if the threshold is met and secondary dci is true.. example</p>
<p dir="auto">if (current dci &gt;= 100 and secondary dci is true)<br />
{</p>
<p dir="auto">trigger event</p>
<p dir="auto">}</p>
<p dir="auto">else<br />
{<br />
keep on going<br />
}</p>
<p dir="auto">* Does the threshold script need to return a boolean  or integer to be evaluated</p>
]]></description><link>https://forum.netxms.org/post/19089</link><guid isPermaLink="true">https://forum.netxms.org/post/19089</guid><dc:creator><![CDATA[gmonk63]]></dc:creator><pubDate>Wed, 03 Feb 2016 00:08:37 GMT</pubDate></item><item><title><![CDATA[Reply to DCI question on Thu, 28 Jan 2016 19:00:54 GMT]]></title><description><![CDATA[<p dir="auto">I dont understand exactly what you are trying to achieve, but maybe look at the delta functionality for the DCI.<br />
It will automatically calculate the change of the DCI for the time period, and show you the value the DCI changed by.</p>
]]></description><link>https://forum.netxms.org/post/19036</link><guid isPermaLink="true">https://forum.netxms.org/post/19036</guid><dc:creator><![CDATA[tomaskir]]></dc:creator><pubDate>Thu, 28 Jan 2016 19:00:54 GMT</pubDate></item><item><title><![CDATA[Reply to DCI question on Thu, 28 Jan 2016 17:33:19 GMT]]></title><description><![CDATA[<p dir="auto">tomaskir,</p>
<p dir="auto">Im almost succesfull at what im trying to achieve but im stuck on figuring out a way to reset values after the polling interval  I have four DCI's that collect and increment the values every minute and using your code created an internal DCI which will sum those values every 15min and i want to trigger an alarm based on the totals of the internal DCI  but how do I reset the values  the DCI's  after every poll interval instead of permanently incrementing</p>
]]></description><link>https://forum.netxms.org/post/19035</link><guid isPermaLink="true">https://forum.netxms.org/post/19035</guid><dc:creator><![CDATA[gmonk63]]></dc:creator><pubDate>Thu, 28 Jan 2016 17:33:19 GMT</pubDate></item><item><title><![CDATA[Reply to DCI question on Fri, 22 Jan 2016 02:41:40 GMT]]></title><description><![CDATA[<p dir="auto">Create a script DCI and collect the combined value of the DCIs into the script DCI.</p>
<p dir="auto">Then make the threshold on that DCI.</p>
<p dir="auto">Sample script attached below.<br />
Save it to script library and call it from the script DCI.</p>
<pre><code>val1 = GetDCIValueByDescription($node, "DCI1 description");
val2 = GetDCIValueByDescription($node, "DCI2 description");
val3 = GetDCIValueByDescription($node, "DCI3 description");
val4 = GetDCIValueByDescription($node, "DCI4 description");

if (val1 == null || val2 == null || val3 == null || val4 == null)
  return 0;

return val1 + val2 + val3 + val4;
</code></pre>
]]></description><link>https://forum.netxms.org/post/18931</link><guid isPermaLink="true">https://forum.netxms.org/post/18931</guid><dc:creator><![CDATA[tomaskir]]></dc:creator><pubDate>Fri, 22 Jan 2016 02:41:40 GMT</pubDate></item></channel></rss>