收集整理:怎么知道Linux系统里的 Nginx Apache MySQL PHP 编译参数是什么

  • A+
所属分类:Linux
高性能企业级服务器首台5折

查看 nginx 编译参数


  1. 1
    <span class="pln">root@ubuntu</span><span class="pun">:~<span class="hljs-comment">#</span></span><span class="pln"><span class="hljs-comment"> nginx </span></span><span class="pun"><span class="hljs-comment">-</span></span><span class="pln"><span class="hljs-comment">V </span></span>
  2. 1
    <span class="pln">nginx</span><span class="pun">:</span><span class="pln"> nginx version</span><span class="pun">:</span><span class="pln"> nginx</span><span class="pun">/</span><span class="lit">1.0</span><span class="pun">.</span><span class="lit">8</span>
  3. 1
    <span class="pln">nginx</span><span class="pun">:</span><span class="pln"> built by gcc </span><span class="lit">4.4</span><span class="pun">.</span><span class="lit">3</span> <span class="pun">(</span><span class="typ">Ubuntu</span> <span class="lit">4.4</span><span class="pun">.</span><span class="lit">3</span><span class="pun">-</span><span class="lit">4ubuntu5</span><span class="pun">)</span>
  4. 1
    <span class="pln">nginx</span><span class="pun">:</span><span class="pln"> TLS SNI support enabled </span>
  5. 1
    <span class="pln">nginx</span><span class="pun">:</span><span class="pln"> configure arguments</span><span class="pun">:</span> <span class="pun">--</span><span class="pln">conf</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">etc</span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">.</span><span class="pln">conf </span><span class="pun">--</span><span class="pln">error</span><span class="pun">-</span><span class="pln">log</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">var</span><span class="pun">/</span><span class="pln"><span class="hljs-built_in">log</span></span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">/</span><span class="pln">error</span><span class="pun">.</span><span class="pln">log </span><span class="pun">--</span><span class="pln">pid</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">var</span><span class="pun">/</span><span class="pln">run</span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">.</span><span class="pln">pid </span><span class="pun">--</span><span class="pln">lock</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">var</span><span class="pun">/</span><span class="pln">lock</span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">.</span><span class="pln">lock </span><span class="pun">--</span><span class="pln">http</span><span class="pun">-</span><span class="pln">log</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">var</span><span class="pun">/</span><span class="pln"><span class="hljs-built_in">log</span></span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">/</span><span class="pln">access</span><span class="pun">.</span><span class="pln">log </span><span class="pun">--</span><span class="pln">http</span><span class="pun">-</span><span class="pln">client</span><span class="pun">-</span><span class="pln">body</span><span class="pun">-</span><span class="pln">temp</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">var</span><span class="pun">/</span><span class="pln">lib</span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">/</span><span class="pln">body </span><span class="pun">--</span><span class="pln">http</span><span class="pun">-</span><span class="pln">proxy</span><span class="pun">-</span><span class="pln">temp</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">var</span><span class="pun">/</span><span class="pln">lib</span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">/</span><span class="pln">proxy </span><span class="pun">--</span><span class="pln">http</span><span class="pun">-</span><span class="pln">fastcgi</span><span class="pun">-</span><span class="pln">temp</span><span class="pun">-</span><span class="pln">path</span><span class="pun">=/</span><span class="pln">var</span><span class="pun">/</span><span class="pln">lib</span><span class="pun">/</span><span class="pln">nginx</span><span class="pun">/</span><span class="pln">fastcgi </span><span class="pun">--</span><span class="pln">with</span><span class="pun">-</span><span class="pln">http_stub_status_module </span><span class="pun">--</span><span class="pln">with</span><span class="pun">-</span><span class="pln">http_flv_module </span><span class="pun">--</span><span class="pln">with</span><span class="pun">-</span><span class="pln">http_ssl_module </span><span class="pun">--</span><span class="pln">with</span><span class="pun">-</span><span class="pln">http_dav_module </span><span class="pun">--</span><span class="pln">with</span><span class="pun">-</span><span class="pln">http_gzip_static_module </span><span class="pun">--</span><span class="pln">with</span><span class="pun">-</span><span class="pln">http_realip_module </span><span class="pun">--</span><span class="pln">with</span><span class="pun">-</span><span class="pln">http_sub_module </span><span class="pun">--</span><span class="pln">add</span><span class="pun">-</span><span class="pln">module</span><span class="pun">=../</span><span class="pln">substitutions4nginx</span><span class="pun">-</span><span class="pln">read</span><span class="pun">-</span><span class="pln">only </span><span class="pun">--</span><span class="pln">add</span><span class="pun">-</span><span class="pln">module</span><span class="pun">=../</span><span class="pln">ngx_cache_purge</span><span class="pun">-</span><span class="lit">1.4</span> <span class="pun">--</span><span class="pln">add</span><span class="pun">-</span><span class="pln">module</span><span class="pun">=../</span><span class="pln">ngx_http_upstream_keepalive</span><span class="pun">-</span><span class="pln">d9ac9ad67f45 </span><span class="pun">--</span><span class="pln">add</span><span class="pun">-</span><span class="pln">module</span><span class="pun">=../</span><span class="pln">agentzh</span><span class="pun">-</span><span class="pln">memc</span><span class="pun">-</span><span class="pln">nginx</span><span class="pun">-</span><span class="pln">module</span><span class="pun">-</span><span class="lit">5b0504b</span> <span class="pun">--</span><span class="pln">add</span><span class="pun">-</span><span class="pln">module</span><span class="pun">=../</span><span class="pln">agentzh</span><span class="pun">-</span><span class="pln">srcache</span><span class="pun">-</span><span class="pln">nginx</span><span class="pun">-</span><span class="pln">module</span><span class="pun">-</span><span class="lit">10d968e</span>

