Applicable environment:
System support: CentOS-5 (32bit/64bit), CentOS-6 (32bit/64bit)
Memory Requirements: ≥256m
What was installed:
1, Apache 2.2.22 or Apache 2.4.2
2, MySQL 5.5.24
3, PHP 5.2.17 or PHP 5.3.13
4, phpMyAdmin 3.5.1
5, Zendoptimizer 3.3.9 (optional, only suitable for PHP 5.2.17)
6, XCache 1.3.2 (optional)
7, pure-ftpd-1.0.36 (optional)
How to install:
wget http://centos.googlecode.com/files/lamp0.4.tar.gz
Tar XF lamp0.4.tar.gz && cd lamp0.4 && chmod +x lamp.sh &&/lamp.sh
Install other
1, execute the script pureftpd.sh installs PURE-FTPD.
2, execute the script zend.sh installs Zendoptimizer.
3, execute the script xcache.sh installs XCache.
Tips for using:
Lamp script Uses
Lamp Add (del,list): Create (delete, list) a virtual host.
Lamp FTP (add|del|list): Create (delete, list) FTP users.
Lamp Uninstall: one-click Unload lamp (remember to back up good data before uninstalling!) )。
Program Directory
MySQL directory:/usr/local/mysql
MySQL Data directory:/usr/local/mysql/data
PHP Directory:/usr/local/php
Apache Directory:/usr/local/apache
Process Management
Apache Start (Stop | reboot | overload profile): Service httpd start (stop|restart|reload)
MySQL (Stop | reboot | overload profile): Service mysqld Start (stop|restart|reload)
PUREFTPD (Stop | reboot | overload profile): Service pure-ftpd start (stop|restart|reload)
Configuration file path
Apache:/etc/httpd/conf
Mysql:/etc/my.cnf
Php:/etc/php.ini/etc/php.d
Pure-ftpd:/etc/pure-ftpd.conf
Firewall shutdown and Open
1) effective after reboot
Open:
Chkconfig iptables on
Shut down:
Chkconfig iptables off
2) immediate effect, restart after failure
Open:
Service Iptables Start
Shut down:
Service Iptables Stop
It should be explained that for other services under Linux, you can use the above command to perform the open and close operations.
When the firewall is turned on, make the following settings, open the relevant port,
Modify the/etc/sysconfig/iptables file and add the following:
-A rh-firewall-1-input-m state--state new-m tcp-p TCP--dport 80-j ACCEPT
-A rh-firewall-1-input-m state--state new-m tcp-p TCP--dport 22-j ACCEPT