How to Install WordPress 4.7 On Ubuntu 16.10/16.04 Using LAMP Stack

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Get your own self-hosted blog with a Free Domain at ($3.95/month).
  4. Become a Supporter - Make a contribution via PayPal
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

Aaron Kili

Aaron Kili is a Linux and F.O.S.S enthusiast, an upcoming Linux SysAdmin, web developer, and currently a content creator for TecMint who loves working with computers and strongly believes in sharing knowledge.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide

You may also like...

85 Responses

  1. Brendan Garnham says:

    Thank you! Easy, painless install on Ubuntu Mate 17.04 using this tutorial. The only additional step I needed to take was renaming the original Apache index.html page so that I would be directed to index.php by default.

  2. Mero says:

    Thank you Aaron!

    Great job easy installation and no problems.

    Just had a small one with the mysql creating user and granting privileges.

  3. Andrew M says:

    One item that I found needs to be added into this is after creating the database, it helps to do a :

    USE ; otherwise, MySQL doesn’t always change the database focus – this is particularly relevant if the password is wanting to be changed for the internal MySQL account.

  4. Charity says:

    Thanks for all your help. I was able to follow along on my up to date Linux Mint box up to the final steps of restarting the web server and mySQL:

    $ sudo systemctl restart apache2.service 
    $ sudo systemctl restart mysql.service 
    

    When I enter that, I always get the same error message:
    command not found

    I have rebooted, but I still encounter the same problem. When I go to localhost, I still only get the Apache2 Ubuntu Default Page, not WordPress.

    Second, for the step just above it, the config stage, I used the define DB_NAME, DB_USER and DB_PASSWORD from the actual online install of my site, although I presume at the fresh starting point it does not make much difference since the DB that will be used locally will be, well, local, and can have its own name, user and pw. So my question is this. Are we putting this info in there so that when WordPress does start up and go to create the DB, it uses that info provided?

    Thanks so much for all your help and info!

  5. Pascal LACROIX says:

    Very nice and useful tutorial, hats off to you !!!

  6. amin says:

    Great article specially code + photo it helps a lot thanks..

  7. nick says:

    Thanks for this awesome guide, it helped a ton! I had a problem trying to connect to WP server after installing everything and editing my wp-config.php file. After a while of trouble shooting I realized the build file required the presence of the wp-config-sample.php file. I changed the name back to that ( so basically I ignored the $ sudo mv wp-config-sample.php wp-config.php ) and it came out fine.

  8. Isaac Abrahamson says:

    I am new to Linux and WordPress, this helped me out a lot! Should the user create unique authentication keys and salts for this?

    • Aaron Kili says:

      @Isaac

      Not really, you can use the same credentials(username and password) for logging into the system here, or else create a new user for the database; hope that is what you meant.

      Many thanks for the feedback.

  9. Gibbs says:

    I love the conciseness of it. I’ve been working with *nix for years now and it’s great to have a simple article with clear commands; without any bloated discussion of why they should be run. I love that the lines don’t have a LF at the end so I can paste in without it executing. Keep it up!

    • Aaron Kili says:

      @Gibbs

      Hope you enjoyed reading it. We always intend to keep our articles simple, direct but with a lot of details to help a Linux user(especially with high consideration of newbies). Thanks a ton for the kind words of appreciation.

  10. Jérôme says:

    Very useful tutorial, totally hassle-free. Thanks a lot !

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *