Zen Cart Logo
Forums / General Questions / Moved To New Server, store Not Working

Moved To New Server, store Not Working

Views: 3,010

Results 41 to 43 of 43
17 Feb 2015, 3:01 PM
#41
rodg avatar

rodg

Deceased

Join Date:
Jan 2007
Location:
Australia
Posts:
6,263
Plugin Contributions:
4

Moved To New Server, store Not Working

DK_Scully:

I've done a fresh install four different times. I'm sure I'm only missing one very small piece of the puzzle...

It appears that your 'missing piece' is what you are doing with your config files, but we don't have any idea of what you are doing different from the instructions.

DK_Scully:

because you're right, I'm not stupid. But no matter how many times I read the instructions, I'm not seeing what that one piece is.

After you've done a fresh install you'll have two 'sets' of configure.php files. The newly created ones, and a copy of the original ones, correct?

Exactly what steps are you taking from this point? Replacing the 'new' config files with the old copies and editing them, or are you editing the newly created config files?

DK_Scully:

I've been told that HostGator will move everything on the old server for free,

Many webhosts will do this, especially if both the original and destination host both use cPanel.

Just because the'll do this though is no guarantee that the'll end up giving you a working website because as you have discovered there is a little more to it than simply copying the files and database. It still needs to be correctly configured for the new site, and many hosts won't help with that on account of the fact that they consider it to be an 'application issue' and outside the level of support they offer.

DK_Scully:

since my new account with them (I moved from the reseller server to the shared server to save money)

Although this is probably OK (on account of the fact that most reseller servers are subject to the same limitations as a shared server) you should be aware that if/when the site(s) start generating a lot of traffic most shared server hosts will threaten to suspend the account unless you reduce the server load, and they'll expect you to do this by 'selling' you a VPS.

I'm probably no telling you anything you don't already know though.

DK_Scully:

If what I was told is true, I'm going to let them do it,

Nothing wrong with that. If they do manage to give you a functional site though, if I were you one of the1st things to do would be to take a look at the config files and compare them with the changes that you've been making. Quite often once you see the differences the reasons for your failed attempts will become quite obvious and this will help you with future moves/changes, etc.

DK_Scully:

and stop beating my head against the wall. Life's too short for this kind of stress.

Yeah, this should have been solved 30 odd messages ago. This is no reflection on you though. It can take a bit to come to grips with the config files, and with as many sites that I've set up and/or moved I still often make mistakes and mess up the first time around.

Cheers
RodG

19 Feb 2015, 4:27 PM
#42
dk_scully avatar

dk_scully

Zen Follower

Join Date:
Jan 2011
Posts:
339
Plugin Contributions:
0

Re: Moved To New Server, store Not Working

The suggestion about downloading the configure.php files from a site that's already been migrated was brilliant, thank you! I managed to figure out the biggest problem from there:

'/home2/boruma/public_html/book-oasis.com/' is what I needed.

Somehow I was looking at the line about logs, and missing the one above it for catalogs.

Now the login page and default green template are showing up again. That's a huge step forward, imho...and now I know exactly what to look for, because I copied the entire configure.php file into a Word document, and color-coded where the changes were. :D

Now...I did a full backup while I was working on the site development, then I did another one a few weeks later, just to make sure I had the most recent data. I downloaded it to my PC.

The database boruma_oasis exists on the new server. I've confirmed that boruma_oasis is also what's inside my configure.php files. I've looked at phpMyAdmin, and clicked on that database, and a whole bunch of stuff has come up...but I don't have a clue what to do with it, so I haven't touched anything. This is the new database I've recreated four times, correct? And I want to overwrite it with the database from the old server. Right? Just checking to make sure I'm understanding where I am and what I need to do.

So I've gone to Backup Wizard, and clicked Restore Database, then selected the backup file on my PC. And it says it's restoring the database. But then...nothing. It sits and sits and sits, and nothing ever changes on the site. The last time I tried doing this, a couple of weeks ago, it sat for several hours, and nothing ever happened. That's why I figured I must have done something wrong, and started asking for help...and got totally bolluxed and made things worse than they had been. Thankfully I'm at least back to Ground Zero again.

How long should this be taking? The database is very small, because no real data has been entered yet...the site's still in development, and all I'd done was change the template and added a bunch of categories. It's already been sitting for half an hour with no changes.

Am I missing some other small but crucial step?

Thank you so much for your continued patience, and kindness with my fumbling ineptitude. If you knew how far I've come since I started working with ZenCart... Doesn't feel like it very much right now, though. :dontgetit

19 Feb 2015, 5:54 PM
#43
rodg avatar

