The Dreaded Web Host Manager

The next to last paragraph in the first article on this subject went like this,

Going hand in hand with Cpanel is WHM, the WebHost Manager (this will be important in the next section) Their user documentation is here and here. If your web host uses Apache they are most likely going to be using Cpanel and WHM as the control panel and manager for the hosting service. Once you have signed up with a web host you are now dabbling in web hosting, at least vicariously. WHM is your best friend when managing a web host. You should probably get to know your new best friend better.

If your site is part of another site, you might have more to do than just trying to break your new web host’s software. You have real work to do breaking other stuff first. Before doing anything else, even if you have a completely new site, you should probably make sure that you have a clean backup of your current website. This is the kind of common advice that gets a well duh response, but every time there is an unrecoverable oops event, it is because someone ignored the well duh advice. Backing up isn’t the easiest thing to do with a hosted web account. It isn’t easy because a simple duplication of your online files will not give you something that you can restore your site from. Backup in cpanel requires you to backup your files and databases separately if you want them to be available to be used to restore an oops event. So do a backup, and then keep reading.

No, Seriously. Backup!

Done? Good. So now you want to create your new website, right? A personal place all your own to host your blog on. You want to create a separate web site because you are borrowing space from a lifelong companion not known for her neat, organized workspace (Ouch! Don’t throw things at me! It’s true and you know it!) and you’d like to know what part of this mess is yours to deal with. This will require you to access WHM, the WebHost Manager. Since you are creating an account for yourself (or myself, in this case) be generous. But don’t worry, you can change the package and account settings later. As is typical with linux GUI’s, some of the settings will say they have been changed or can have particular values, but the implementation of the setting may fail because of limitations that your web host places on your account. This is the one bright point about hosting for yourself, the thing I told you that you didn’t want to do in the first installment of this series. The only bright spot in self hosting, being able to set any hosting variable to any allowed value. This isn’t necessarily a good thing.

Make sure that autoSSL is included as part of the feature set of whatever package you end up creating. SSL? Secure Sockets Layer. It allows you and your visitors to establish an encrypted connection between the two of you. AutoSSL generates a certificate for you at your new hosting location, so you will want it enabled. If it isn’t, you will not be able to be certified as an HTTPS location on the web, and that is bad on today’s internet using todays browsers. WHM will generate an error if you set your bandwidth to unlimited and disk usage to unlimited when you set up your package, and this error will keep you from successfully creating an SSL certificate. You can set the bandwidth to 100GB if you want (one hell of a lot of data) It just can’t be unlimited. Like I said, not a good thing to be able to muck about with all the settings.

Once you have your package set up the way you want it, the way you are allowed to set it up, create your account from the create new account tab on the sidebar menu. Select the package you just created. If you followed your web hosts rules correctly it should show as green and selectable. If you aren’t planning to resell or offer to piggyback your needy relatives on your web host, you can skip package creation and just go straight to account creation. When you get to the menu for “select package” simply toggle the Select Options Manually checkbox, and you can piss off your web host all over again by selecting values that aren’t allowed while simultaneously creating your account. This will save you the trouble of trying to figure out what your web host will allow while creating the package that you will only need once anyway, but you won’t get to give it that special name if you don’t create the package in advance. For me, naming is important. You may be content to let someone else pick the names you use. To each his own.

Get the important stuff right! Check the domain name. Check the user name. Write down the password. Make sure the email address is a working email address. The only default setting that I needed to change on our web host was toggling the recommended setting for mail routing to Automatically Detect Configuration because, again, if if the host can find it, it will find it. If not, you can always figure out what it is later. Hit Create and you are done.

Now comes the fun part, and when I say fun I mean tooth extraction levels of pain. But fun, you know? Since you are migrating your (my) wordpress installation, you’ll have to duplicate the SQL database that makes the installation do what it does in its current location. SQL? Sequel. Structured Query Language. You don’t really need to know what it does (but the link will tell you all about it) you just need to know that you need it. If you only copy the files from the software installation that you are migrating, you may or may not notice parts of your installation working the same way later. You’ll need to access PHP admin. PHP? It’s yet another scripting language (see? Fun!) PHP stood for Personal Home Pages back at the dawn of time, but now stands for Hypertext Pre-processor. I think we’re up to version 7 as I type this. I seriously couldn’t care less. I wish I could work up to caring at least a little. Trying to make Linux work for a decade burned me out on caring about coding, one failed install at a time. AutoCAD Lisp was a walk in the park next to getting Linux to run on mystery hardware. Now I just want the software to WORK, DAMMNIT! I want it to work pretty much 24/7 without my having to do anything about it. It’s enough to make you wish you had the money to pay Squarespace to do this all for you. But I digress.

