Preface:
Yesterday learned to install the server, today try to install lamp through the remote terminal Xshell, with the development environment, there is an integrated environment can be installed using a key, or a blind toss, manually step by step to build this development environment.
Next : Ubuntu server 14.04 LTS built lamp environment One of the most detailed notes U disk installation dual system This article original blog address: http://www.cnblogs.com/unofficial official website address:www.pushself.com)
Prepare:
On the Windows system first need to install Xhsell, specifically can search, the installation process there is no special need to pay attention to.
You need to install an SSH service on the server, install the command:sudo apt-get install openssh-server
actual operation:
① Establish remote connection, configure Xshell, new-
First: The corresponding is the name, this is to see oneself can be arbitrarily named, used to identify
Second: Connection mode ssh
Third: Server IP address (not clear can use command query:ifconfig)
IV: Service port (default)
Finally, enter the user name, user password and Login success screen when installing Ubuntu server.
Note: If there is a garbled Chinese, you need to set the interface encoding to UTF-8, encoding settings: File-Properties-terminal-utf-8
Connected to the server, then I formally started the installation environment Oh, →_→, a lot of crap, can't wait
PHP Development Environment configuration:
① install Apache, enter command, return, wait for prompt confirmation, enter Y, carriage return. Install Apache command:sudo apt-get install apache2
After the installation is complete, verify that the installation was successful:apache2-v
We can also enter the server IP address in the browser address bar, enter to see, such as
② install PHP, input command, enter, wait for prompt confirmation, enter Y, carriage return. Install Apache command:sudo apt-get install php5
After the installation is complete, verify that the installation was successful:php5-v
③ install MySQL, input command, enter, wait for prompt confirmation, enter Y, carriage return. Install Apache command:sudo apt-get install mysql-server
You will be prompted to enter the database user name root, set the root password,
After the password entered, enter, ask for a confirmation password, the password just entered once again input
Mysql-server installation is successful, because the PHP installation process is not installed by default MySQL extension, so we need to manually install the Php5-mysql
Install command:sudo apt-get install php5-mysql
Now that we have successfully installed the Apache,php,mysql, let's restart the service
Restart MySQL command:sudo service mysql restart
Restart Apache services:sudo service apache2 restart This article original blog address: http://www.cnblogs.com/unofficial official website address:www.pushself.com)
Through the above installation steps we can summarize a command to install lamp:
The Install LANMP command is:sudo apt-get install apache2 php5 mysql-server php5-mysql
→_→ Finally we create a Phpindo file, such as operation, you can also refer to the operation steps:
①cd/var/www/html
②sudo Vim index.php
③ Input Code
<? PHP Phpinfo ();? >
By the end of the note, the next note was to create my first PHP project. This article original blog address: http://www.cnblogs.com/unofficial official website address:www.pushself.com)