<?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[NXLS state and runtimeFlags in v3.0]]></title><description><![CDATA[<p dir="auto">Hi</p>
<p dir="auto">After upgrading from 2.2.17 to 3.0.2292 runtimeFlags and state in NXLS does not show correct values.</p>
<p dir="auto">Debugging with a Dummy dci on nodes and return $node-&gt;runtimeFlags + $node-&gt;state gives this results:</p>
<p dir="auto">Node with active alarm, not responding to ICMP (dead) and only ICMP poll:<br />
$node-&gt;runtimeFlags = 4<br />
$node-&gt;state = 5</p>
<p dir="auto">Node with no active alarm, responding to ICMP and only ICMP poll :<br />
$node-&gt;runtimeFlags = 4<br />
$node-&gt;state = 4</p>
<p dir="auto">Node with no active alarm, responding to ICMP and nxagent+ICMP poll:<br />
$node-&gt;runtimeFlags = 4<br />
$node-&gt;state = 0</p>
<p dir="auto">How can i stable check whetever Node is dead or not within NXLS?<br />
We are using this on dummy/external+proxy DCI's to prevent them raising alarms when node is dead(not responding to ICMP or Agent)</p>
<p dir="auto">We used this before:</p>
<blockquote>
<p dir="auto">if ($node-&gt;runtimeFlags &amp; 0x0004) {<br />
    return true;<br />
}</p>
</blockquote>
]]></description><link>https://forum.netxms.org/topic/6195/nxls-state-and-runtimeflags-in-v3.0</link><generator>RSS for Node</generator><lastBuildDate>Fri, 13 Nov 2026 20:02:34 GMT</lastBuildDate><atom:link href="https://forum.netxms.org/topic/6195.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 28 Sep 2019 07:32:39 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to NXLS state and runtimeFlags in v3.0 on Mon, 30 Sep 2019 06:46:39 GMT]]></title><description><![CDATA[<p dir="auto">Thanks for the clarifications, this helped me alot <img src="https://forum.netxms.org/assets/plugins/nodebb-plugin-emoji/emoji/android/1f642.png?v=72b86a538fc" class="not-responsive emoji emoji-android emoji--slightly_smiling_face" style="height:1.4em;width:auto;vertical-align:middle" title=":)" alt="🙂" /></p>
]]></description><link>https://forum.netxms.org/post/26642</link><guid isPermaLink="true">https://forum.netxms.org/post/26642</guid><dc:creator><![CDATA[Borgso]]></dc:creator><pubDate>Mon, 30 Sep 2019 06:46:39 GMT</pubDate></item><item><title><![CDATA[Reply to NXLS state and runtimeFlags in v3.0 on Sat, 28 Sep 2019 13:17:02 GMT]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto">now you should use <em>state</em> attribute to determine node state. For convenience server version 3.0 defines constants for each state:</p>
<p dir="auto">NodeState::Unreachable<br />
NodeState::NetworkPathProblem<br />
NodeState::AgentUnreachable<br />
NodeState::SNMPUnreachable<br />
NodeState::CacheModeNotSupported</p>
<p dir="auto">ClusterState::Unreachable<br />
ClusterState::NetworkPathProblem<br />
ClusterState::Down</p>
<p dir="auto">SensorState::Unreachable<br />
SensorState::NetworkPathProblem<br />
SensorState::Provisioned<br />
SensorState::Registered<br />
SensorState::Active<br />
SensorState::PendingConfigUpdate</p>
<p dir="auto">So equivalent of 2.2.x</p>
<pre><code>if ($node-&gt;runtimeFlags &amp; 0x0004)
</code></pre>
<p dir="auto">will be</p>
<pre><code>if ($node-&gt;state &amp; NodeState::Unreachable)
</code></pre>
<p dir="auto">State bit 4 is not used and it's presence is a bit of a mystery. Probably something goes wrong during DB upgrade. You can left it as is - it will not affect anything, or clean it up in database while server is stopped using the following queries:</p>
<p dir="auto">UPDATED object_properties SET state=0 WHERE state=4;<br />
UPDATED object_properties SET state=1 WHERE state=5;</p>
<p dir="auto">This will clean it up for most common flag combinations.</p>
<p dir="auto">If you are using PostgreSQL you should be able to do this in one query using bitwise AND:</p>
<p dir="auto">UPDATED object_properties SET state=state &amp; ~4;</p>
<p dir="auto">Best regards,<br />
Victor</p>
]]></description><link>https://forum.netxms.org/post/26637</link><guid isPermaLink="true">https://forum.netxms.org/post/26637</guid><dc:creator><![CDATA[victor]]></dc:creator><pubDate>Sat, 28 Sep 2019 13:17:02 GMT</pubDate></item></channel></rss>