• English日本語한국어
  • Log inStart now

No data appears (Java)

Problem

After generating traffic for your app and waiting a few minutes for data to appear in the New Relic UI, your Java app isn't reporting data.

Solution

After sending a request to your web application, data should appear in the APM UI within two to three minutes. If no data appears after a few minutes:

  1. Restart your web server.

  2. Use New Relic Diagnostics to try to automatically identify the issue.

  3. Verify the newrelic.jar file has been installed correctly and that the -javaagent argument has been passed correctly into the JVM:

    1. Start your web server if it isn't already running.

    2. In your terminal or console, run the appropriate command:

      Linux or macOS:

      ps -ef | grep java

      Windows:

      wmic process where "name='java.exe'" get ProcessID, Commandline /format:list
    3. Find the process for the service you're trying to monitor and see if the -javaagent argument is present:

      • If you see a -javaagent argument: The issue is either in agent startup, or the agent is unable to communicate through your firewall to our collector's IP range.
      • If you don't see a -javaagent argument: The argument wasn't passsed to your JVM. Check your startup scripts or other resources to ensure there's nothing preventing it from being passed. For more info about how to pass the argument for your environment, see Include the Java agent with a JVM argument.
    4. If neither solution works, keep reading.

  4. Verify that your newrelic.jar and newrelic.yml files are in the same directory. If you have specified a non-default location for the config file using the newrelic.config.file system property, ensure that the config file does exist in that location and is correctly formatted.

  5. Generate finest level logs, and check the logs for errors. In the event no log file can be found, see No log file (Java).

  6. Check the application server logs for errors related to the New Relic Java agent. You can see the troubleshooting pages Error bootstrapping Java agent and Errors starting Java app server for examples of observable errors in application server logs that prevent the java agent data from reporting.

  7. Verify that your app is reporting to the expected name: In your New Relic log files, search for "reporting to", then select the link in the message. For example:

    {"message":"Reporting to: https://rpm.newrelic.com/accounts/000/applications/000000"}

    If you are reporting to multiple application names, look for multiple lines with this message.

  8. If the message link does not go to the expected application, ensure that your app name settings are the same in both newrelic.yml and in the web.xml display-name setting.

Copyright © 2024 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.