• This is more of a general question rather than something specific.

    I have a pretty large WordPress website. At any moment is has about 200 active users on the site downloading files and chatting etc.

    I’ve been maintaining it for years and have now developed a custom plugin to help with many custom-needed admin features and backend/frontend functionality, not to mention a good complete overhaul of the theme and widgets and pages etc.

    It’s a big change that involves a LOT more than simply enabling this new custom plugin…
    To implement this “update”, I have a large notepad file of many things I need to do. Disable old plugins, change pages, add new roles, etc, etc… All in a specific order. It will take a solid hour of tediously making sure everything is going smoothly.

    Here’s what I’m worried about – what is the best way to seamlessly do this?

    PERFORM UPDATE LOCALLY AND COPY DATABASE TO LIVE SITE?

    Is this a good idea? I’m already working on a local version of my site but I don’t know how “compatible” this would be, to take my working copy of the database from my local version, and clone it on my live site (I think there are minor differences in phpmyadmin/mariadb versions or something for example, is this gonna screw me?).

    Process would be:
    Clone live site onto local installation on that day
    Make all of my changes and implement my new plugin/system while on the local installation
    …But then what? How do I get this local DB onto the live site seamlessly?

    Should I make a second NEW database on my server and take this local database clone, put it there, and then when I’m ready, change wp-config.php on the live site to point at the new database. Is this safe or could things go horribly wrong? I mean this as, is simply changing the database name in wp-config going to possibly nuke my entire world or-

    It goes without saying I would backup the original live site DB and files beforehand.

    Basic advice on how to manage such a task is appreciated. Excuse me if not the best forum for this, I figure we’re all WP developers so-

    • This topic was modified 4 years, 8 months ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Developing with WordPress topic
Viewing 4 replies - 1 through 4 (of 4 total)
  • I think the answer depends on how much the users change the database.
    If the users are leaving comments or content, then you will need to make your site read-only for the duration of the live capture/update. If the users don’t affect the database, you have more choices.
    You can use a migration plugin to move your site from your local testbed to the live site.
    You can clone it to a folder on your site, and when ready, you just switch the config.
    You can break the changes into manageable pieces that are easier to implement while users are there.
    You can use a plugin to show a “Maintenance” page to all users.

    Thread Starter FTLRalph

    (@ftlralph)

    @joyously Yes I forgot to mention. I’m “willing” to lose a little user content for the small period of time. I’ll use a maintenance mode plugin as well, though in past experience (and I don’t know how) a very small selection of visitors get by it. Whether it be because they were already on the site or what, but I can see activity on pages within the site (very, very minimal, but it’s there).

    Anyway. I’m leaning towards
    1) Cloning the site locally
    2) Performing all plugin/widget/page/layout/DB changes
    3) Cloning THAT DB onto a second DB on my LIVE server
    4) Changing wp-config.php on live server to point to “new” DB

    I’m just concerned
    1) Compatibility with exported DB from my localhost to live server. I’ve gone from live server -> localhost but never the other way around. While my phpmyadmin / MariaDB versions are close, they’re not identical.
    2) Worried WP might think it’s a new installation once I change wp-config “for some reason” (never know with this stuff)

    But I think that’s my cleanest option.
    Again, any input/advice from people that have been there done that is appreciated. I’m still planning for this in the upcoming week.

    When you say “cloning the DB”, what do you mean?
    When I say it, I mean use a migration plugin, which will ask you for what is the domain name change to make in the exported database. It exports to SQL, so the version number doesn’t matter, and you can even go from Maria to something else.
    When I say to install WP in a folder, I mean another entire installation of WP, not just a second database. You can have both live at the same time, and switching the subfolder to control the root is easy (the link for instructions is even in the main Settings page). It’s pretty simple to switch, and you can test it on the live site before switching.

    Worried WP might think it’s a new installation once I change wp-config

    The only place that WP has to look for the options is in the database, although there are a number of directives you can set in code using define(). The option for whether this is a new site is stored in the database, though. It’s named fresh_site.

    Thread Starter FTLRalph

    (@ftlralph)

    @joyously Thanks for your replies.

    “Cloning the DB” what I mean is I export the database from phpmyadmin. I then go to my local server via WAMP and import it into a blank DB. Connect a new WP installation to it, and the site is cloned. Using my hosts file to redirect mydomain.com to localhost I can emulate being on the live site.

    I’ve done this many times. So what I’m proposing here is I’d do the same, but in reverse.

    After doing that ^ and making all of my changes locally, I’d export from phpmyadmin again, upload this DB to a second/blank DB on my *live* server, and once complete, simply point wp-config.php on my life sit to this new database which should be identical+my changes.

    It’s essentially a migration plugin, I just don’t trust a migration plugin. There is a LOT of data and finicky plugins and I really don’t even want to introduce WP in a new folder, even if temporary, as I can see that borking permalinks and everything.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Attempting to Update (Big Visual/Plugin Front-End) A Large Site – Best Way?’ is closed to new replies.