CentOS6.4 deploys and installs XAMPP1.8.3 website environment to establish and run the site

888u

Last update at :2024-06-14,Edit by888u

XAMPP environment package Some of our friends may use this one-click package for the PHP debugging environment on their local computers. The XAMPP installation package is a popular website environment that can run on multiple platforms. Supports Linux, MAC and WINDOWS systems. In this article, what Snail needs to share is to install XAMPP in the Linux Centos environment, and then install and build the website in its operating platform.

First, preparations

If we are novice VPS users, I personally recommend choosing environments such as WEB panels and one-click packages that are commonly used by the public. After all, there are many tutorial documents that you can refer to. Since Snail is just a hassle, we deployed the XAMPP1.8.3 environment in a centos6 32/64-bit environment.

yum updateyum remove httpd*

Upgrade the system and then clean up the existing environment to avoid installation conflicts.

Second, download and install XAMPP

#CentOS 32-bit

cd /tmpwget http://downloads.sourceforge.net/project/xampp/XAMPP%20Linux/1.8.3/xampp-linux-1.8.3-4-installer.run

#CentOS 64-bit

cd /tmpwget http://downloads.sourceforge.net/project/xampp/XAMPP%20Linux/1.8.3/xampp-linux-x64-1.8.3-4-installer.run

Correspond to our current system environment, and then download the XAMPP environment package to the TMP folder.

chmod 755 xampp-linux*./xampp-linux*

Grant file permissions and install the XAMPP environment.

Then you will see the installation process as shown above. We enter y according to the steps to continue until the installation is completed.

/opt/lampp/lampp start

Then restart XAMPP

Then we can see that it has been started. At this time, we open the IP address to check whether the installation is complete. We will see the Access forbidden! error message. We need to solve this problem.

Find/opt/lampp/etc/extra/httpd-xampp.conf Edit this file and find

Require localErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var

Then block these lines (add # in front).

# # Require local# ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var

Then we restart XAMPP

/opt/lampp/lampp restart

After we open the IP, we can see the XAMPP interface and select Simplified Chinese.

This way we can see that XAMPP is running OK.

Third, set up XAMPP

Open the /opt/lampp/etc/httpd.conf file and edit it

# Include etc/extra/httpd-vhosts.conf

Remove the # in front, save, and restart XAMPP.

/opt/lampp/lampp restart

Edit /opt/lampp/etc/extra/httpd-vhosts.conf to set up the site. First create the mkdir -p /var/www/html directory. We need to build the website in the HTML directory.

Then configure the site information in the httpd-vhosts.conf file.

ServerAdmin [email protected]DocumentRoot \\”/var/www/html\\”ServerName laozuo.orgServerAlias ​​www.laozuo.orgErrorLog \\”logs/laozuo.org-error_log\\”CustomLog \\”logs/laozuo .org-access_log\\” common

Execute /opt/lampp/lampp restart to restart, and then we need to set a password, such as a MYSQL password, etc.

/opt/lampp/lampp security

XAMPP: Quick security check…XAMPP: Your XAMPP pages are NOT secured by a password. . Please use \\'xampp\\' as user name!XAMPP: MySQL is accessable via network.XAMPP: Normaly that\\'s not recommended. Do you want me to turn it off? [yes] yes XAMPP: Stopping MySQL…ok.XAMPP: Starting MySQL…ok.XAMPP: The MySQL/phpMyAdmin user pma has no password set!!! again):XAMPP: Setting new MySQL pma password. yesXAMPP: Write the password somewhere down to make sure you won't forget it!!!XAMPP: Password:XAMPP: Password (again):XAMPP: Setting new MySQL root password.XAMPP: Change phpMyAdmin's authentication method .XAMPP: The FTP password for user \\'daemon\\' is still set to \\'xampp\\'.XAMPP: Do you want to change the password? [yes] yesXAMPP: Password:XAMPP: Password (again) :XAMPP: Reload ProFTPD…ok.XAMPP: Done.

After executing the command, we will operate the above demonstration command. It is used to set the password for MYSQL and PHPMYADMIN. Then after we are finished, log in to HTTP://IP/xampp. We can set the user name and password in the execution path. xampp is the user name and the password is set by us.

Fourth, activate and start eAccelerator

Because some programs need to use eAccelerator, we need to start it. It is turned off by default. We need to start it in the /opt/lampp/etc/php.ini file and find the following code:

;extension=\\”eaccelerator.so\\”;eaccelerator.shm_size=\\”16\\”;eaccelerator.cache_dir=\\”/opt/lampp/temp/eaccelerator\\”;eaccelerator.enable =\\"1\\";eaccelerator.optimizer=\\"1\\";eaccelerator.check_mtime=\\"1\\";eaccelerator.debug=\\"0\\";eaccelerator.filter=\ \"\\";eaccelerator.shm_max=\\"0\\";eaccelerator.shm_ttl=\\"0\\";eaccelerator.shm_prune_period=\\"0\\";eaccelerator.shm_only=\\"0 \\";eaccelerator.compress=\\"1\\";eaccelerator.compress_level=\\"9\\"

Then remove the previous; comment and save.

Finally, restart /opt/lampp/lampp restart. We can go to the directory and add the file demo site.

To summarize, this article is about installing the XAMPP environment in CENTOS. If you want to do it, you can also play around. The XAMPP environment is used more when debugging our local PHP, or it is also used a lot in the MAC environment.

Recommended site searches: overseas hosts, virtual host space, forum registration, same IP site query, foreign free asp space, independent IP host, 1g US virtual host, IP query overseas virtual host, station group server,

CentOS6.4 deploys and installs XAMPP1.8.3 website environment to establish and run the site

All copyrights belong to 888u unless special state
取消
微信二维码
微信二维码
支付宝二维码