rodg

Deceased

Join Date:
Jan 2007
Location:
Australia
Posts:
6,263
Plugin Contributions:
4

Re: Moved To New Server, store Not Working

DK_Scully:

Now the login page and default green template are showing up again.

I assume you are still missing your categories as well?

DK_Scully:

because I copied the entire configure.php file into a Word document, and color-coded where the changes were. :D

I'm sure you've done this OK, but you should be warned that you should never use 'Word' (or any other word processor) to edit any of the ZenCart files. This will cause problems (unless you strip any and all embeddded control characters and save the file as plain text).
Best avoided.

DK_Scully:

Now...I did a full backup while I was working on the site development, then I did another one a few weeks later, just to make sure I had the most recent data. I downloaded it to my PC.

Was this a "cPanel" backup or a database backup via some other means?

DK_Scully:

The database boruma_oasis exists on the new server. I've confirmed that boruma_oasis is also what's inside my configure.php files. I've looked at phpMyAdmin, and clicked on that database, and a whole bunch of stuff has come up...but I don't have a clue what to do with it, so I haven't touched anything. This is the new database I've recreated four times, correct?

I can only say probably correct.

DK_Scully:

And I want to overwrite it with the database from the old server. Right? Just checking to make sure I'm understanding where I am and what I need to do.

You probably have two options here. Yes, importing the old/original database is one approach you can take (but you'll probably need to edit the .sql file so that the import goes into the new database. This will be required because as you have previously told us, the database name has changed between the old server and the new server.

The second option may or may not be possible if the host has placed a restriction on the database names that they allow.

DK_Scully:

So I've gone to Backup Wizard, and clicked Restore Database, then selected the backup file on my PC. And it says it's restoring the database. But then...nothing. It sits and sits and sits, and nothing ever changes on the site. The last time I tried doing this, a couple of weeks ago, it sat for several hours, and nothing ever happened. That's why I figured I must have done something wrong,

There's two possible causes for this (perhaps more). The first is very common if your database is quite large.. it is the site timing out before the restoration can be completed. The second being is the name of of database being imported has a name that is dissallowed by the server. I honestly don't know if this will cause the 'sits and sits and sits' that you are describing, or whether the backup thingy can somehow manage to rename the database to one that is compatible for your server.
The reason I don't know is because I never use the cPanel backup wizard for site migrations. That isn't what it is really for.
This is why you will probably need to edit the .sql file within the cPanel backup file so that the database name matches the name used on the new server.

DK_Scully:

and started asking for help...and got totally bolluxed and made things worse than they had been. Thankfully I'm at least back to Ground Zero again.

Yes, you ARE back at 'ground zero again, but apparently no wiser than you were when you started this thread.

DK_Scully:

How long should this be taking?

In all seriousness, to do a backup of the original site, a fresh install of zenCart, and importing the original database, probably no more than 10-15 minutes.

DK_Scully:

The database is very small, because no real data has been entered yet...the site's still in development, and all I'd done was change the template and added a bunch of categories. It's already been sitting for half an hour with no changes.

To be perfectly honest, this being the case, have you considered simply re-creating the new categories and reselecting the original template?

Or would you prefer to persevere for the time when you need to move a heavily populated site?

DK_Scully:

Am I missing some other small but crucial step?

You are missing a couple of things (mainly experience) <g>
I think the 1st thing you are probably missing is the way you did your site/database backup. I'm sure that none of the Zencart upgrade/migration instructions would suggest that you start out with a cPanel backup.

The second thing you are missing is an understanding of Database names (and the limitations imposed by most shared hosting companies).

Do you still have access to the old site? If so, log into it, and follow these instructions to download just the database.
http://www.zen-cart.com/content.php?144-how-can-i-do-a-site-backup-or-use-phpmyadmin-for-database-backup

If you don't have access to the old server you will need to unzip the cPanel backup and extract the .sql file for the site.

When you have this .SQL file on your local computer you will need to open it in a text editor, and somewhere around line#20 there will be a line that reads like:

-- Database: '*oasis1_bookstore' * (this is the original databse name)

Change this line (and no others) so it reads
-- Database: 'boruma_oasis*' * (or whatever the name of the database is on the new server)

Save the changes and re-zip just this .sql file (I say this in case you needed to unzip the entire cPanel backup)

You final step is to log into the new server, and using Phpmyadmin select the 'import' option, select the edited file, then wait one or two minutes. (its pretty quick). Take note of any errors that may pop up and report them to us before messing with things that could make moving forward even more difficult).

All being well you should now have a fully functioning store with all the original data.

Good luck. I'm off to bed (4:30am)
RodG