NetXMS Support Forum

English Support => General Support => Topic started by: mitchellj on August 05, 2013, 01:36:00 PM

Title: Creating DCI on joining auto filtered container
Post by: mitchellj on August 05, 2013, 01:36:00 PM
Hiya,

I am hoping someone can point me in the right direction. What I'm trying to do is

When a new node gets added to the netxms server, if the node is an agent and is linux then automatically join it to a container called "Linux Servers".  <-- I can do this part easy enough
Once a node has joined the Linux Servers container then automatically create a DCI (if it doesn't exist) on another Node (MonitoringServer) which performs a PortCheck on SSH

I'm struggling with this second part, mainly finding someone to hook the "has joined" script onto, is this even possible? What I'm trying to accomplish is when a new node is added (of type linux) to the server I start monitoring its SSH port to make sure SSH is up and running.

Thanks!
mitch
Title: Re: Creating DCI on joining auto filtered container
Post by: Victor Kirhenshtein on August 05, 2013, 08:04:29 PM
Hi!

I see two possible solutions here:

1. Create DCI for SSH monitoring on Linux server node, not on the monitoring node. You can use autobinding template for that. Because actual check should be done from management server, you can set "proxy node" for this DCI in template to be management server node. Then you'll have obe DCI per LInux node with actual data being collected from management server.

2. You can use configuration poll hook script to detect Linux nodes and then use FindDCIByName and CreateDCI functions to create DCI on management server if it doesn't exist.

Best regards,
Victor
Title: Re: Creating DCI on joining auto filtered container
Post by: mitchellj on August 07, 2013, 07:18:39 PM
Thanks for the response.

I've switched to using the proxy method since I think it does what I was trying to accomplish without a fuller understanding of how it worked :P

I have now ran into another problem though :| Whenever I switch on proxy mode in the DCI I get a "UNSUPPORTED" message.  I have enabled proxy support on the node I am using as a proxy in the agentd.conf file and restarted the node (127.0.0.1).

Any pointers you can give would be much apprechiated.

Thanks!
mitch
Title: Re: Creating DCI on joining auto filtered container
Post by: Victor Kirhenshtein on August 14, 2013, 01:22:30 PM
Hi!

You have to add node where you create proxied DCI to proxy node's "trusted nodes" list, or turn off trusted nodes checking by setting server configuration variable CheckTrustedNodes to 0. A bit more detailed explanation of trusted nodes concept is here: http://wiki.netxms.org/wiki/SG:Security_Issues (http://wiki.netxms.org/wiki/SG:Security_Issues).

Best regards,
Victor