查看 apache 编译参数


  1. 1
    <span class="pln">root@ubuntu</span><span class="pun">:~<span class="hljs-comment">#</span></span><span class="pln"><span class="hljs-comment"> cat </span></span><span class="pun"><span class="hljs-comment">/</span></span><span class="pln"><span class="hljs-comment">usr</span></span><span class="pun"><span class="hljs-comment">/</span></span><span class="kwd"><span class="hljs-comment">local</span></span><span class="pun"><span class="hljs-comment">/</span></span><span class="pln"><span class="hljs-comment">apache2</span></span><span class="pun"><span class="hljs-comment">/</span></span><span class="pln"><span class="hljs-comment">build</span></span><span class="pun"><span class="hljs-comment">/</span></span><span class="pln"><span class="hljs-comment">config</span></span><span class="pun"><span class="hljs-comment">.</span></span><span class="pln"><span class="hljs-comment">nice</span></span>
  2. 1
    <span class="com"><span class="hljs-meta">#! /bin/sh</span></span>
  3. 1
    <span class="com"><span class="hljs-comment">#</span></span>
  4. 1
    <span class="com"><span class="hljs-comment"># Created by configure</span></span>
  5. 1
     
  6. 1
    <span class="str"><span class="hljs-string">"./configure"</span></span><span class="pln"> \</span>
  7. 1
    <span class="str"><span class="hljs-string">"--prefix=/usr/local/apache2"</span></span><span class="pln"> \</span>
  8. 1
    <span class="str"><span class="hljs-string">"--with-included-apr"</span></span><span class="pln"> \</span>
  9. 1
    <span class="str"><span class="hljs-string">"--enable-so"</span></span><span class="pln"> \</span>
  10. 1
    <span class="str"><span class="hljs-string">"--enable-deflate=shared"</span></span><span class="pln"> \</span>
  11. 1
    <span class="str"><span class="hljs-string">"--enable-expires=shared"</span></span><span class="pln"> \</span>
  12. 1
    <span class="str"><span class="hljs-string">"--enable-rewrite=shared"</span></span><span class="pln"> \</span>
  13. 1
    <span class="str"><span class="hljs-string">"--enable-static-support"</span></span><span class="pln"> \</span>
  14. 1
    <span class="str"><span class="hljs-string">"--disable-userdir"</span></span><span class="pln"> \</span>
  15. 1
    <span class="str"><span class="hljs-string">"<span class="hljs-variable">$@</span>"</span></span>

