• Forums
    • Public Forums
      • Community Connect
      • Dynatrace
        • Dynatrace Open Q&A
      • Application Monitoring & UEM
        • AppMon & UEM Open Q&A
      • Network Application Monitoring
        • NAM Open Q&A
  • Home /
  • Public Forums /
  • Application Monitoring & UEM /
  • AppMon & UEM Open Q&A /
avatar image
Question by Douglas V. · Jan 15, 2015 at 05:49 AM ·

PHP files being called by Shell Script

Hello guys, first of all sorry for the bad english (and bad title).

I have an PHP application here who have some PHP files being called by Shell Scripts, but when I search in the PurePaths tab I cant find the PHP request on the PurePaths list. I believe this happens because the shell calls the PHP file at the local machine and it is not considered a Web Request (???).

The question is, there's a way to monitor these PHP called by Shell Scripts?

thank you and sorry for the bad english (no google translator this time (smile)).

Comment

People who like this

0 Show 0
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

13 Replies

  • Sort: 
  • Most voted
  • Newest
  • Oldest
avatar image

Answer by Douglas V. · Jan 30, 2015 at 11:49 PM

Yes, we load a lot of scripts in parallel. Then I believe this behavior is expected then...

Well... thank you for the responses!

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Harald Z. · Jan 30, 2015 at 11:17 PM

as the agent is loaded as an extension into PHP, a new instance of the agent is registered with each PHP process. In detail: when you load PHP into Apache or start as a FastCGI module (PHP-FPM), 1 agent is loaded for that process, even though it could execute multiple PHP scripts. On the other side, when you run PHP in CGI or from command line, a new PHP process is started for each script execution, and therefore loads a new agent. After the execution is finished, there is a timeout (10 seconds) before the agent will disappear in the overview. During that timeout you would see multiple agents when a new script is started.

Do you run multiple PHP scripts in parallel?

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Douglas V. · Jan 30, 2015 at 10:31 PM

Well...

Looking better... the number of agents changes after each update sometimes is 4, updates to 6, then 5, then 10. It just changes all time.

The question is....

Can I use only 1 agent to collect all the data? or will it keep opening and closing new agents?

(sorry for the bad english).

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Harald Z. · Jan 30, 2015 at 03:47 AM

looks strange...

is each of these agents started by an execution of your PHP script in the cron, I mean one after the other, while existing ones are never removed from the list? 

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Douglas V. · Jan 30, 2015 at 03:38 AM

Well

I opened the agent overview as you suggested and I didn't find anything like a PID there...

there's a screenshot.

 

Anything that I'm missing?

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Harald Z. · Jan 30, 2015 at 02:17 AM

when you can see 6 PHP agents in the agent overview, do you have a PHP process running for each of these agents?

the agent's name in the overview contains the PID of the unix process running your PHP. are these ID's still active processes?

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Douglas V. · Jan 30, 2015 at 01:11 AM

Anyone know something about the question above?

thank you.

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Douglas V. · Jan 16, 2015 at 03:06 AM

Oh, sorry, I didn't pay attention to the last line hahaha, Thank you it worked!

But now my application are using at least SIX agents. Have any way to solve this? or it'll use an agent to each new process? (sorry for the bad english!)

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Harald Z. · Jan 16, 2015 at 01:33 AM

are you saying that you already have defined dtphpagent.useAgentForCmdLine = true in your php.ini ?

Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

avatar image

Answer by Douglas V. · Jan 16, 2015 at 12:15 AM

Harald, thanks for the help but I already have the PHP agent up and running.

I'll make an example to make it better. (bad english and mispelling incoming).

  1. I have a routine scheduled in cron, who loads routine.sh every 10 minutes
  2. routine.sh loads checklist.php
  3. I cant see the request checklist.php on my purepaths tab... WHY? There's a way to enable it?
Comment

People who like this

0 Show 0 · Share
10 |2000000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Toggle Comment visibility. Current Visibility: Viewable by all users

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

  • 1
  • 2
  • ›

How to get started

First steps in the forum
Read Community User Guide
Best practices of using forum

NAM 2019 SP5 is available


Check the RHEL support added in the latest NAM service pack.

Learn more

LIVE WEBINAR

"Performance Clinic - Monitoring as a Self Service with Dynatrace"


JANUARY 15, 3:00 PM GMT / 10:00 AM ET

Register here

Follow this Question

Answers Answers and Comments

1 Person is following this question.

avatar image

Forum Tags

dotnet mobile monitoring load iis 6.5 kubernetes mainframe rest api dashboard framework 7.0 appmon 7 health monitoring adk log monitoring services auto-detection uem webserver test automation license web performance monitoring ios nam probe collector migration mq web services knowledge sharing reports window java hybris javascript appmon sensors good to know extensions search 6.3+ server documentation easytravel web dashboard kibana system profile purelytics docker splunk 6.1 process groups account 7.2 rest dynatrace saas spa guardian appmon administration production user actions postgresql upgrade oneagent measures security Dynatrace Managed transactionflow technologies diagnostics user session monitoring unique users continuous delivery sharing configuration alerting NGINX splitting business transaction client 6.3 installation database scheduler apache mobileapp RUM php dashlet azure purepath agent 7.1 appmonsaas messagebroker nodejs 6.2 android sensor performance warehouse
  • Forums
  • Public Forums
    • Community Connect
    • Dynatrace
      • Dynatrace Open Q&A
    • Application Monitoring & UEM
      • AppMon & UEM Open Q&A
    • Network Application Monitoring
      • NAM Open Q&A