• /
  • EnglishEspañol日本語한국어Português
  • Log inStart now

The agent is not starting and there are no logs

Problem

The infrastructure agent is not starting, and logs are not created.

Solution

Here are some troubleshooting options for non-root users if the infrastructure agent is not starting and there are no logs:

Check requiretty

To see if requiretty is causing logging issues:

  1. In /var/log/messages or /var/log/syslog, look for the message sudo: sorry, you must have a tty to run sudo .

  2. If you find this message, edit your /etc/sudoers file with the visudo command and comment or remove the following line: Defaults requiretty

  3. Save and exit the file.

  4. Restart the newrelic-infra service.

Review log permissions

Check the agent's permission to open log_file. It's possible that the log file you are using was created when the agent was running as root, and now the nri-agent user does not have permissions to write it.

To solve this, try one of these options:

  • Change the owner of the log file.

  • Change the log_file entry in the /etc/newrelic-infra.yml configuration file. Our installation scripts create the /var/log/newrelic-infra/ folder for that purpose, so we recommend the following value:

    log_file: /var/log/newrelic-infra/newrelic-infra.log
Copyright © 2024 New Relic Inc.

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