查看 mysql 编译参数


  1. 1
    <span class="pln">root@ubuntu</span><span class="pun">:~<span class="hljs-comment">#</span></span><span class="pln"><span class="hljs-comment"> find </span></span><span class="pun"><span class="hljs-comment">/</span></span><span class="pln"><span class="hljs-comment">usr </span></span><span class="pun"><span class="hljs-comment">-</span></span><span class="pln"><span class="hljs-comment">name mysqlbug</span></span>
  2. 1
    <span class="pun">/</span><span class="pln">usr</span><span class="pun">/</span><span class="pln">bin</span><span class="pun">/</span><span class="pln">mysqlbug</span>
  3. 1
    <span class="pln">root@ubuntu</span><span class="pun">:~<span class="hljs-comment">#</span></span><span class="pln"><span class="hljs-comment"> cat </span></span><span class="str"><span class="hljs-comment">"/usr/bin/mysqlbug"</span></span><span class="pun"><span class="hljs-comment">|</span></span><span class="pln"><span class="hljs-comment">grep configure</span></span>
  4. 1
    <span class="com"><span class="hljs-comment"># This is set by configure</span></span>
  5. 1
    <span class="pln">CONFIGURE_LINE</span><span class="pun">=</span><span class="str"><span class="hljs-string">"../configure  '--build=x86_64-linux-gnu' '--host=x86_64-linux-gnu' '--prefix=/usr' '--exec-prefix=/usr' '--libexecdir=/usr/sbin' '--datadir=/usr/share' '--localstatedir=/var/lib/mysql' '--includedir=/usr/include' '--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-server-suffix=-3ubuntu12.7' '--with-comment=(Ubuntu)' '--with-system-type=debian-linux-gnu' '--enable-shared' '--enable-static' '--enable-thread-safe-client' '--enable-assembler' '--enable-local-infile' '--with-pstack' '--with-fast-mutexes' '--with-big-tables' '--with-unix-socket-path=/var/run/mysqld/mysqld.sock' '--with-mysqld-user=mysql' '--with-libwrap' '--without-readline' '--with-ssl' '--without-docs' '--with-extra-charsets=all' '--with-plugins=max' '--without-ndbcluster' '--with-embedded-server' '--with-embedded-privilege-control' 'build_alias=x86_64-linux-gnu' 'host_alias=x86_64-linux-gnu' 'CC=gcc' 'CFLAGS=-O3 -DBIG_JOINS=1  -fno-strict-aliasing' 'LDFLAGS=-Wl,-Bsymbolic-functions' 'CPPFLAGS=' 'CXX=g++' 'CXXFLAGS=-O3 -DBIG_JOINS=1 -felide-constructors -fno-exceptions -fno-rtti  -fno-strict-aliasing'"</span></span>

查看 php 编译参数


  1. 1
    <span class="pln">root@ubuntu</span><span class="pun">:~<span class="hljs-comment">#</span></span><span class="pln"><span class="hljs-comment"> php5</span></span><span class="pun"><span class="hljs-comment">-</span></span><span class="pln"><span class="hljs-comment">fpm </span></span><span class="pun"><span class="hljs-comment">-</span></span><span class="pln"><span class="hljs-comment">i</span></span><span class="pun"><span class="hljs-comment">|</span></span><span class="pln"><span class="hljs-comment">grep configure                                                                                           </span></span>
  2. 1
    <span class="typ">Configure</span> <span class="typ">Command</span> <span class="pun">=&gt;</span>  <span class="str"><span class="hljs-string">'./configure'</span></span>  <span class="str"><span class="hljs-string">'--prefix=/usr/local/php-5.3.3'</span></span> <span class="str"><span class="hljs-string">'--with-config-file-path=/etc/php5'</span></span> <span class="str"><span class="hljs-string">'--with-mcrypt'</span></span> <span class="str"><span class="hljs-string">'--with-gettext'</span></span> <span class="str"><span class="hljs-string">'--with-mysql'</span></span> <span class="str"><span class="hljs-string">'--with-gd'</span></span> <span class="str"><span class="hljs-string">'--with-jpeg-dir'</span></span> <span class="str"><span class="hljs-string">'--with-png-dir'</span></span> <span class="str"><span class="hljs-string">'--with-curl'</span></span> <span class="str"><span class="hljs-string">'--with-freetype-dir'</span></span> <span class="str"><span class="hljs-string">'--enable-gd-native-ttf'</span></span> <span class="str"><span class="hljs-string">'--enable-mbstring'</span></span> <span class="str"><span class="hljs-string">'--enable-sockets'</span></span> <span class="str"><span class="hljs-string">'--enable-fpm'</span></span> <span class="str"><span class="hljs-string">'--with-zlib'</span></span> <span class="str"><span class="hljs-string">'--with-fpm-user=www-data'</span></span> <span class="str"><span class="hljs-string">'--with-fpm-group=www-data'</span></span> <span class="str"><span class="hljs-string">'--enable-xml'</span></span> <span class="str"><span class="hljs-string">'--enable-bcmath'</span></span> <span class="str"><span class="hljs-string">'--with-mhash'</span></span>

发表评论

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen: