Installing WordPress at the command line

Tutorial Difficulty Level    

After you have installed LAMP on your Linux server (or fired up a template with LAMP already installed), you may want to use a CMS like WordPress. But how to install? What are the commands?

You would need to do something like the following. First, make sure you have root privileges (sudo -i). Then, the steps are:

  • Change to web directory
  • Pull down latest WordPress version
  • Extract the files
  • Set correct permissions on the new directory

The commands for this would be:

Now simply visit http://ip-address-of-your-vm/wordpress to carry out the install. You will need to have created your database and have the user credentials on hand. The database may have been created locally or on another server, that bit is up to you. You could even use your student database on, if you have an account there.  See also this tutorial.

Afterwards you may wish to look at this tutorial.

Tip: It would not be out of the question to login via SSH to a MySQL Server created using the template MySQL Server (with PHPMyAdmin) and carry out the above commands.  This way everything would be on one server. Remember to create your database user (and a database for them) before setting up WordPress.