<?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[Monitor Windows service name based on OS version]]></title><description><![CDATA[<p dir="auto">I'm new to NetXMS and it is working well for our needs. I am tweaking our DCI's now and have a question.</p>
<p dir="auto">I have Windows 2003, 2008, and 2012 servers. I have a template setup to add DCI's to the servers and that works fine. I am monitoring the windows firewall service and the name is different on 2003 ("SharedAccess") compared to 2008/2012 ("MpsSvc"). I would like to use the same template/DCI and detect if it is on 2003. I tried using an instance discovery script, but that did not work.</p>
<p dir="auto">The script I used was:<br />
if($node-&gt;sysDescription like "*2003*") {<br />
$1 = "SharedAccess"<br />
else $1 = "MpsSvc"<br />
}<br />
return true;</p>
<p dir="auto">As an alternative, I tried to make separate templates with Auto apply rules. I tried this for the rule:<br />
return $node-&gt;sysDescription like "*2003*";<br />
and that is not working as I expect.</p>
<p dir="auto">Any suggestions would be appreciated. Thank you.</p>
<p dir="auto">Gary</p>
]]></description><link>https://forum.netxms.org/topic/4726/monitor-windows-service-name-based-on-os-version</link><generator>RSS for Node</generator><lastBuildDate>Fri, 13 Nov 2026 20:11:12 GMT</lastBuildDate><atom:link href="https://forum.netxms.org/topic/4726.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 27 Sep 2016 21:17:18 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Monitor Windows service name based on OS version on Wed, 28 Sep 2016 16:30:05 GMT]]></title><description><![CDATA[<p dir="auto">I got it working.</p>
<p dir="auto">One thing that kept tripping me up is that when I would make a change to the discovery script and then Force DCI poll, it would say that it was unsupported. So I would make more changes and that would be unsupported. I probably had it working earlier and just needed to be patient for NetXMS to do it's thing.</p>
<p dir="auto">I had to still see if it was Windows 2003 because newer versions use both services but only the MpsSvc is the firewall.</p>
<hr />
<p dir="auto"><img src="/assets/uploads/files/smf/0000000003245-Capture.JPG" alt="Capture.JPG" class="img-markdown  img-fluid" width="657" height="402" /></p>
]]></description><link>https://forum.netxms.org/post/21042</link><guid isPermaLink="true">https://forum.netxms.org/post/21042</guid><dc:creator><![CDATA[gdodd]]></dc:creator><pubDate>Wed, 28 Sep 2016 16:30:05 GMT</pubDate></item><item><title><![CDATA[Reply to Monitor Windows service name based on OS version on Wed, 28 Sep 2016 14:23:45 GMT]]></title><description><![CDATA[<p dir="auto">All auto-apply functionality is executed on each node during configuration poll of that node.</p>
<p dir="auto">You can force a conf poll on a node with right click &gt; Poll &gt; Configuration.</p>
<p dir="auto">You can configure how often conf poll runs in Server Configuration - ConfigurationPollingInterval.</p>
]]></description><link>https://forum.netxms.org/post/21021</link><guid isPermaLink="true">https://forum.netxms.org/post/21021</guid><dc:creator><![CDATA[tomaskir]]></dc:creator><pubDate>Wed, 28 Sep 2016 14:23:45 GMT</pubDate></item><item><title><![CDATA[Reply to Monitor Windows service name based on OS version on Wed, 28 Sep 2016 12:34:02 GMT]]></title><description><![CDATA[<p dir="auto">Thank you for the reply.</p>
<p dir="auto">My original template script worked, it just took longer than expected to apply. How often is it checked to see if a template should be automatically applied? The active discovery interval?</p>
<p dir="auto">Can you see a way to make it work so I only need one template?</p>
]]></description><link>https://forum.netxms.org/post/21020</link><guid isPermaLink="true">https://forum.netxms.org/post/21020</guid><dc:creator><![CDATA[gdodd]]></dc:creator><pubDate>Wed, 28 Sep 2016 12:34:02 GMT</pubDate></item><item><title><![CDATA[Reply to Monitor Windows service name based on OS version on Tue, 27 Sep 2016 21:24:19 GMT]]></title><description><![CDATA[<p dir="auto">Try</p>
<pre><code>if ($node-&gt;sysDescription ~= ".*2003.*")
  println("matches");
</code></pre>
<p dir="auto">"~=" is a regex comparison.</p>
]]></description><link>https://forum.netxms.org/post/21012</link><guid isPermaLink="true">https://forum.netxms.org/post/21012</guid><dc:creator><![CDATA[tomaskir]]></dc:creator><pubDate>Tue, 27 Sep 2016 21:24:19 GMT</pubDate></item></channel></rss>