手动阀

Good Luck To You!

Linux下查看nginx apache mysql php的编译参数

在Linux系统下,查看Nginx、Apache、MySQL和PHP的编译参数可以通过以下几种方法实现:

Nginx

要查看Nginx的编译参数,可以使用nginx V命令,这个命令会输出Nginx的编译选项和配置信息。

nginx V

输出示例:

nginx version: nginx/1.20.1
built by gcc 9.3.0 (Ubuntu 9.3.017ubuntu1~20.04)
configure arguments: withhttp_ssl_module withpcre=/usr/local/src/pcre8.44 withzlib=/usr/local/src/zlib1.2.11 ...

Apache

要查看Apache(httpd)的编译参数,可以使用httpd V命令,这个命令会输出Apache的编译选项和配置信息。

httpd V

输出示例:

Server version: Apache/2.4.46 (Unix)
Server built:   Apr 15 2021 12:34:56
Server's Module Magic Number: 20140224:64
Server loaded:  APR 1.7.0, APRUTIL 1.7.0
Compiled using: APR 1.7.0, APRUTIL 1.7.0
Architecture:   64bit
Server MPM:     prefork
  threaded:     no
    forked:     yes (variable process count)
...

MySQL

要查看MySQL的编译参数,可以登录到MySQL服务器并运行以下SQL查询:

SHOW VARIABLES LIKE '%compile%';

这将返回与编译相关的变量及其值。

+++
| Variable_name            | Value                 |
+++
| version_compile_machine  | x86_64                |
| version_compile_os       | Linux                 |
| version_source_revision  | 57a8b8e               |
+++

PHP

要查看PHP的编译参数,可以使用php i命令,然后通过grep过滤出相关信息。

php i | grep "Configure Command"

输出示例:

Configure Command =>  './configure' 'prefix=/usr/local/php' 'withconfigfilepath=/usr/local/php/etc' 'enablembstring' 'withmysqli' 'withpdomysql' 'withopenssl' 'withzlib' 'enablebcmath' 'withbz2' 'enablecalendar' 'withcurl' 'withcdb' 'enableexif' 'enableftp' 'enablegdnativettf' 'withfreetypedir=/usr/include/freetype2' 'withjpegdir=/usr/include' 'withpngdir=/usr/include/libpng' 'withgettext' 'withgmp' 'withmhash' 'enablejson' 'enablembregex' 'enablembregexbacktrack' 'withonig' 'enableshmop' 'enablesoap' 'enablesockets' 'enablesysvmsg' 'enablesysvsem' 'enablesysvshm' 'enablewddx' 'withlibxmldir=/usr' 'withxsl' 'withtidy' 'enablezip' 'withpear' 'disablefileinfo' 'enableintl' 'withicudir=/usr' 'withopenssldir=/usr/include/openssl' 'withreadline' 'withkerberos' 'withsnmp' 'withxmlrpc' 'enablefpm' 'withfpmuser=wwwdata' 'withfpmgroup=wwwdata' 'enablemaintainerzts' 'withlayout=GNU' 'enabledebug' 'enablecli' 'enableembeddedmysqli' 'enableembeddedpdo' 'enableembeddedpgsql' 'enableembeddedsqlite3' 'enableembeddedsnmp' 'enableembeddedldap' 'enableembeddedprocess' 'enableembeddedregex' 'enableembeddedstmp' 'enableembeddedxml' 'enableembeddedjson' 'enableembeddedmultibyte' 'enableembeddedtokenizer' 'enableembeddedsimplexml' 'enableembeddedctype' 'enableembeddedsession' 'enableembeddedgd' 'enableembeddediconv' 'enableembeddedfilter' 'enableembeddedposix' 'enableembeddedsysvmsg' 'enableembeddedsysvsem' 'enableembeddedsysvshm' 'enableembeddedpspell' 'enableembeddedxmlreader' 'enableembeddedxmlwriter' 'enableembeddeddom' 'enableembeddedcurl' 'enableembeddedzip' 'enableembeddedimap' 'enableembeddedftp' 'enableembeddedfileinfo' 'enableembeddedgmp' 'enableembeddedbcmath' 'enableembeddedjsonc' 'enableembeddedsodium' 'enableembeddedredis' 'enableembeddedmemcached' 'enableembeddedmongodb' 'enableembeddedmongoc' 'enableembeddedamqp' 'enableembeddedrdkafka' 'enableembeddedswoole' 'enableembeddedprotobuf' 'enableembeddedmsgpack' 'enableembeddedxxhash' 'enableembeddedtbb' 'enableembeddedhiredis' 'enableembeddedleveldb' 'enableembeddedluajit' 'enableembeddedlua' 'enableembeddedcouchbase' 'enableembeddedcouchbasesdk' 'enableembeddedgeoip' 'enableembeddedsassc' 'enableembeddedscssphp' 'enableembeddedtwig' 'enableembeddedv8js' 'enableembeddedv8snapshotserializer' 'enableembeddedv8shellexecutable' 'enableembeddedv8inspector' 'enableembeddedv8unwinder' 'enableembeddedv8testing' 'enableembeddedv8coverager' 'enableembeddedv8profilingtools' 'enableembeddedv8heapprofiler' 'enableembeddedv8cpuprofiler' 'enableembeddedv8memoryreducer' 'enableembeddedv8tracingcontroller' 'enableembeddedv8serializedcontextprinter' 'enableembeddedv8inspectorprotocolimpl' 'enableembeddedv8inspectorclientimpl' 'enableembeddedv8inspectorruntimeimpl' 'enableembeddedv8inspectorvaluemirrorimpl' 'enableembeddedv8inspectorhelperimpl' 'enableembeddedv8inspectoragentimpl' 'enableembeddedv8inspectorbackendimpl' 'enableembeddedv8inspectorfrontendimpl' 'enableembeddedv8inspectorpageimpl' 'enableembeddedv8inspectoroverlayimpl' 'enableembeddedv8inspectorsharedbufferimpl' 'enableembeddedv8inspectortestrunnerimpl' 'enablenestedfunctions' 'enablephar' 'withpharfullpharpath=/usr/bin/phar.phar' 'withpear=/usr/share/pear/pear.php' 'withopenssl=/usr/include/openssl/openssl.cnf' 'withzlib=/usr/include/zlib/zlib.h' 'withbz2=/usr/include/bz2/bz2.h' '...

这些命令将帮助你获取每个软件的编译参数和配置选项。

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

Powered By Z-BlogPHP 1.7.3

Copyright Your WebSite.Some Rights Reserved.