Manually Installing Wordpress on a Synology NAS

Photo by Alex Cheung on Unsplash

For months now, probably even years, my website (williamvanzweeden.nl) has been running as a WordPress application, hosted on my NAS. In order to get it up and running, I installed the pretty-much-one-click-install-package that is available in Package Center. Works like a charm! For sure, the response rates of my webserver weren’t always super fast but hey, since this was mostly a hobby-project, nobody cared about it. I was happy too until I decided to make some improvements, including the installation of several plugins.

  • All the sudden, my WordPress install told me two things:
    The version of WordPress I was running was the latest one available.

After a few Google queries, I found out that the first statement was not true. There was a newer version of WordPress, not for me though. The WordPress instance that you can install through Package Center is dependent on an older version of phpMyAdmin but more importantly: it relies on an older version of PHP. That is, just for your information, a version of PHP that has been declared End-Of-Life and is therefore not receiving (security) updates anymore. Time to update you’d say but apparently, the folks at Synology are busy doing other things.

Frustratingly enough, there is not a simple way, if there is a working way at all, to change the PHP version that WordPress and phpMyAdmin refer to in your Synology. So you’re stuck waiting for them to update their package.

Or… you can do it yourself, which is what I did. It isn’t very difficult, but you have to take care of a few things, which I overlooked initially.

The WordPress installation as it comes by Synology uses MariaDB. MariaDB had been working perfectly so far so there was no need to replace that. In my first attempt, I wanted to start from a clean sheet so I uninstalled both WordPress and phpMyAdmin from Package Center. Later on in the process though, I learned that the configuration files in those two packages were useful. So, instead of uninstalling them at the start, I recommend to change their names, complete the manual installs, leverage the existing config files and only delete them after you have confirmed the newer versions to be working.

Photo by Luca Bravo on Unsplash

Here’s what you do next:

  1. If not yet installed, use Package Center to install Apache 2.4 and PHP 7.3.

Next, you need to work on the config files. Let’s start with phpMyAdmin. When phpMyAdmin is installed via Package Center, it creates a workaround with regards to the configuration. So, instead of using config.php, it will instead refer to Synology_server.json. So, if you want to use the Package Center configuration in your manual install without having to change anything, you need both files.

  1. Copy config.php and synology_server.json from the pypMyAdmin_old folder to the phpMyAdmin_new folder.

Next, you will need to work on your permissions. It might be my Synology setup but whenever I upload files to my Synology, even to the web folder, they cannot be accessed from the web (williamvanzweeden.nl/something) and will turn up 403 errors instead. To solve that, you need to add permissions for the HTTP user.

Photo by mostafa meraji on Unsplash
  1. In the Synology File Explorer, right-click on the phpMyAdmin_new folder, click Properties and select the permission tab.

Okay, you’re almost there. Time for the final steps.

  1. If you haven’t done so already, rename the _old folders, removing the _old tag.

That’s it. It’s a bit of a workaround process and you gotta think for yourself when you’re about to do this but this is how I got things working on my end.

Good luck!

Hey, thanks for making it all the way down here. Did you like what you read? Take a look over here, or here, to take a look at some other articles I wrote. If you want me to inform you whenever I have published a new article, look here!

Originally published at https://williamvanzweeden.nl on May 12, 2020.

The world has truly turned upside down.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store