This commit is contained in:
as2252258@163.com
2021-03-28 16:28:53 +08:00
parent 722e302484
commit 1ea5086d4e
+3
View File
@@ -81,6 +81,9 @@ class Shutdown extends Component
*/
public function pidIsExists($content): bool
{
if (intval($content) < 1) {
return false;
}
$shell = 'ps -eo pid,cmd,state | grep %d | grep -v grep';
exec(sprintf($shell, $content), $output, $code);
var_dump(sprintf($shell, $content), $output, $code);