cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

This product reached the end of support date on March 31, 2021.

AppMon Agent is not connecting

nrandhawa
Participant

Hi.

I have a java application that I am trying to connect to with AppMon. I have followed all the steps mentioned here:

https://community.dynatrace.com/community/pages/vi...

When I try to add the application server, and after adding the jvm options for agent, it keeps on waiting for it to connect but can't. The server and app are on the same machine and I'm only selecting Java as my Application Server. Everything is running, port 9998 is also open. Is there an obvious thing I'm missing? Any help would be appreciated.

Thanks.

33 REPLIES 33

arihant_polavar
Dynatrace Pro
Dynatrace Pro

Hello,

Can you attach the agent logs that might have been generated during this installed? They should in the /agent directory under /logs

That should hopefully help us figure out what the issue might be.

Thanks,

Ari

To add to this. Can you paste the -agentpath command line option that you are using?

Babar_Qayyum
DynaMight Leader
DynaMight Leader

Hello NoorUllah,

As already asked by @Ari P. For the agent logs, to understand the causes.
Simply make sure that you already created the name of agent to map and weather application is 32bit or 64bit.

Also any network latency due to firewall in between agent and collector, if exists.

Regards,

Babar

nrandhawa
Participant

dt-host-103370.log dt-host-bootstrap-103370.log

@Babar Q. @Ari P. @Andreas G.

Following are the log files, why there are two log files? I've added the following vm option:

-agentpath:/media/nrandhawa/Downloads/dynatrace_agent/agent/lib64/libdtagent.so=name=JavaApplication_Monitoring,server=nrandhawa:9998

I don't see anything unusual in the log files. Do we have to start the agent manually somehwre, or where is the agent started?

Looking at the log files, this one line stands out:-

2016-12-15 12:07:19 [e1e5e868] info    [native] License = license exhausted; too many agents connected; 

Are you using a personal license? How many agents do you already have connected with your license?

I'm running a free trial. And I only activated it once. Any way to check?

How long you activated the license?

You can go to License Overview and see how many agents you are licensed for. I suspect you have used all of your available licenses.

If that is the case, you will need to disable one of the agents you have successfully connected (just commenting out the agentpath in the startup script should work) and try this again.

I don't see that option in the dynatrace client. The eservices webpage shows no licenses at all.

screenshot-from-2016-12-15-143638.png

Hello,

Open the server settings from the client and click on the license.

Regards,

Babar

you can also open the Agent OVerview DAshlet and send us a screenshot from that. I assume you simply connected too many agents at once - therefore exceeding the limit of available licenses that are part of the free trial

No agents are currently configured.

Exactly. According to logs, it is related to license, if all above correct.

nrandhawa
Participant

My question is, how is the dynatrace agent created. Is it created when we give restart the application?
Because the above log files were created when I ran the init script I belive. When I restart the app, I see no new log files that are created which means there is no agent that the client can connect to, right?

An agent gets connected if you start an application that loads our agent, e.g: if you start a JVM that has the -agentpath command line parameter it means that the agent gets loaded and it will connect to the dynatrace server

When you launch your application - are you just launching a single JVM? Or do you launch several JVMs? MAybe more than 5 which is the maximum limit?

Andi

There is only one jvm and I have given the agent path option in the IDE however, the agent does not get started since I cannot see any log files. The application starts successfully however.

dave_mauney
Dynatrace Champion
Dynatrace Champion

Did you by chance run the host agent init.d script? If you are instrumenting java, there is nothing to start other than the java application/app server. Simply adding the agentpath vm argument and restarting the affected process is all you need to do. The host agent is another matter, and I don't think you need it. I base this on your log file names (dt-host appears in the names). As to why there are two logs, one is the bootstrapper and the other one is the "real" log.

HTH,

dave

I did, by mistake, and you are right those log files are from the one i manually started. The agent is not starting when I start my application even though I have given the jvm options.

Hello NoorUllah,

I will suggest you to see the below performance clinic specifically designed for evaluating Dynatrace for Java Applications.

Here you will see all the step-by-step process to install and configure the agent and more...

https://www.youtube.com/watch?v=dDJTQqri8vU&list=P...

Regards,

Babar

dave_mauney
Dynatrace Champion
Dynatrace Champion

Can you see the agentpath when you use "ps -ef | grep java" or similar command to see the actual command line? Does the user the java process runs under have rights to read the agent and write to the logs directory?

nrandhawa
Participant

Yes the agent path is being used in the command and the user has all the permissions.

However, this was just a test application, when I try to make it work on HDFS which is running on a remote machine, it does try to start the agent however it cannot connect to the connector/server.

Gives me this:

2016-12-16 18:18:10 [54775873] info [native] Trying to connect to Server/Collector for up to 0 seconds 2016-12-16 18:18:20 [54775873] info [native] Could not retrieve LoadBalancing configuration from 10.129.2.100:9998 (70007): The timeout specified has expired 2016-12-16 18:18:30 [54775873] severe [native] Exception while connecting to Server/Collector 10.129.2.100, info:<connect()/apr_socket_connect(), 70007, Connection timed out> 2016-12-16 18:18:30 [54775873] warning [native] Unable to register with Server/Collector 10.129.2.100:9998, CONTINUING WITHOUT INSTRUMENTATION.

Firewall is not blocking anything and I tried increasing the wait and socket timeout but nothing worked.

Babar_Qayyum
DynaMight Leader
DynaMight Leader

Hello NoorUllah,

In the logs "Couldnot retrieve LoadBalancing configuration from 10.129.2.100:9998(70007)"

Is this IP Address of your server/collector?

Regards,

Babar

nrandhawa
Participant

Yes that is where the server/collector is running and the port is listening and I can ping/nmap to the above address and port.

Hey Noor. Pls send me an email. IF you are still up I send you a quick webex invite

you should have my email if you registered for the free trial. simply reply to the emails you received as part of the trial sign up

rrawat
Guide

Hi Andreas,

I have also facing the same issue could you pleaase help me out .But in my case it is dot net agent.

Hi Rishab:

Are there have dotnet agent logs?Have you try to login dotnet portal after restart the dotnet service?

Guangzhi

Steps what i did ---

1.Installed DYnatrace full msi and activated the license.

2.Then i want to configure system profile.I started by configure webser tier in our case IIS 7.5 .

Then i followed all those steps but agents did not connect .

we have 2 webserver remote with multiple application which need to be monitor.So i restarted the webserver agent in both server.Also i tried to close the webserver agent in DYnatrace server .But that also not worked.

IS their any thing i missing.

Are you using the Dynatrace AppMon Trial? In that case - feel free to respond to the trial emails you receive. we can than also take this via the official free trial email support chain and can update this community page with our solution

Hi Andreas,

We were using Dynatrace 6.2 in via-west and now we have installed Dynatrace version 6.5 in cloud (Armor). So we asked license team to provide temp license for 1 month so we can verfiy our configuration and then permanetly go for that.

We have installed dynatrace(full msi pakage)and activated the license but the webserver are in remote machine 2 web server having mutiple application which need to track..

Facing issue while configuration.Web server agent.

Hi Andi,

FYI I was communicating with Rishab in this post: https://answers.dynatrace.com/questions/178543/dynatracae-installation.html

rrawat
Guide

Guangzhi can i have our mail id

Email to me?