Ubuntu under PHP mysql environment build-upcoming-chinaunix blog

Source: Internet
Author: User
Tags configuration php php mysql

Programming language Select PHP5, Web server select Apache2, background database select MySQL
First install the build tool, open the terminal

sudo apt-get install build-essential autoconf automake1.9 CVS Subversion (try it whether you've installed it or not)

Installation of Apache

sudo apt-get install Apache5

Installation of PHP5

sudo apt-get install php5

Installation of MySQL in PHP5 environment

sudo apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql

MySQL start/stop/restart

Sudo/etc/init.d/mysql start
Sudo/etc/init.d/mysql stop
Sudo/etc/init.d/mysql restart

Set root password after Mysql installation
Mysql-uroot (the root user's password is empty at first, so you can go in if you set the password in the interface when you install it.)
Can skip this step)

Go to the MySQL console:
Set password for ' root ' @ ' localhost ' =password (' YourPassword ');
If successful, MySQL tip: Query OK 0rows affected (0.00SEC)

Setup Complete Configuration

sudo gedit/etc/apach2/apach2.conf configuring Apache server

sudo gedit/etc/php5/apach2/php.ini configuration php is found in the text box "; Extension=mysql.so ", remove; indicate Apache startup
Load the module with the MySQL connection, then save and restart the Apache server.


In the/var/www directory is the home directory of Apache, new *.php input <? Phpinfo ();?> Save exit

In the Firefox address bar, enter: http://localhost/*.php run if successful, the build is complete.

Ubuntu under PHP mysql environment build-upcoming-chinaunix blog

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.