Engine Yard is a Platform as a Service (PaaS) management solution capable of hosting web applications. Language support includes PHP and Ruby.
A New Relic application is equivalent to an Engine Yard Cloud environment. The New Relic add-on can help you understand if your app or your server needs help by providing real-time application performance.
Create New Relic account
To create a New Relic account, use your Engine Yard account and password.
- For new accounts, use the New Relic add-on.
- If you previously set up New Relic with the original integration, do not use the add-on with the same account. To convert from the original integration to the add-on, contact Engine Yard Support.
Before installing New Relic, consider which applications and environments need monitoring, and which plan is right for you. In addition, you must meet the following conditions:
- You must have a full Engine Yard account, not a trial account.
- Your enviroment must be no older than the November 13th, 2012 release. It if is, you will have to upgrade it.
- Make sure your application is ready for deployment.
Sign up for New Relic
- Log in to your Engine Yard account.
- Navigate to the New Relic add-ons page at cloud.engineyard.com/addons/newrelic. Review the add-on Details to learn more about the New Relic service.
- Select Set it up.
- To accept the Terms and Conditions, select Sign Up.
This sets up your New Relic login and password with SSO (providing the same sign-on as Engine Yard Cloud).
Activate apps for New Relic monitoring
If you have multiple apps (environments), then the Set it up page's Activation dropdown will list multiple selections. Otherwise there will only be one.
For each app (environment) you want to activate:
- From the New Relic Set it up > Activation dropdown, select the Engine Yard environment you want to extend with New Relic monitoring.
- Select Activate.
After you select Activate for the selected app/environment, a message will appear to confirm that New Relic is activated on the environment.
Update your config file
For each app (environment) you activated, repeat these steps to update your code so the New Relic add-on service will be available.
Modify your Gemfile by adding the following lines:
gem 'newrelic_rpm' gem 'ey_config'
- Download the Engine Yard version of newrelic.yml.
- Place the
newrelic.ymlfile in the
configsubdirectory of your application.
- Push all changes to your GitHub repository host.
Deploy your apps
After you update your config file for each app (environment), deploy the code changes to your Gemfile and config/newrelic.yml in the New Relic add-on service.
- Select the environment link to go to your application environment in Engine Yard Cloud.
- On the environment page, select Deploy.
- To ensure that you have the November 13th, 2012 or higher Engine Yard stack update (which includes database server monitoring), select Upgrade.
This installs the required New Relic functionality.
Verify your New Relic configuration
After you configure and update your app (environment) with the New Relic add-on, verify the setup.
- Sign in to your Engine Yard account.
- Navigate to the New Relic add-ons page at cloud.engineyard.com/addons/newrelic.
- To view the New Relic interface, select the New Relic Dashboard link.
If you see a Searching for app data error message, your app/environment may not have deployed yet. For more information, follow the Engine Yard troubleshooting procedures.
Here are some troubleshooting tips for Engine Yard users, including problems with installing, testing, and monitoring your app.
- User interface problems
Problem: When I view the New Relic UI, it looks like it is not set up yet. The Gemfile was modified and we set up
Solution: You must select Deploy to update the configuration for each environment that you are extending with New Relic.
Problem: Different license keys for
Solution: New Relic strongly recommends against using the original New Relic integration (from (selected account) > Account settings) along with the new add-on, as this issue results. You also will have double billing, and the new account will not reflect historical data. To convert from the original integration to the new add-on, contact Engine Yard Support.
- Server monitor problems
Problem: Server monitoring is not working.
Solution: You need a Chef run to install the New Relic daemon that monitors server resources. Select Upgrade on each environment that you are extending with New Relic. (Fixed in July 24, 2012 stack upgrade.)
- Testing problems
Problem: When running in Development mode, this error appears:
Error reading newrelic.yml file: Expected to find EY::Config YAML file at one of: ["config/ey_services_config_deploy.yml", "config/ey_services_config_local.yml"] (RuntimeError)
Solution: New Relic does not require a valid license key in Development mode. The easiest thing to do is create this file:
config/ey_services_config_local.yml 'New Relic': license_key: "NA"
When you deploy, this file remains. However, a
config/ey_services_config_deploy.ymlfile also is written. It contains your real license key and takes precedence.