Resolve New Relic agent issues with PHP 8.2 to 8.3 upgrade in Adobe Commerce
When you upgrade PHP from version 8.2 to 8.3, you might notice that the New Relic agent stops working in your Adobe Commerce environment. This issue has been observed in staging and production environments. In this article, you’ll find steps to troubleshoot and resolve this issue, including how to submit a support case to fix the New Relic agent, ensuring your New Relic agent continues to function. You can usually self-manage the PHP version upgrade, but when this issue occurs, you must submit a support ticket.
Description description
Environment
Adobe Commerce (any versions upgrading to PHP 8.3)
Issue/Symptom(s)
The New Relic agent stops working after you upgrade from PHP 8.2 to 8.3.
Steps to reproduce:
To confirm that this issue relates to the PHP upgrade, take the following error identification steps:
-
Log in to the Commerce New Relic account.
-
Select Logs on the left navigation bar.
-
Select the time window from the time selection dropdown.
-
In the search box:
- For a staging environment enter: “PHP Warning” ADBE_Environment:“dev”.
- For a production environment enter: "PHP Warning" ADBE_Environment:“production”.
- Press enter or select Query logs.
-
In the log result table, look for messages containing the below:
PHP Warning: PHP Startup: Unable to load dynamic library 'newrelic.so' (tried: /usr/lib/php/XXXXXXXX/newrelic.so (/usr/lib/php/XXXXXXXX/newrelic.so: cannot open shared object file: No such file or directory), /usr/lib/php/XXXXXXXX/newrelic.so.so (/usr/lib/php/XXXXXXXX/newrelic.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Cause
The New Relic agent stops working after the PHP upgrade due to incompatibility with PHP 8.3.
Resolution resolution
To resolve this issue, you need to submit a support case to reinstall or fix the New Relic agent and have assistance from the platform team.