Unable to connect using external parameter on windows netxms agent 1.0.4

Started by Dan, January 10, 2011, 11:56:40 AM

Previous topic - Next topic

Dan

Hello!

I have a server running Windows 2008 R2.
I have installed the netxms agent, we are currently running version 1.0.4, and is able to connect, it is stated as "Active" under the nodes "Overview".

In the netxms configuration file I have created a number of external parameters which all runs as they should from the command line, but when I try to connect and run it through NetXMS I receive the following error message: "Cannot get parameter: Communication failure".

If I look in the event viewer on the windows machine I can see that there are a number of errors related to the agent containing this error message:
"Unable to create temporary file to hold process output: The system cannot find the path specified"

I have other windows servers running with the same configuration and they are running fine.
Where is it trying to create the temporary file?
Could it be a file system access problem?

Thanks for your help!

Victor Kirhenshtein

Hi!

Agent uses Windows API call GetTempPath to obtain directory for temporary files. It works as following (quote from MSDN):

The GetTempPath function checks for the existence of environment variables in the following order and uses the first path found:

   1. The path specified by the TMP environment variable.
   2. The path specified by the TEMP environment variable.
   3. The path specified by the USERPROFILE environment variable.
   4. The Windows directory.

Note that the function does not verify that the path exists, nor does it test to see if the current process has any kind of access rights to the path.

Could you please check values of mentioned environment variables and access rights for appropriate directories? Also, do you run agent under local system account?

Best regards,
Victor

Dan

Hi,
Thanks!

I'll check the values of the environment variables and get back asap!

The agent is running under the local system account, it's just a default install, is there anything special to consider?

Best regards,
Dan

Dan

The variables are set, both TMP and TEMP (and the others), I also checked the user rights and they were set as they should I guess, everything checked on "allow" and nothing on "deny".
The hard drive is not full. I have tried to stop and start the agent again.

The strange thing is that it is only on this server.
Do you have any other ideas what could be wrong?
I could suggest a reboot of the server, but not sure if that would help?

Thanks again!

Best regards,
Dan

Dan

Just made sure and it is only my own specified parameters through "ExternalParameter" in the netxms agent configuration file that is now working, everything else seems to be running fine, which is a bit disturbing :)
When I try to run the parameter I have specified manually it works like a charm, but not through the agent.

If it were any problems running the parameter there should be another error in the event log, or am I wrong?

Edit: I found another error message as well, this time on NetXMS, "Unable to open buffer file" in the "last values" history for the node when I clicked on it through the alarm browser.

Best regards,
Dan

Victor Kirhenshtein

As you are running Windows 2008 R2, it is 64 bit. Are you running 1.0.4 agent? If yes, it is 32 bit, and it may cause some problem (although it shouldn't). In this case, could you please try to replace agent with x64 version (it will be agent version 1.1.0, but it is compatible with 1.0.x servers).

Best regards,
Victor

Dan

Sorry, it is 32 bits, it is apparently not R2, it has Service Pack 2 though!
From description:
"Windows SCHED 6.0.6002 Windows Server 2008 Build 6002 Service Pack 2 Intel IA-32"

Yes it is the 1.0.4 agent, 32-bits.

The server has also been restarted now, just to ensure that it is nothing trivial like that, but it displays the same errors, so I changed the user who runs the nxagent to the administrator, and now it works :)
Not optimal, but something is not as it should with the local system account :)

I think I will let some windows admin look at it.
Thanks for your help!

Best regards,
Dan