WordPress Help

Installing WordPress on ibiblio

  • Note that lines starting with a “$” indicate commands issued from login.ibiblio.org.
  • The “$” is the command prompt and is not part of the command you would enter.
  • Similarly, items in ALL CAPS definitely need to be replaced by values that match your site.

Using WP-CLI

We recommend using the wp-cli (wordpress command line interface) for installing and updating your WordPress site. On login.ibiblio.org, wp-cli is installed system-wide as ‘wp’:

$ which wp
/usr/local/bin/wp

If you prefer to install your own copy, you can find instructions for installing the wp-cli here.

The wp-cli allows you to do much more than installing and updating – you can read more about it in the wp-cli handbook.

We’ve included instructions for installing and updating WordPress both with and without the wp-cli below.

Installing WordPress on ibiblio with wp-cli

Instructions here.

  1. Use an SSH client to connect to login.ibiblio.org. 
  2. Create (or request) a directory for your blog. For instance:

     $ cd /public/html/YOURSITE/
     $ mkdir wordpress
  3. Request a MySQL database if you don’t have one already.
  4. cd to the directory you created above
  5. type: $ wp core download
  6. type: $ wp config create –dbname=DATABASENAME –dbuser=DATABASE USERNAME –prompt=dbpass
    • These are the credentials provided to you when your database was set up
  7. Type: $ wp db create
  8. Type: $ wp core install –url=YOURURLHERE –title=YOURTITLEHERE –admin_user=YOURWORDPRESSUSERNAME –admin_password=YOURWORDPRESSPASSWORD –admin_email=YOUREMAIL

Installing WordPress on ibiblio without using wp-cli

Installing WordPress on ibiblio really is simple! Even if you’re squeamish at the command line, you can simply follow our recipe:

  1. Use an SSH client to connect to login.ibiblio.org.
  2. Create (or request) a directory for your blog. For instance:
     $ cd /public/html/YOURSITE/
     $ mkdir wordpress
    
  3. Request a MySQL database if you don’t have one already.
  4. Download and unpack the latest copy of WordPress:
     $ cd /public/html/YOURSITE
     $ wget http://wordpress.org/latest.tar.gz
     $ tar xvfz FILE_JUST_SAVED_BY_WGET
     $ rm FILE_JUST_SAVED_BY_WGET
    
  5. Browse to http://www.ibiblio.org/YOURSITE/wordpress and follow the installation instructions.

If you need help or have problems with the installation, please drop us a note via http://www.ibiblio.org/help.

Upgrading WordPress on ibiblio

  • Note that lines starting with a “$” indicate commands issued from login.ibiblio.org.
  • The “$” is the command prompt and is not part of the command you would enter.
  • Similarly, items in ALL CAPS definitely need to be replaced by values that match your site.

Upgrading WordPress on ibiblio with wp-cli

  1. Use an SSH client to connect to login.ibiblio.org.
  2. Back up your database tables. This only takes a minute and can really save you some headaches:

     $ mysqldump -h MYSQL.ibiblio.org -u MYSQLUSER --password="SOMEPASSWORD" YOURDBNAME > WORDPRESS-YYYYMMDD.sql
    • Don’t forget to substitute the values above with yours. For instance, your database server might be mysql2.ibiblio.org, and YOURDBNAME will be the name of your mysql database, etc. If you don’t know these values but have a working WordPress install, you can find them in your wp-config.php file.
    • Please NOTE that the backup process will brieflly lock the database, making your site inaccessible. This usually takes less than 30 seconds, but if you’re worried about it, do it during off-peak hours.
      To save space, please gzip your SQL backup file:

       $ gzip WORDPRESS-YYYYMMDD.sql
  3. Navigate to the folder where your wordpress is located
  4. Type: $ wp core version
    • To see current version
  5. Type: $ wp core update
    • To update to newest version
  6. Type: $ wp core update-db
    • To update database, or confirm that the database was updated
  7. Type: $ wp theme update –all
    • To update your installed themes
  8. Type: $ wp plugin update –all
    • To update all plugins

Upgrading WordPress on ibiblio without wp-cli

  1. Use an SSH client to connect to login.ibiblio.org.
  2. Back up your database tables. This only takes a minute and can really save you some headaches:
     $ mysqldump -h MYSQL.ibiblio.org -u MYSQLUSER --password="SOMEPASSWORD" YOURDBNAME > WORDPRESS-YYYYMMDD.sql
    • Don’t forget to substitute the values above with yours. For instance, your database server might be mysql2.ibiblio.org, and YOURDBNAME will be the name of your mysql database, etc. If you don’t know these values but have a working WordPress install, you can find them in your wp-config.php file.
    • Please NOTE that the backup process will briefly lock the database, making your site inaccessible. This usually takes less than 30 seconds, but if you’re worried about it, do it during off-peak hours.To save space, please gzip your SQL backup file:
       $ gzip WORDPRESS-YYYYMMDD.sql
      
  3. Disable all plugins.
    Wordpress upgrades can cause irreversible damage in some cases if you fail to disable your plugins. You did make a backup, right?

    • Change directories to the directory above your WordPress installation:
 $ cd /public/html/YOURSITE
    • If your blog is a subdirectory named “wordpress” then you would do the following:
 $ wget http://wordpress.org/latest.tar.gz
 $ tar xvfz FILE_JUST_SAVED_BY_WGET
 $ rm FILE_JUST_SAVED_BY_WGET

WordPress may want to modify its database tables to accommodate the new version.

    • Browse to http://www.ibiblio.org/YOURSITE/wp-admin/upgrade.php and follow the instructions.
    • If your blog isn’t a subdirectory named “wordpress” you’ll want to do something like:
       $ mkdir ~/tmp
       $ cd ~/tmp
       $ wget http://wordpress.org/latest.tar.gz
       $ tar xvfz FILE_JUST_SAVED_BY_WGET
       $ rm FILE_JUST_SAVED_BY_WGET
       $ rsync -av wordpress/ /public/html/YOURSITE/YOURWORDPRESSDIR/
  1. Then proceed to the upgrade itself by browsing to http://www.ibiblio.org/YOURSITE/YOURWORDPRESSDIR/wp-admin/upgrade.php and following the instructions.
  2. Re-enable your plugins, one by one. If you enable a plugin and then can’t get to your blog, use your SSH/SFTP client to go into your wp-content/plugins directory, and remove the plugin that caused things to break. You can simply rename the directory for the offending plugin and it will be automatically disabled.

That should do it! Please do be sure to follow answers.ibiblio.org discussion about web applications such as WordPress.

What to do when you have problems running WordPress on ibiblio

  • First thing, please do make sure you’re running the most current version of WordPress. They make releases to fix bugs and security problems much more often than to add new features. The instructions above can help you with this.
  • The most common WordPress problems stem from buggy plugins. If you get strange or inconsistent error messages, try disabling your plugins, then re-enabling them one by one. This should help isolate if a particular plugin is causing a problem for you.
  • If these steps don’t take care of things, please do drop us a note via our Q&A site and a member of the ibiblio team will be back in touch with you.

An alternate backup method

Some users strongly prefer using an SFTP client and never using an SSH client. Please note that you will need to make slightly different backup arrangements if you go this route. For documentation on this approach, please see first here and later here for backup strategies. Please note that some kinds of errors are unrecoverable, so it is imperative that you implement a backup strategy and keep using it. If you do not, we may be unable to rescue you!