Addressing Multiple Application Instances creation with Different Ports in APM Insight PHP Agent

Addressing Multiple Application Instances creation with Different Ports in APM Insight PHP Agent

Issue: After installing the APM Insight PHP Agent, multiple application instances appear with different port numbers for the same application, which is expected to run only on port 80/443.

Issue Cause:
As per the PHP agent’s auto-discovery behavior, all application runtime ports are detected by design, resulting in monitor instances such as:
  1. apphost:0 (PHP-Application): Instance created to show background application activity.
  2. apphost:80 (PHP-Application):  Instance created to show web activity accessed via port 80.
  3. apphost:443 (PHP-Application): Instance created to show web activity accessed via port 443
Solution:  To monitor only a specific port (e.g., 443) and exclude others, follow these steps:
1. Confirm the primary port used for web traffic.
2. Exclude unnecessary ports by executing the following command from the agent installation path:
Quote
sh /opt/zpa/bin/agent_php.sh configure -zpa.exclude_ports "<app_port_which_not_required>"
For Example, To exclude port 80, execute the below cmd: 
Quote
sh /opt/zpa/bin/agent_php.sh configure -zpa.exclude_ports "80"

3. Restart the application to apply the changes.

4. Delete the excluded instances from the Applications Manager portal.

Note: Excluding ports prevents data collection for those instances. Ensure the correct port is monitored before making changes.

If any concerns, kindly contact appmanager-support@manageengine.com for further assistance.

                  New to ADSelfService Plus?

                    • Related Articles

                    • Addressing Multiple Instances in a Single APM Insight Application - "PHP-Application"

                      Issue Overview: By default, the PHP Agent configures the application name as "PHP-Application" in APM Insight. This default setting causes multiple PHP applications to be discovered under the same APM Insight Application, leading to data usage limit ...
                    • How to install the APM Insight PHP Agent in an Azure Web App?

                      Follow these steps to install and configure the APM Insight PHP Agent in an Azure Web App. Step 1: Create a deployment script Navigate to the directory /home/apm/ (create it if it doesn’t exist). Create a new shell script named apm-phpagent-deploy.sh ...
                    • How to rename an existing APM - Java agent application's monitor?

                      In Applications Manager's APM(Application Performance Monitoring) doesn't support renaming applications/monitors from the web client. However, the application name of an existing application instance can be renamed in the `apminsight.conf` file and ...
                    • Uninstrumented Block of Code - APM Insight

                      In the traces tab --> Slowest Method Calls and Count we show if you find Un-instrumented block of code the reason is as follows: Basically, What is un-instrumented block of code in APM Insight? By default, APM Insight agent monitors known frameworks ...
                    • APM Insight Troubleshooting - FAQs

                      Monitor Addition - FAQs 1. How to add an APM Insight Monitor? After you deploy the APM Insight agent in your Application Server with suitable Applications Manager credentials in the apminsight.conf file, APM Insight monitors will automatically be ...