변군이글루

[APM] APM 설치(mysql, apache, php, zend)_201308 본문

및___APM

[APM] APM 설치(mysql, apache, php, zend)_201308

변군 변군이글루 2013.08.18 22:15
APM 설치(mysql, apache, php, zend)

 

[MySQL]

[root@lamp mysql-5.1.60]# useradd -m -c "MySQL Server" -d /usr/local/mysql -s /bin/false -u 27 mysql

[root@lamp mysql-5.1.60]# ./configure --prefix=/usr/local/mysql --localstatedir=/usr/local/mysql/data --with-charset=utf8 --with-extra-charsets=all

[root@lamp mysql-5.1.60]# make && make install

[root@lamp mysql-5.1.60]# cp /usr/local/mysql/share/mysql/my-huge.cnf /etc/my.cnf

[root@lamp mysql-5.1.60]# /usr/local/mysql/bin/mysql_install_db

[root@lamp mysql-5.1.60]# chown -R mysql.mysql /usr/local/mysql/data

[root@lamp mysql-5.1.60]# /usr/local/mysql/bin/mysqld_safe &

[root@lamp mysql-5.1.60]# /usr/local/mysql/bin/mysqladmin -u root password "비밀번호"

[root@lamp mysql-5.1.60]# /usr/local/mysql/bin/mysql -u root -p mysql

 

[Apache]

[root@lamp httpd-2.2.25]# useradd -c "Apache" -u 48 -s /sbin/nologin apache

[root@lamp httpd-2.2.25]# vi server/mpm/prefork/prefork.c

[root@lamp httpd-2.2.25]# vi server/mpm/worker/worker.c

[root@lamp httpd-2.2.25]# ./configure --prefix=/usr/local/apache2 --enable-so --enable-rewrite --enable-ssl --enable-proxy --with-mpm=worker --with-included-apr --enable-modules=all --enable-mods-shared=all

[root@byungun httpd-2.2.11]# make && make install

[root@byungun httpd-2.2.11]# /usr/local/apache2/bin/apachectl start

 

[PHP]

[root@lamp php-5.2.17]# yum -y install gdbm-devel

[root@lamp php-5.2.17]# ./configure --prefix=/usr/local/php --with-mysql=/usr/local/mysql --with-apxs2=/usr/local/apache2/bin/apxs --enable-sysvshm=yes --enable-sysvsem=yes --enable-debug=no --with-ttf --with-png-dir=/usr --with-zlib-dir --with-jpeg-dir=/usr --with-gdbm=/usr --enable-ftp --enable-mbstring --enable-sockets --enable-wddx --with-freetype-dir=/usr --enable-bcmath --with-curl --with-mcrypt --enable-mbregex --enable-exif --with-gd --enable-gd-native-ttf --enable-calendar --with-openssl --with-libxml-dir

[root@lamp php-5.2.17]# make && make install

[root@lamp php-5.2.17]# cp /usr/local/src/php-5.2.17/php.ini-dist /usr/local/php/lib/php.ini

 

httpd.conf 파일 설정

[root@lamp php-5.2.17]# vi /usr/local/apache2/conf/httpd.conf

...

- 자동 추가

LoadModule php5_module modules/libphp5.so

...

- 수동 추가

AddType application/x-httpd-php .ph .php .php3 .inc .asp .html

AddType application/x-httpd-php-source .phps

...

<IfModule dir_module>

    DirectoryIndex index.html index.php

</IfModule>

 

[root@lamp php-5.2.17]# /usr/local/php/bin/php -v

PHP 5.2.17 (cli) (built: Aug 18 2013 22:15:06)

Copyright (c) 1997-2010 The PHP Group

Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies

 

[ZendOptimizer]

[root@lamp ZendOptimizer-3.3.0a-linux-glibc21-i386]# sh install.sh

 

Enter the location of your php.ini file

/usr/local/php/lib/

 

[root@lamp ZendOptimizer-3.3.0a-linux-glibc21-i386]# /usr/local/php/bin/php -v

PHP 5.2.17 (cli) (built: Aug 18 2013 22:15:06)

Copyright (c) 1997-2010 The PHP Group

Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies

    with Zend Extension Manager v1.2.2, Copyright (c) 2003-2007, by Zend Technologies

    with Zend Optimizer v3.3.0, Copyright (c) 1998-2007, by Zend Technologies

 

0 Comments
댓글쓰기 폼