Xavier
Xavier

Reputation: 133

What environment should PCNTL be used in?

The PHP manual states:

Process Control should not be enabled within a web server environment and unexpected results may happen if any Process Control functions are used within a web server environment.

However, the manual does not state what environment PCNTL should be used in. I am new to PCNTL and want to know what environments PCNTL scripts are run on. I wanted to use PCNTL for the purpose of writing a daemon script that runs on my server but, I feel confused about PCNTL intention, as I see many articles using PCNTL to write daemon scripts.

I looked for an article or question explaining what environments PCNTL is run on but, maybe I'm misunderstanding something fundamental about it's intended use?

Upvotes: -2

Views: 150

Answers (1)

Xavier
Xavier

Reputation: 133

As it turns out, PCNTL is used on servers such as mail servers, database servers, file servers, and others. It had never occurred to me that servers are not just used for the web and that PHP can be used outside of a web environment. These types of servers are new to me hence why I was so confused on the matter.

Upvotes: -1

Related Questions