Accessing the PHP manager will allow you to copy out your SQL commands so that they can be applied to your new account. You’ll want to follow the directions of your web host for doing this. Just make sure you verify which SQL command list is associated with your current install beforehand, then go to the PHP manager, highlight the right one (not expand it) and make sure that, add DROP TABLE/ VIEW/ PROCEDURE/ FUNCTION is selected. This should be in the options section. Export as SQL. Next you will go into your new account, use the SQL wizard to create a new database, associate the database with the user for the account, and then import the SQL file you downloaded earlier. Wipe the sweat off your brow, because that was the hard part of this process.

Time to export all those collected years of hard work. Don’t slip up! Grab your current install of WordPress from the directory that it is in. It should be about twenty-two files, four of which are folders, including one named wp-content. Once you have located those files, zip them up through the cPanel file manager interface, and download them to your local drive. Then you open your new account, go to the file manager, and upload the same zip file to a directory there. I suggest using the tmp directory. That is what temporary directories are for, things you will delete later. move the files and folders from where they land in tmp and paste them to the public_html folder. Verify that the file and folder structure matches your previous files and folders before doing anything else.

Now it is back to coding, again (I’m sorry) You will need to edit your wp-config file in order to modify a few commands so that they point to the new SQL database. This is where writing down your username, password and SQL command list name comes in handy. Open the wp-config.php file in a text editor, like Windows notepad or the native editor in CPanel. Scroll to the lines in the file that say DB_NAME, DB_USER and DB_PASSWORD and then modify the SQL database name username and password with the information that you wrote down previously. Because you wrote it down like I said, right?

Put on your dunce cap, because it’s time for a test! Don’t Panic! This is a website test, you won’t have to cram for the exam. To conduct this test you will need to modify your WordPress config file in the new location, similar to what we did in the last paragraph. There are other ways to test the configuration including logging into the wordpress installation directly and altering the file storage location in settings, and modifying the SQL database to point to the new location, but the test method I chose was modifying the wp-config.php file because I was in that file already. Insert two lines into the code that read as follows, replacing yoururl with the URL that your new installation is currently residing at.

define('WP_HOME','http://yoururl');

define('WP_SITEURL','http://yoururl');

After you do that go back to your original installation location and backup the existing WordPress installations wp-config.php file. After you do that replace the wp-config.php file with an empty text file by creating a new file with that name. This is just a test, and if you backed up like I told you to, you can always revert to the correct wp-config.php if the test fails. Then open your browser and type in your test URL and click on a few links to make sure that everything displays properly.

Nothing sideways? Everything where it is supposed to be and working correctly? Great!

Once you are satisfied that the new installation is working correctly, you can reedit the new locations wp-config.php with your real URL name, and then redirect your URL to point to the new location on your web host. You do this from within CPanel in your old location, deleting the URL from the Domains menu, and then adding the URL to your new location. Once you have successfully moved the URL to your new web host location, you are done. Log back on your site and bask in marvel of your unique genius and programming wizardry. Unless of course, the site doesn’t come up like it is supposed to. If not, go back through the steps and make sure you hit all the points correctly.

If all else fails, even the cheapest of web hosting sites will have some form of chat available to paying customers. Log on the chat and see if they can help you. Just don’t panic. It’s just electrons whizzing around in space. It isn’t the end of the world if the website is down a few days. You’ll get it back up because you made a backup, and you didn’t delete the old installation yet.

Wait. You did make a backup, right? Oops?


If you work with writing text online long enough, and if you don’t want to sign away the rights to your product by just typing it into Facebook or Twitter or one of the other corporate properties squatting on the internet these days, then you are going to run into the need to work on your writing from anywhere and on pretty much anything with a monitor and a keyboard.

Keyboards are essential for thinking. That is my version of only being able to design with a pencil in your hand, the last generations response to my insistence that I could design on a computer. A hundred years ago it would be a pen was required for thinking and a hundred years before that it would have been the quill is required for thinking. The next generation will insist that haptic gloves and an immersive 3D environment are required for thinking. The generation after that will just be directly interfacing with their tech and won’t understand the point of this paragraph at all. Thinking just happens. What do you mean you need a tool to access what is always there all the time?

