HOW TO COPY A LIVE WORDPRESS SITE TO YOUR SYNOLOGY DEVICE


HOW TO ENABLE YOUR SYNOLOGY DEVICE
TO HOST A COPY OF YOUR LIVE ONLINE WEB SITE

I have tried to make this as simple as possible, as I found most of the tutorials online to be either difficult to follow, incomplete or just so long winded that I gave up out of sheer misery!

I would like to point out that I am an amateur in WordPress and web material in general, so I am open to all suggestions on how to make this article better for other people to read and understand, as I have may have some glaring mistakes, that are not apparent to me.
I have worked through this list a number of times and it has worked for me, so I hope it does the same for you.

Lets start by going to your WordPress enabled web site, and installing a new plugin called: DUPLICATOR

Voila_Capture10

You can search for this in the plugins section, or download it from the creator’s web site over at: http://lifeinthegrid.com/labs/duplicator/

And yes… the plugin is FREE!

Once you have it installed, click on Duplicator at the bottom of the left hand side of the screen. You should see on the right hand side that there are no packages to be found.

Voila_Capture11
Click the button to create a new package and after a few seconds you will be prompted for a name for this backup and also an option to comment on it if required. Just click on Create Package Set and the backup will be created. Depending in the size of your site, this may take a few minutes to complete.

Voila_Capture12

Once done, you should see something similar to the image below.

Voila_Capture13

All you need to do now is click on the button INSTALLER and it will download an installation file, and then click on PACKAGE to download all the site data.

Voila_Capture14

Once we have the data saved, then it’s time to get the Synology device ready.

Log into your Synology device and do the following:

Go to the CONTROL PANEL and click WEB SERVICES.
Make sure you tick ENABLE WEB STATION and also ENABLE MYSQL.

Voila_Capture5

Go to the PACKAGE CENTRE.

Install phpMyAdmin and then WordPress.

Voila_Capture6

If you go to FILE STATION you should see a folder called WEB, and in there are the various folders that have been created to let you do your own thing.

Voila_Capture7

The WordPress folder is the default one that is created, and you can safely use that if you are just starting out learning WordPress. If you muck things up you can just uninstall WordPress, re-install and start again. Sorry about that.. let’s get back on track again!

Create a folder under the folder WEB and call it the name of the site you are looking to import. As an example, my site of http://www.tasystems.org will sit in a folder called TAS. You can call it anything you like.

Go back to the Control Panel, click on Web Services again, and then click on VIRTUAL HOST. Click on create, and enter the folder name you created earlier. The hostname should be set to local. Change the port to 81 or whatever one you prefer. (You can change the hostname to your WAN ip address and port to whatever you want, if you wish to access this site from the Internet. You will have to set up port forwarding in your router for this work correctly.)

Voila_Capture8

Now go to phpMyAdmin, and at the top, click on DATABASES.

Voila_Capture9
Now you need to create a name for the database, so I’ll stick with tas as that is the folder I’m working in and an abbreviation for the site I have live. Just click create.

Now, go to http://wordpress.org/download/ and download the latest version of WordPress. Once it is downloaded, unzip it and it will create a folder called wordpress. Go inside that folder and copy everything from it, into the new folder you created.

You can check to see if things are working by typing in:

http://synology_name_or_ip_address/wordpress for the standard wordpress site.

http://synology_name_or_ip_address/name_of_folder_you_created and the new site should appear, but it will tell you that there is no wp-config.php file available. That’s fine, but just ignore this, as we are not interested in creating a new site.

Copy the installer.php file and the package file you saved at the start of this, into the folder you created in the web folder of the Synology device.
Note: In this screenshot you will see I have the original wordpress zip file in the folder. Makes sure you don’t have that there as having another zip file there will cause you problems, but you will get warned about it if it does happen.

Voila_Capture15

Once this has been done, go to your web browser and type in:

http://synology_ip_address/folder_you_created/installer.php

Mine’s as an example is: http://omega/tas/installer.php

If everything has been done correctly… you should see the following below:

You will see that I have a Green light indicating that the system has passed the first phase, and is looking good.

Voila_Capture16
Now you need to fill in your settings and then click on TEST CONNECTION!

Voila_Capture17

If all goes well… you should see this next:
Voila_Capture18
Now click on the option “I have read all warnings & notices” and then click on RUN DEPLOYMENT. A screen will then prompt you  to continue… do so!

Voila_Capture19

Now you need to wait until the files are copied across.

Voila_Capture20
If all goes well, you should see something similar to the screenshot below:

Voila_Capture21

The next part may not be needed, but I did experience a few issues trying to log into my site, so have included it anyway just so you can try it if you too have any issues.

Click the section that says NEW ADMIN ACCOUNT and create a new username and password.

Voila_Capture22

Once this has been done, click on RUN UPDATE. At the end you sill have a summary screen that will give you information on any issues found.

Voila_Capture23

Click on Resave Permalinks, and then finally click on Delete Installer Files.

After that… click Test Entire Site… and if all goes well… you have a fully working site now sitting on your Synology device.

I hope this will help someone out in some way, but would appreciate having mistakes pointed out and any way to improve upon this way of doing things. As it is, it works but I’m sure there must be some things that could do with improving upon!

UPDATE: 06-10-2013
One issue you may experience once the site has been transferred across to your Synology device is that the plugins will not automatically update and you will be presented with a screen asking for ftp details and a username and password. It makes no difference what you do here, the plugins do not want to update.

The way around this is simple as long as you go back in to the Synology device, go to the control panel, Terminal and make sure you have enabled TELNET SERVICE.

Next, you want to TELNET into the Synology device and log in with the username of root and the password you have set up for your main admin account. Once you have logged in, you need to issue the following command:  chown -R nobody:nobody /volume1/web/name_of_your_folder

Once this has been done, the plugins will automatically download and update when you select them.

Thanks go to PedroT over at the forum.synology.com site for this information: http://forum.synology.com/enu/viewtopic.php?p=75746

Advertisements

Posted on October 5, 2013, in How To, NAS, Opinion, Review, Software, Wittering and tagged , , , , , , , , . Bookmark the permalink. 18 Comments.

  1. Gordon excellent blog, worked a treat, i have 2 issues.

    1. when trying to delete the files
    Does not exsist or unable to remove file: /home/hutch1/public_html/installer.php
    Does not exsist or unable to remove file: /home/hutch1/public_html/installer-backup.php
    Does not exsist or unable to remove file: /home/hutch1/public_html/installer-data.sql
    Does not exsist or unable to remove file: /home/hutch1/public_html/installer-log.txt
    Does not exsist or unable to remove file ”. Validate that an archive file exists.

    2. when i click on the wordpress icon in synology, it directs me to the wordpress file = http://192.168.10.250/wordpress/. To gain access to the site, i simply have to change the file name to the one i created? what do i need to do to make wordpress go directly to the new site?

    many thanks
    steve

  2. Hi Steve,

    Your first question has me a little confused. At what stage are you getting this error message?
    I can see that whatever is giving you that message is looking in the the HOME folder of your NAS, inside hutch1 and whatever it’s looking for does not appear to be there. If you use file manager and go into that folder, you should be able to check and see what is there and either add or remove the material manually.

    The second question, is simpler to sort! When you initially install WordPress onto the NAS box the system creates a default WordPress folder inside the web folder on the NAS. If you click the icon, it will then take you in there. To be honest, the way that you would normally connect to any WordPress site on your has would be be to just enter http://NASNAME/folder_that_wordpress_is_installed and it will connect. As an example, one of my NAS boxes is called OMEGA, and I have a folder called test inside the web folder that I use for testing, so I would enter: http://omega/test/wp-admin and this would take me to the main admin portal to log in and do any work to it.
    If you want the WordPress icon to automatically go to a site you have created, you have to be working in the WordPress folder for that to work, so any themes etc would have been installed into that default folder.

    I hope that makes some sense, and if not, please get back in touch and I’ll do my best to assist!

    • wow thanks for the quick response.
      Let me explain, you are talking to a complete novice (if you hadn’t guessed already!)
      After wasting copious amounts of my time and money on “web developers” and getting zero results, i decided to build my site myself.

      just before i found your blog i had issues with Maria DB (mysql), after grappling with it, i simply uninstalled/re installed Maria DB and phpmyadmin. The original DB folder of the site was Hutch1, in my ignorance, i simply created a new DB folder name and loaded everything into it, i think that’s why the files cant be found ?

      The site works fine on the NAS when i type in the folder name, as i mentioned it would be nice for the WordPress icon to connect to the new site and not the “wordpress” folder. No big deal unless, i have to explain it to a “web developer” 🙂

      thanks again for your time and blog, keep up the great work.

      • Not a problem!
        The manual creation of the DB folder is what has caused this issue….
        If you accept the defaults of the DB and then log into the phpMyAdmin app, you will see all of the databases that you may have created in here.
        A WordPress developer would not use the front end of the has WordPress logo to do anything, he would always just log into the has using a web browser, unless of course they wanted to create a working site on the NAS for you and needed to create the database side of things, and then the other tweaks required to get the NAS 100% operational.

        This is the sort of thing that I could probably show you remotely easier than typing, but the modified tutorial over at http://www.tech-reality.co.uk may offer a bit more information to you.

        Either way, if I can help you in any way, please get in touch!

  3. For more information and updates please go to: http://www.tech-reality.co.uk as this is now my main site for all reviews and tutorials that I do.

  4. Hi Gordon, thank you for this tutorial. But I’d like to know if the same procedure applies to this concern I have: I have a wordpress site running on my present synology device and I’d like to move it to another synology device. Do you know how I can move it there in a more simpler way or would this tutorial do the same thing? Your reply is greatly appreciated. Thanks!

    • It’s pretty straight forward. Just make sure you have all the same applications installed and running on the other NAS box, do a Duplicator backup, drag the two files into he web folder on the other NAS, do the install and that should be it! If you do have any problems trying this out, please get in touch and I can help you out. To be honest, its better to use my main site rather than here now as I don’t update this at all.
      http://www.tech-reality.co.uk

  5. There are several issues with this approach. WordPress will reside on your Synology, but the integrated DSM functionality is lost. The NAS will have no knowledge of your custom WP folder. Updates to the DSM or related packages run the risk of breaking your site. Good luck getting any help from Synology tech support which is already below par. The WP package from Synology is custom built for the NAS. It has integrated security, updates and access to PhotoStation. However, there are advantages to your approach such as multisite capability, quicker access to WP updates and more control over the installation. Thanks for an excellent and very thorough tutorial. My knowledge of the Synology is rudimentary and I welcome any corrections.

    • Thanks for the feedback, its always appreciated, more so that I’m not an expert with WordPress on the Synology NAS units, but I do have a fair understanding on how to go about getting things up and running on it.

      I’m a little bit confused about “the integrated DSM functionality is lost” and what that implies?

      For me, the idea is to be able to work on a new WordPress site created on my NAS, by creating a new folder etc, and then installing the latest version of WordPress from the Internet. That would be installed into the new folder etc, so there is no interaction at all from anything on the NAS side required, via plugins etc except for the database side, and that seems pretty standard. All the plugins and even WordPress itself update without any problems, so again I’m confused on the issues you say are there?

      What packages would you say are capable of breaking the site that are on the NAS itself? Information about this would be good so that I could look into this at a later date.

      When I have worked on a site on the Sinology device, I use Duplicator to upload the site straight to a hosted site and thing just function perfectly ok, and as yet, I have encountered no issues whatsoever.

      At the moment, I have never had the need to contact Synology support, and I have read a mixture of reviews on it… I just hope that when the time comes for me to need help, I find them fast and helpful!!

      Once again, thanks for the feedback, I hope you can enlighten me on the items you mentioned in case I am missing something that should be obvious to me!

      • I don’t know the full extent of the Synology WP package core modifications for DSM integration. It would be a great question for support. I know you can interoperate with PhotoStation via a Synology plugin. I would hope that the Security Advisor would also monitor the package. I’ve had breaking issues with a non-WordPress Synology hosted site due to DSM changes to user and service permissions. I’d worry about an update to the Maria dB package but as you said it is pretty standard. I’m not disagreeing with your approach in fact after further review of the Synology forum, the opposite of what I suggested may hold true. That is Synology may be more likely to break their own package, because they have in the past. In general from an IT perspective, I think it is always preferable to go with a supported approach. However, there a numerous advantages to the contrary such as immediate access to WP core updates, easier migration and less likelihood of issues due to core mods. Thanks again for your feedback. This discussion is very helpful, because I’m about to deploy my first WP site.

      • I only use the main WordPress features of the Synology device, and do not integrate anything from their own application into my site. The way I use the NAS is to work on a variety of WordPress sites, and when Im happy with them upload them to the Internet and thereafter, the work is done there until such times I decide to do a Duplicator backup and then re-install that backup to the Synology device for further work etc.

        If you are looking to host your WordPress site on the Sinology NAS box and then push that out to the Internet as your live site, then I can see there may be issues (bandwidth of you current broadband being the main one) but my use is more a development/testing rather than live.

        As you say, its good to discuss these features as I feel that too many people work on a variety of material and never take the time to share what it is they are doing, and to me that is quite sad as newcomers (like me) can learn so much more and in turn pass that knowledge onto others.

        I hope your new sites goes well and would love to check it out once its completed.

  6. My wordpress account is free site I have no way of intalling a plugin. Any ideas?

    • To add all the plugins etc you will need to host your own WordPress site on a NAS or on some other host as the free WordPress sites don’t allow you to do much other than just have the basics I’m afraid.

  7. Thanks Gordon for your clear explanation from the transfer of a wordpress site to my local nas server I had one problem which I could solve by the explanation in this url “http://www.fogma.co.uk/foggylog/archive/386.html”

  8. Hi,

    I run a webshop and staging website online, but I’d like to run the staging version on my nas.
    I can’t use duplicator because the database, number of files and images are too big.
    Can I just copy all the content from my FTP site and put it in the WP directory on my NAS?

    How can I correctly name/install/setup the database?

    • You can backup your main WordPress folder off your hosting site, and also do a backup of the backend database.
      All you have to do is create a new database on the NAS, copy your content into a new wordpress folder on the NAS and then just restore the database into the NAS using phpMyAdmin. The Duplicator way is so much easier though!

  9. If you’re adept at the unix command line and easier method is with this simple script..
    pretty simple script that does what you want, backups wordpress files + database to an offfsite nas server.
    http://www.abrandao.com/2017/07/backup-script-wordpress-offsite-nas-via-rsync/

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: