查看mysql,apache,php,nginx编译参数
#/usr/local/nginx/sbin/nginx -V
cat /usr/local/mysql/bin/mysqlbug | grep CONFIGURE_LINE
查看apache编译参数:
cat $apachehome$/build/config.nice
查看php编译参数:
$PHP$/bin/php -i | grep configure
本文出自 “ohgenlong16300blog.com” 博客,请务必保留此出处http://ohgenlong16300.blog.51cto.com/499130/846075
轻松获取LAMP,LNMP环境编译参数配置
大家是否遇到过去了新公司,公司内的LAMP,LNMP等所有的环境都是配置好的(已经在提供服务了),公司又没有留下部署文档,甚至安装LAMP,LAMP等环境的人已经和你交接完离职了,那么线上服务器(lamp,lnmp)的编译环境等就成了黑盒,如果不改造还好,当服务器需要迁移改造时,我们(新手的你)没有老的环境编译情况,就会很郁闷,生怕编译错了影响线上程序运行。
其实,很多时候,是可以看到软件的编译的情况的,下面老男孩就以lamp,lnmp环境为例为大家一一道来。
1)查看web服务的编译参数
a.查看nginx的编译参数:
/home/oldboy/run/nginx/sbin/nginx -V
范例1:
- [root@VM-001 ~]# /home/oldboy/run/nginx/sbin/nginx -V
- nginx version: nginx/0.8.50
- built by gcc 4.1.2 20080704 (Red Hat 4.1.2-48)
- configure arguments: --prefix=/app/nginx
提示:/home/oldboy/run/为普通用户起的nginx服务命令路径
b.查看apache的编译参数:
cat /home/oldboy/run/apache/build/config.nice
范例2:
- [root@VM-002 ~]# cat /home/oldboy/run/apache/build/config.nice
- #! /bin/sh
- #
- # Created by configure
- "./configure" \
- "--prefix=/app/apache2.2.9" \
- "--enable-deflate" \
- "--enable-headers" \
- "--enable-modules=so" \
- "--enable-so" \
- "--with-mpm=worker" \
- "--enable-rewrite" \
- "--enable-cgi" \
- "$@"
提示:/home/oldboy/run/为普通用户起的apache服务命令路径
2)查看MySQL数据库的编译参数:
grep CONFIGURE_LINE /app/mysql/bin/mysqlbug
提示:还发现很多人先cat,在grep,很不专业,应杜绝。
范例3:
- [root@VM-001~]# grep CONFIGURE_LINE /app/mysql/bin/mysqlbug
- CONFIGURE_LINE="./configure '--prefix=/app/mysql/' '--enable-assembler' '--with-extra-charsets=complex' '--enable-thread-safe-client' '--with-big-tables' '--with-readline' '--with-ssl' '--with-embedded-server' '--enable-local-infile' '--with-plugins=partition,innobase' '--with-plugin-PLUGIN'"
- `test -n "$CONFIGURE_LINE" && echo "Configure command: $CONFIGURE_LINE"`
提示:/app为mysql服务安装路径
3)查看php编译参数:
/app/php/bin/php -i|grep configure
范例4:
- [root@VM-001 ~]# /app/php/bin/php -i|grep configure
- Configure Command => './configure' '--prefix=/app/php' '--with-apxs2=/app/apache/bin/apxs' '--with-mysql=shared,/app/mysql' '--with-ttf=shared' '--with-freetype-dir' '--with-gd' '--with-zlib' '--with-jpeg-dir' '--with-png-dir' '--with-iconv=/app/libiconv' '--enable-short-tags' '--enable-sockets' '--enable-zend-multibyte' '--enable-soap' '--with-openssl' '--enable-mbstring' '--enable-static' '--enable-gd-native-ttf' '--with-curl' '--with-xsl' '--enable-ftp' '--with-libxml-dir'
提示:/app为php服务安装路径
本文得益于智君同学的http://ohgenlong16300.blog.51cto.com/499130/846075文章才有的分享!
本文出自 “老男孩linux培训” 博客,请务必保留此出处http://oldboy.blog.51cto.com/2561410/929333
查看mysql,apache,php,nginx编译参数的更多相关文章
- 查看mysql apache php nginx的编译参数
查看mysql编译参数: cat /usr/local/mysql/bin/mysqlbug|grep configure 查看apache编译参数: cat /usr/local/apache2/b ...
- 查看 apache、nginx、php、mysql 的编译参数
查看nginx编译参数:/usr/local/nginx/sbin/nginx -V 查看apache编译参数:cat /usr/local/apache2/build/config.nice 查看m ...
- 查看Nginx、apache、MySQL和PHP的编译参数
1.nginx编译参数:#/usr/local/nginx/sbin/nginx -V2.apache编译参数:# cat /usr/local/apache/build/config.nice3.p ...
- 如何查看已经安装的nginx、apache、mysql和php的编译参数
1.nginx编译参数: nginx -V(大写) #注意:需保证nginx在环境变量中,或者使用这样的形式:/user/local/nginx/sbin/nginx -V 2.apache编译参数 ...
- apache、nginx、php、mysql 编译参数查询
nginx编译参数查看:/usr/local/nginx/sbin/nginx -V apache编译参数查看:cat /usr/local/apache2/build/config.nice mys ...
- Zabbix 监控MySQL、Apache、Nginx应用监控
zabbix对第三方应用软件的监控,主要有两个工作难点,一个是编写自定义监控脚本,另一个是在编写模板并导入zabbix web中,编写脚本这个要根据 监控需求定制即可,而编写模板文件有些难度,不过网上 ...
- Linux下查看mysql、apache是否安装,安装,卸载等操作
Linux下查看mysql.apache是否安装,并卸载. 指令 ps -ef|grep mysql 得出结果 root ? :: /bin/sh /usr/ ...
- linux下如何查看mysql、apache是否安装,并卸载
--linux下如何查看mysql.apache是否安装,并卸载? http://blog.163.com/dengxiuhua126@126/blog/static/1186077720137311 ...
- LAMP第一部分安装mysql -apache -php
1. 安装mysqlcd /usr/local/src/ 免安装编译二进制的包wget http://syslab.comsenz.com/downloads/linux/mysql-5.1.40-l ...
随机推荐
- 通过HttpWebRequest请求https接口
一.为什么进行代理接口的开发: 有些项目需要访问被墙了哒网站,比如前不久公司开发项目需要使用google地图的接口,而google在中国被墙了,所有打算做一个代理接口服务,将代理放到国外服务器上,通过 ...
- mybatis There is no getter for property named 'xxxx
mybatis There is no getter for property named 'xxxx 360反馈意见截图16230322799670.png http://blog.sina.com ...
- python CGI编程Apache配置
1. 编辑http.conf,添加两行,路径可以自定义 <Directory "C:/AppServ/www/cgi-bin"> AllowOverride None ...
- GJM:用C#实现网络爬虫(二) [转载]
上一篇<用C#实现网络爬虫(一)>我们实现了网络通信的部分,接下来继续讨论爬虫的实现 3. 保存页面文件 这一部分可简单可复杂,如果只要简单地把HTML代码全部保存下来的话,直接存文件就行 ...
- 初识Hibernate 缓存
生活就像一杯咖啡,让你我慢慢的品尝,品尝它的苦涩和甘甜...... 一.什么是Hibernate缓存. 解析:白话来说就是缓存数据的容器 官方标准点缓存:是计算机领域的概念,它介于应用程序和永久性数据 ...
- ArcGIS server 开发实践之【FeatureLayer类】
全是干活,你值得拥有 要素图层类简介:Class:FeatureLayer //调用方式:require(["esri/layers/FeatureLayer"],function ...
- 值得 Web 开发人员收藏的16款 HTML5 工具
HTML5 正在迅速改变创建和管理网站的方式.HTML5 在不同的领域让网页设计更强大的.快速,安全,响应式,互动和美丽,这些优点吸引更多的 Web 开发人员使用 HTML5 开发各种网站和应用程序. ...
- JavaScript中使用typeof运算符需要注意的几个坑
typeof是一个运算符,它对操作数返回的结果是一个字符串,有6种(只针对ES,不包含HOST环境对象). 1.'undefined'2.'boolean'3.'string'4.'number'5. ...
- SharePoint 2013 报:网站在改进过程中处于只读状态,对此给您带来的不便,我们深表歉意
SharePoint 2013备份过程意外中断,导致再打开站点报:网站在改进过程中处于只读状态,对此给您带来的不便,我们深表歉意 英文:We apologize for any inconvenien ...
- datagridview的数据存取
这里主要是复习DataSet等数据或ADO.NET方面的知识.下面是一个简单的数据存储(在DataGridView上增加一行然后并存储到数据库的过程): private void button1_Cl ...