Newrelic Installation, Deinstallation and Errors
Newrelic is a monitoring service (website: newrelic.com), which is supposed to watch after the health of your server/website.
Installation was quite simple. Few CLI commands, which they provide to you upon server registration and you are done:
wget -O - https://download.newrelic.com/548C16BF.gpg | sudo apt-key add - sudo sh -c 'echo "deb http://apt.newrelic.com/debian/ newrelic non-free" > /etc/apt/sources.list.d/newrelic.list' sudo apt-get update sudo apt-get install newrelic-php5 sudo sh -c 'echo "deb http://apt.newrelic.com/debian/ newrelic non-free" > /etc/apt/sources.list.d/newrelic.list' echo 'deb http://apt.newrelic.com/debian/ newrelic non-free' | sudo tee /etc/apt/sources.list.d/newrelic.list sudo apt-get update sudo apt-get install newrelic-php5 reboot
Yeah, yeah. It requires a server renoot.
First and Last Impressions of Newrelic
First impression was that it is not very helpful. The monitoring information left lots to be desired. I was looking for some development information like slow database queries or similar, which never was shown. Nevertheless, I was inclined to leave for a few days.
A few minutes later I noticed my webpages load a lot slower than normal. After inspecting the webpages closer it turned out, that each time you load your webpage a request is made to the Newrelic servers to send a report. This was unexpected, as I never saw this mentioned on their website.
These requests seem to be noteceably slow. Though the page is fully rendered the browser status is still showing the loading icon, as the NewRelicl is being sent. From user perspective, this is annoying.
Of course, NewRelic was a BIG NO NO, so I proceeded with deinstallation.
Deinstallation of Newrelic
Deinstallation was kind of more obscure to find, but some minutes later, with the help of serach engines, I found the NewRelic deinstallation pages.
Few CLI commands and NewRelic was a goner.
sudo apt-get uninstall newrelic-php5 sudo apt-get remove newrelic-php5 sudo apt-get autoremove
Or so I thought.
A bit later, I run a CLI comand involving php. My php came back with the following response:
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20121212/newrelic.so' - /usr/lib/php5/20121212/newrelic.so: cannot open shared object file: No such file or directory in Unknown on line 0
Seraching for the error on the Internet did not come with a solution out of the box. So I had to investigate, and found out that Newrelic had created a separate config file in the cli directory of my PHP installation. After deleteing my PHP was happily singing again
cd /etc/php5/cli/conf.d/ ls rm 20-newrelic.ini
Please Do Not Reprint This Article
This article is copyrighted. Please do not reproduce or distribute this article in whole or part, in any form. Links to this article are welcome