Install lamp (ubuntu environment)

Source: Internet
Author: User
Tags fully qualified domain name
Lamp installation (ubuntu environment)-Linux Enterprise Application-Linux server application information, the following is a detailed description. LAMP (Linux + Apache + Mysql + Perl/PHP/Python) is an open Resource Network Development Platform Based on Linux, Apache, MySQL, and PHP. It is hailed as a golden combination of PHP development.

1. Install the LAMP component
System-> System Management-> New Software Package Manager, open new software package, edit?> Mark a software package using a task group?> Select LAMP Server.

2. Install phpmyadmin
System-> System Management-> New Software Package Manager, open the new software package search phpmyadmin, and mark the installation.
Or sudo apt-get install phpmyadmin to establish a hard connection between phpmyadmin and apache2. For example, run the following command to access the/home/dreamcatcher/www directory of my www: sudo ln-s/usr/share/phpmyadmin/home/dreamcatcher/www can be opened in the browser address bar http: // localhost/phpmyadmin.

3. Enable mod_rewrite module
Sudo a2enmod rewrite

4. apachesupports .htm. html. php
Sudo gedit/etc/apache2/apache2.conf
Add
AddType application/x-httpd-php. php. htm. html
Solve the Problem of Garbled text in firefox, or this file, and add
Adddefacharcharset UTF-8
Here the UTF-8 can also be replaced by gb2312 according to the actual situation.

5. Restart apache
Sudo/etc/init. d/apache2 restart
6. Start mysql: mysql-u root-p. Enter the password as prompted.
If:
* Restarting web server apache2
Apache2: cocould not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
Apache2: cocould not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName

Continue sudo gedit/etc/apache2/apache2.conf
Add ServerName 127.0.0.1 to the end of the file.

Note: Remember the following commands and locations:

Sudo/etc/init. d/apache2 restart (restart apache)

Sudo gedit/etc/php5/apache2/php. ini (configure php. ini)

Sudo gedit/etc/apache2/apache2.conf (configure apache2.conf)

/Var/www/cgi-bin/(CGI program)
Related Article

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.