In the meantime the internet disappears on occasion and you still want to work. You want to design something new and keep it from the public eye until it is ready to be seen. What you want is a local installation of your web interfaces. What you want is a personal web host manager that you can manage for yourself.

If you are trying to do a local installation of WordPress then you will need your own version of a web host manager, one designed for installation on a private system and managing only the websites that you host for yourself. That is, if you have the forethought to do your editing locally rather than in the cloud in the first place. In which case when the internet disappears, so does all your work. Until it comes back. Yes I’ve been cooling my heels a lot lately, why do you ask?

The Wife pointed me in the direction of WP Beginner as a resource that she tapped frequently while learning the ropes of designing websites with WordPress. When I searched on their site for pointers on how to set up a local version of my website for editing and testing purposes, I discovered that their number one suggestion and WordPress’ number one suggestion were the same.

So I installed Local (formerly Flywheel) on my editing computer and then struggled to get an archive of the website built that could be read by Local. Every attempt failed until I also installed the WP Migrate plugin into my WordPress website. The archive created by WP Migrate loaded easily, if not completely accurately. It seems that naming your website differently than your online website will break the established page setups within your WordPress installation. I’m fiddling with that confounding factor now. It is very important that you don’t name your local sites exactly the same as your online websites. This much I know for sure because I’ve now screwed up the security setting on my web browser by trying that. Deleting the local site and restarting the system corrected the error. On to the next thing I can break.

There’s also the problem of usability when it comes to putting Local and WP Migrate together since WP Migrate will require an annual subscription in exchange for being allowed to port changes between the two installations seamlessly. You can’t even use WP Migrate Lite to import anything into an existing site, even to use WP Migrate to put data into a testbed that already exists locally. This makes the name WP Migrate a lie in that you can’t migrate anything from one host to another without paying them. WP Migrate Lite should more properly be named WP Backup, and it would suck as a backup even then because you can’t properly restore from that backup without paying someone to let you do a restoration. I’m removing the plugin as I type this.

You can import an Updraft Plus backup into a fresh install of WordPress on Local. My first barrier for creating a local testbed is going to be the 1,000+ bad links in the existing site. I’ve been working on this problem for three years, ever since the rage incident that stimulated the creation of this post and the other WordPress blogging posts, if not the move to WordPress itself which was a little farther back in time than 2020. But not much (Damn you, Blogger!) The Broken Link Checker is a plugin that every WordPress site should probably be running. Discovering the plugin has seriously increased my faith in the stability of the current site, even with all its errors.

I have discovered the problem with just duplicating the site locally. Because the local site can’t be distinguished from the live site, none of the automation that makes a modern website work so seamlessly can be relied upon in a duplicate testing environment; essentially, the duplicate finds the live site and uses its resources as its own. This will require a migration script to be run on the SQL database, changing the links in the code to point to the local test bed (a fact that website coders have probably been aware of for decades, and I just discovered today by purposefully breaking things. Again) This is why the bad links will be a problem for creating a local testbed. If the links already don’t work, they won’t be redirected to the new migration site, either. Also, I will have to pay Updraft Plus to run the script as part of the migration to the new local site. This makes them useful as a backup/restore tool and a migration tool if you are just moving your website to a new host, but useless for making your desire to edit locally a reality.

The all-in-one WP Migration tool will indeed export a migration to file for free; however importing a site over 300 MB will incur a cost. Exporting to something other than straight to file will also incur a cost. I get it, interoperability has to be maintained. That means it costs money. However, the artificial limit of 300 MB to import a site is entirely a trap intended to get the unwary to pay for something which costs the programmers nothing over the cost of just programming the plugin in the first place. Here’s some advice for you programmers; if you want someone to chip a few bucks in, say so up front. Most people will throw a few bucks at you. Surprising someone on the backend with a surcharge is just another confidence game; and anyone who will play confidence games with me is someone I won’t trust with the keys to my data. Goodbye.

Testing continues.

Author: RAnthony

I'm a freethinking, unapologetic liberal. I'm a former CAD guru with an architectural fetish. I'm a happily married father. I'm also a disabled Meniere's sufferer.

Attacks on arguments offered are appreciated and awaited. Attacks on the author will be deleted.

%d bloggers like this: