Reputation: 1941
I'm trying to follow the official steps from Newrelic to install the Newrelic PHP Agent, but I couldn't get any data statistics.
I have added manually extension=newrelic.so to /opt/lampp/etc/php.ini , but also not working
I recognized that XAMPP has no extension directory but a directory called "opt/lampp/modules"
So newrelic doesn't push the installed extension inside it, what to do so ?!
Upvotes: 0
Views: 800
Reputation: 54
Are you installing it on a Mac or a Linux box?
What Distro?
Xampp is just a packaged install of key server components and New Relic only integrates with PHP. So if your Linux OS is Debian or Red-Hat based you can do it through the general instructions. If it's Mac OS it's a little bit more unusual but can be done.
As install instructions exist for Debian / Red Hat I'll assume this is Mac OSX as there is no Windows Agent.
Download the latest Mac OS X agent http://download.newrelic.com/php_agent/release/
Extract this package in a unique location where you want to store the New Relic files. In Terminal, CD into that directory. Run sudo NR_INSTALL_PATH=/Applications/MAMP/bin/php/phpX.X.X/bin ./newrelic-install
When prompted where to install, type "all" without quotes.
Open "/Applications/MAMP/bin/php/phpX.X.X/conf/php.ini" (remember, replace X.X.X with the version you found above) in your text editor of choice, then copy and paste the following into it. Make sure to replace the license key placeholder with your license key.
extension=newrelic.so
newrelic.appname = <appName>
newrelic.license = <licenseKey>
Changing AppName to the name you want your Application to be called and LicenseKey to your accounts LicenseKey.
Restart MAMP.
If you create a PHPinfo file you will be able to check that New Relic is a loaded module on it.
In some rare cases, if the daemon doesn't start with the restart of MAMP you can start it manually /usr/bin/newrelic-daemon
Upvotes: 3