一个人免费观看视频www中文,女人与公狍交酡女免费,久久99精品久久久久久hb无码,免费人成视频网站在线观看18,亚洲热妇无码av在线播放,好姑娘高清影视在线观看,久久aaaa片一区二区,aaaaa级少妇高潮大片

綠色資源網:您身邊最放心的安全下載站! 最新軟件|熱門排行|軟件分類|軟件專題|廠商大全

綠色資源網

技術教程
您的位置:首頁服務器類Linux服務器 → Centos6.0 x64下搭建LAMP環境

Centos6.0 x64下搭建LAMP環境

我要評論 2013/07/07 01:30:32 來源:綠色資源網 編輯:www.dq05.cn [ ] 評論:0 點擊:311次

系統環境:Centos6.0 x64

1、確認搭建LAMP所需要的環境是否已經安裝

[root@centos6 ~]# rpm -q make gcc gcc-c++ zlib-devel libaio

備注:安裝libpng時候需要zlib-devel

             安裝mysql時候需要libaio

2、如果沒安裝則yum安裝

[root@centos6 ~]# yum install make gcc gcc-c++ zlib-devel libaio -y

3、由于要使用編譯安裝,所以查看httpd、mysql、php是否安裝,如果安裝則卸載

[root@centos6 ~]# rpm -q httpd mysql php

4、編譯安裝libxml2

注:libxml2是一個xml的c語言版的解析器,不僅支持c語言,還支持c++、php、Pascal、Ruby、Tcl等語言的綁定

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf libxml2-2.7.8.tar.gz

[root@centos6 LAMP]# cd ./libxml2-2.7.8

[root@centos6 libxml2-2.7.8]# ./configure  --prefix=/usr/local/libxml2/

[root@centos6 libxml2-2.7.8]# make;make install

5、編譯安裝libmcrypt

注:libmcrypt是加密算法擴展庫。支持DES, 3DES, RIJNDAEL, Twofish, IDEA, GOST, CAST-256, ARCFOUR, SERPENT, SAFER+等算法。

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf libmcrypt-2.5.8.tar.gz

[root@centos6 LAMP]# cd ./libmcrypt-2.5.8

[root@centos6 libmcrypt-2.5.8]# ./configure  --prefix=/usr/local/libmcrypt/

[root@centos6 libmcrypt-2.5.8]# make;make install

6、編譯安裝zlib

注:zlib是提供數據壓縮用的函式庫

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf zlib-1.2.5.tar.gz

[root@centos6 LAMP]# cd ./zlib-1.2.5

[root@centos6 zlib-1.2.5]# ./configure  --prefix=/usr/local/zlib/

[root@centos6 zlib-1.2.5]# make ; make install

7、編譯安裝libpng

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf libpng-1.5.4.tar.gz

[root@centos6 LAMP]# cd ./libpng-1.5.4

[root@centos6 libpng-1.5.4]#

./configure --prefix=/usr/local/libpng/  --enable-shared

[root@centos6 libpng-1.5.4]# make ; make install

8、編譯安裝jpeg

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf jpegsrc.v8c.tar.gz

[root@centos6 LAMP]# cd ./jpeg-8c/

[root@centos6 jpeg-8c]# mkdir /usr/local/jpeg/(創建jpeg軟件的安裝目錄)

[root@centos6 jpeg-8c]# mkdir /usr/local/jpeg/bin/(創建存放命令的目錄)

[root@centos6 jpeg-8c]# mkdir /usr/local/jpeg/lib/(創建jpeg庫文件所在目錄)

[root@centos6 jpeg-8c]# mkdir /usr/local/jpeg/include/(創建存放頭文件目錄)

[root@centos6 jpeg-8c]# mkdir -p /usr/local/jpeg/man/man1(建立存放手冊的目錄)

[root@centos6 jpeg-8c]#

 ./configure --prefix=/usr/local/jpeg/ --enable-shared --enable-static(建立共享庫使用的GNU的libtool和靜態庫使用的GNU的libtool)

[root@centos6 jpeg-8c]# make ; make install

9、編譯安裝freetype

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf freetype-2.4.6.tar.gz

[root@centos6 LAMP]# cd ./freetype-2.4.6

[root@centos6 freetype-2.4.6]#

 ./configure --prefix=/usr/local/freetype/ --enable-shared

[root@centos6 freetype-2.4.6]# make ;make install

10、      編譯安裝autoconf

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf autoconf-2.68.tar.gz

[root@centos6 LAMP]# cd ./autoconf-2.68

[root@centos6 autoconf-2.68]# ./configure

[root@centos6 autoconf-2.68]# make ; make install

11、      編譯安裝GD

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf gd-2.0.35.tar.gz

[root@centos6 LAMP]# cd ./gd-2.0.35

[root@centos6 gd-2.0.35]#

 ./configure --prefix=/usr/local/gd/ --with-zlib=/usr/local/zlib/ --with-jpeg=/usr/local/jpeg/ --with-png=/usr/local/libpng/ --with-freetype=/usr/local/freetype/

[root@centos6 gd-2.0.35]# make ; make install

12、      安裝apache

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf httpd-2.2.19.tar.gz

[root@centos6 LAMP]# cd ./httpd-2.2.19

