[vc_row][vc_column width=”1/1″][vc_tour][vc_tab title=”Install Software” tab_id=”1394880595-1-44″][vc_column_text]
su ##root sudo apt-get update ##Update source, suggest to do this before each installation sudo apt-get install apache2 ##apache sudo apt-get install libapache2-mod-php5 php5 ##PHP sudo apt-get install mysql-server ##Install MySQL sudo apt-get install php5-mysql
Start mysql
sudo /etc/init.d/mysql start
Enter mysql and initial setup
1
mysql -u root -p --Login #Start security settings 3 use mysql; ##Switching Database update user set password=password('1234') where user='root'; --Change the password to 1234 flush privileges; --Forced refresh the memory authorization form drop database test; delete from db; delete from user where not (user='root'); insert into mysql.user(Host,User,Password,ssl_cipher,x509_issuer,x509_subject) values ("localhost","wordpress",password('2345'),'','',''); --Create wordpress user create database wordpressDB; grant all privileges on wordpressDB.* to wordpress; flush privileges; --Forced refresh the memory authorization form
The created databases and users are for wordpress.
After completed
mysql-u wordpress-p
then enter the password to test whether you can successfully login.
[/vc_column_text][/vc_tab][vc_tab title=”Install WordPress” tab_id=”1394880595-2-33″][vc_column_text]
wget -c http://wordpress.org/latest.tar.gz
Unzip
tar xvzf latest.tar.gz
Copy the unzipped file to apache2, and edit the Competence.
sudo cp -rf wordpress /var/www/ cd /var/www sudo chown -R www-data:www-data wordpress/
Input http://localhost/wordpress/ into browser, if want to visit by net, you can change localhost to IP address.Will be prompted to change php profiles
cd /var/www/wordpress cp wp-config-sample.php wp-config.php vi wp-config.php
define('DB_NAME', 'wordpressDB'); // The name of the database define('DB_USER', 'wordpress'); // Your MySQL username define('DB_PASSWORD', '2345'); // ...and password
Modify properties again
sudo chown -R www-data:www-data ./wp-config.php
Restart apache2
##stop
sudo /etc/init.d/apache2 stop
##start
sudo /etc/init.d/apache2 start
Input http://localhost/wordpress/ into browser, until now wordpress set up completed.
[/vc_column_text][/vc_tab][/vc_tour][/vc_column][/vc_row]
Leave a Reply
You must be logged in to post a comment.