monitoring space on remote HDD over SSH
-
-
Absolutely, please check NetXMS docs on that: https://www.netxms.org/documentation/adminguide/ssh-monitoring.html
Make sure you add ssh.nsm subagent to the configuratio file of netxms agent running on your netxms server and restart the agent afterwards. -
OK...
- On the NetXMS server I found /etc/nxagentd.conf and added new line SubAgent=ssh.nsm, then restarted the agent.
- On the server node I opened 'Data Collection Configuration' and there created new parameter.
Parameter: SSH.Command(192.168.10.1,admin,mypass,ls)
Origin: NetXMS Agent Data Type: String
Source Node: myserver
Then I go into Object Details of the Node(myserver) and tab 'Last Values'.
Here I see the my parameter, but value is <<ERROR>> , Timestamp is empty.thank You for any hint
-
You do not need source node if you have configured it on NetXMS server node. It defines where actual data collection will happen, in case of "agent" origin - what agent will be queried. You'll need source node to be set in the opposite case - when you configure DCI on "myserver" node but SSH subagent is on NetXMS server - then you'll have to set source node to NetXMS server node.
Best regards,
Victor -
-
The could be an issue that first SSH.Command since agent start is failing (https://track.radensolutions.com/issue/NX-1852), but is should start working when polled again.
-
for sure I restarted the agnetd a checked his status:
~# systemctl status nxagentd ● nxagentd.service - NetXMS Agent Loaded: loaded (/lib/systemd/system/nxagentd.service; disabled; vendor preset Active: active (running) since Fri 2020-05-08 13:25:58 CEST; 7min ago Process: 1658 ExecStart=/usr/bin/nxagentd -d (code=exited, status=0/SUCCESS) Main PID: 1659 (nxagentd) Tasks: 19 (limit: 3480) Memory: 13.9M CGroup: /system.slice/nxagentd.service └─1659 /usr/bin/nxagentd -d May 08 13:25:55 info21-srv-monitor systemd[1]: Starting NetXMS Agent... May 08 13:25:55 info21-srv-monitor systemd[1]: nxagentd.service: Can't open PID May 08 13:25:58 info21-srv-monitor systemd[1]: Started NetXMS Agent.Configuration Poll (Full)
08.05.2020 13:26:12] **** Poll request sent to server **** [08.05.2020 13:26:25] Checking EtherNet/IP... [08.05.2020 13:26:25] Cannot get device identity via EtherNet/IP (CONNECT FAILED) [08.05.2020 13:26:25] Capability check finished [08.05.2020 13:26:25] Checking interface configuration... [08.05.2020 13:26:25] Interface configuration check finished [08.05.2020 13:26:25] Checking node name [08.05.2020 13:26:25] Node name is OK [08.05.2020 13:26:25] Updating general system hardware information [08.05.2020 13:26:25] Finished configuration poll for node info21-srv-monitor [08.05.2020 13:26:25] Node configuration was not changed after poll [08.05.2020 13:26:25] **** Poll completed successfully ****but it doesn´t seems to be, that it helped

-
Ok, can set DebugLevel=7 in agent configuration file and show an extract from agent log file when the SSH command is executed.
Also, you can use nxget command - it requests data from the agent, e.g.:
nxget 127.0.0.1 "SSH.Command(host,user,password,ls)" -
ok ...
- I have added the log level
- Then I restarted the agent
- Then I restarted the pool on the server
- Jumped into the log a here it is:
2020.05.08 14:34:30.615 *D* [ ] Event sender thread started 2020.05.08 14:34:31.616 *I* [ ] NetXMS Agent started 2020.05.08 14:35:23.876 *D* [ ] Incoming connection from 10.6.6.17 2020.05.08 14:35:23.876 *D* [ ] Connection from 10.6.6.17 rejected 2020.05.08 14:35:30.615 *D* [dc ] DataCollector: sleeping for 60 seconds10.6.6.17 is the NetXMS server self
so I again opened the nxagentd.conf and I have put there:MasterServers=127.0.0.0/8,10.6.6.17
before was just:
MasterServers=127.0.0.0/8and problem is SOLVED! super Thank You :_)
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login