[root@centos6 httpd-2.2.19]#

 ./configure --prefix=/usr/local/apache/ --enable-so --enable-rewrite

[root@centos6 httpd-2.2.19]# make ; make install

[root@centos6 LAMP]# /usr/local/apache/bin/apachectl start

[root@centos6 LAMP]#

cp /usr/local/apache/bin/apachectl /etc/init.d/httpd

[root@centos6 LAMP]# chmod +x /etc/init.d/httpd

[root@centos6 ~]# chkconfig --add httpd

注意:如果提示service httpd does not support chkconfig錯誤

解決辦法:編輯/etc/rc.d/init.d/httpd在文件第二行加入

           #chkconfig:2345 10 90

           #description:Activates/Deactivates Apache Web Server

[root@centos6 ~]# chkconfig --level 2345 httpd on

[root@centos6 LAMP]# service httpd restart

開機自動啟動apache的另一種方法:

修改/etc/rc.local文件

# vim /etc/rc.local

在文件中添加/usr/local/apache/bin/apachectl start

13、      編譯安裝mysql

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]# tar -zxvf mysql-5.5.15-linux2.6-x86_64.tar.gz

[root@centos6 LAMP]# cd ./mysql-5.5.15-linux2.6-x86_64

[root@centos6 mysql-5.5.15-linux2.6-x86_64]# groupadd mysql

[root@centos6 mysql-5.5.15-linux2.6-x86_64]# useradd -r -g mysql mysql(創建mysql用戶,并將用戶指定至mysql組)

[root@centos6 mysql-5.5.15-linux2.6-x86_64]# cd /usr/local/

[root@centos6 local]# ln -s /tmp/LAMP/mysql-5.5.15-linux2.6-x86_64 mysql

[root@centos6 local]# cd ./mysql/

[root@centos6 mysql]# chown -R mysql .(將該目錄的用戶權限全部更改為mysql用戶)

[root@centos6 mysql]# chgrp -R mysql .(將該目錄的用戶組全部改為mysql用戶組)

[root@centos6 mysql]# ./scripts/mysql_install_db --user=mysql(將mysql目錄的數據庫使用權限指定為mysql)

[root@centos6 mysql]# chown -R root .

[root@centos6 mysql]# chown -R mysql data

[root@centos6 mysql]# cp support-files/my-medium.cnf  /etc/my.cnf(將當前目錄下的配置文件拷貝到系統配置文件下,并更名為my.cnf)

[root@centos6 mysql]# cp support-files/mysql.server  /etc/init.d/mysqld

[root@centos6 mysql]# chmod +x /etc/init.d/mysqld

[root@centos6 mysql]# chkconfig --add mysqld

[root@centos6 mysql]# chkconfig --level 345 mysqld on

[root@centos6 mysql]# service mysqld restart

[root@centos6 mysql]#

 /usr/local/mysql/bin/mysqladmin -u root password '123456'(設置root用戶登錄mysql的密碼)

[root@centos6 mysql]# /usr/local/mysql/bin/mysql -u root –p(進入并訪問mysql數據)

Enter password:

Welcome to the MySQL monitor. Commands end with ; or g.

Your MySQL connection id is 2

Server version: 5.5.15-log MySQL Community Server (GPL)

Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its

affiliates. Other names may be trademarks of their respective

owners.

Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.

mysql>(成功登錄mysql)

14、      編譯安裝php

[root@centos6 LAMP]# pwd

/tmp/LAMP

[root@centos6 LAMP]#

關鍵詞:CentOS,LAMP

閱讀本文后您有什么感想? 已有 人給出評價!

  • 0 歡迎喜歡
  • 0 白癡
  • 0 拜托
  • 0 哇
  • 0 加油
  • 0 鄙視
主站蜘蛛池模板: 亚洲色中文字幕无码av| 国产妇女馒头高清泬20p多毛| 精品久久久久久无码国产| 狠狠色丁香婷婷久久综合| 久久无码人妻精品一区二区三区 | 武装少女在线观看高清完整版| 国产女人好紧好爽| 国产精品亚洲va在线| 涩涩涩丁香色婷五月网| 日韩av一中美av一中文字慕| 色翁荡息又大又硬又粗又视频图片| 最近最新中文字幕视频| 大地资源网在线观看免费动漫| 两个人的视频全免费观看在线| 亚洲乱码精品久久久久..| 人妻精品无码一区二区三区| 国产精品自产拍在线观看花钱看 | 97在线观看免费版高清| 一二三四在线播放免费观看高清电影| 亚洲精品无amm毛片| 国产成人亚洲精品无码车a| 国产毛多水多高潮高清| 777午夜精品免费观看| 成人伊人精品色xxxx视频| 直播成品人直播app下载| 自拍偷自拍亚洲精品第1页| 好姑娘免费中文在线观看| 扒开双腿疯狂进出爽爽爽| 成全高清mv电影免费观看| 国产欧美va欧美va香蕉在线| 国产成人精品久久一区二区三区 | 亚洲欧美自拍偷一区二区 | a亚洲va欧美va国产综合| 一区二区三区国产亚洲网站| …久久精品99久久香蕉国产| 中文在线8资源库| 丝瓜视频在线观看免费| 中文字幕精品一区二区2021年| 内射人妻少妇无码一本一道| 电影在线观看+伦理片| 国产免费视频|