Build a LAMP-based web environment under CentOS5.5

Source: Internet
Author: User
Because of the purchased VPS, everything in the system is OK, just the things after installation. There is basically no software, so it is up to you to manually build my bo-blog. Basic information: OS: [root @ localhost ~] # Lsb_release-aLSBVersion :...

 

Because of the purchased VPS, everything in the system is OK, just the things after installation. There is basically no software, so it is up to you to manually build my bo-blog.

Basic information:

OS:

[Root @ localhost ~] # Lsb_release-

LSB Version: core-3.1-ia32: core-3.1-noarch: graphics-3.1-ia32: graphics-3.1-noarch

Distributor ID: CentOS

Description: CentOS release 5.5 (Final)

Release: 5.5

Codename: Final

I first use putty link up, pay attention to the Window in the Translation of the Remote charater set down menu select UTF-8, and then in the link, otherwise, when the Chinese appears, it will be garbled.

 

Install LAMP automatically:

1. [root @ localhost ~] # Vi/bin/lamp1.sh

2. enter in the opened vi or copy the following installation file:

Yum-y install httpd-devel

Yum-y install mysql-server mysql-devel

Yum-y install php-mysql php-common php-gd php-mbstring php-mcrypt php-devel php-xml

Yum-y install perl

Yum-y install mod_python

Then wq is saved and exited.

3. [root @ localhost ~] #/Bin/sh lamp1.sh

And then start to automatically download and install...

 

And so on:

1. [root @ localhost ~] # Chkconfig -- levels 235 mysqld on // Set mysql startup

[Root @ localhost ~] # Chkconfig -- levels 235 httpd on // Set apache startup

2. [root @ localhost ~] #/Etc/init. d/mysqld start // start mysql

[Root @ localhost ~] #/Etc/init. d/httpd start // start apache

Now, start the VPS address and you will be able to see the apache page. at this time, apache has been started successfully. The address where the webpage is stored is/var/www/html.

From YesCK's Blog

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.