Home>Article>Backend Development> How to modify the process name in php

How to modify the process name in php

王林
王林 Original
2021-09-24 16:08:58 2405browse

How to modify the process name in php: [if (function_exists('cli_set_process_title')) {cli_set_process_title("superman php master process");...].

How to modify the process name in php

The operating environment of this article: windows10 system, php 7, thinkpad t480 computer.

How to set the process name in php in cli environment? Let’s take a look.

The specific implementation code is as follows:

if (function_exists('cli_set_process_title')) { cli_set_process_title("superman php master process"); } // Need proctitle when php<=5.5 . elseif (extension_loaded('proctitle') && function_exists('setproctitle')) { setproctitle("superman php master process"); }

Generally it may be used when using php for multi-process processing

How to modify the process name in php

Recommended learning:php training

The above is the detailed content of How to modify the process name in php. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn