PDA

View Full Version : Database Error after changing to new web host?? SITE DOWN


obglobal.net
12-10-2013, 11:26 AM
Really in a spot of bother here. Everything was executed as requested by the new web host at my end, but I'm stuck with a Database Error whenever attempting to access my forum.

I got this message from the tech staff at the web hosting site:

I could see the files in your account. Also, website at: http://obglobal.net/ is showing database error. However, I have created a connection string at: http://obglobal.net/test.php and its is connecting fine. So there is no issue with connecting to databases. Thus, you need to contact the application vendor at: http://www.vbulletin.com/support-forums/ to get more information on this issue.

● I thought I'd start at vb.org because everyone's so helpful. Could really use some guidance/assistance.

Thanks very much. :(

Disco_Dave
12-10-2013, 11:31 AM
Mite be a stupid question, but have you updated your config.php file with the database username and password?

obglobal.net
12-10-2013, 11:36 AM
Mite be a stupid question, but have you updated your config.php file with the database username and password?

As far as I go, no question is stupid, DD. No, I haven't done that, and I don't know how. I know how to locate the config.php as I've had to disable hooks before, but the actual edit itself is a new deal for me.

God I love this site.

EDIT:

I've just had a look, and it appears that the both of them have been edited correctly. Any other ideas?

Disco_Dave
12-10-2013, 11:39 AM
I would check your database username and password match the one on the new host:

// ****** MASTER DATABASE USERNAME & PASSWORD ******
// This is the username and password you use to access MySQL.
// These must be obtained through your webhost.
$config['MasterServer']['username'] = 'edit here';
$config['MasterServer']['password'] = 'edit here';

--------------- Added 1386679439 at 1386679439 ---------------

Have you updated your named servers?

obglobal.net
12-10-2013, 11:52 AM
I would check your database username and password match the one on the new host:

// ****** MASTER DATABASE USERNAME & PASSWORD ******
// This is the username and password you use to access MySQL.
// These must be obtained through your webhost.
$config['MasterServer']['username'] = 'edit here';
$config['MasterServer']['password'] = 'edit here';

--------------- Added 1386679439 at 1386679439 ---------------

Have you updated your named servers?

Yeah, they were solid.

Thanks for your help BTW, DD.

ozzy47
12-10-2013, 12:00 PM
Did you get any email with the error? Without the actual error it is impossible to know what the issue is.

Or possibly look in the server error logs.

obglobal.net
12-10-2013, 12:06 PM
No, I got nothing.

I've just noticed that I had 2 database files. One named vb and the other named vb_4 maybe that's the issue? I only uploaded the vb_4 one to the new webhost via FTP.

No idea.

Thanks, ozzy.

--------------- Added 1386680960 at 1386680960 ---------------

Did you get any email with the error? Without the actual error it is impossible to know what the issue is.

Or possibly look in the server error logs.

Sorry, ozzy. I forgot to ask where the server error logs are. Not sure where to locate them.

ozzy47
12-10-2013, 12:09 PM
Let's see if it is from a modification.

Open your includes/config.php file and below<?php add this line:

define('DISABLE_HOOKS', true);

So it looks like this:
<?php
define('DISABLE_HOOKS', true);
/*================================================= =====================*\
|| ################################################## ################## ||
|| # vBulletin 4.2.2

Then see if you can access your site. If you can, disable all your mods, remove the define('DISABLE_HOOKS', true); from the includes/config.php file, re enable your mods one by one till you find out which one is causing the issue.

obglobal.net
12-10-2013, 12:11 PM
I already tried that and no luck......

--------------- Added 1386681133 at 1386681133 ---------------

Thanks for the idea though man

Disco_Dave
12-10-2013, 12:12 PM
No, I got nothing.

I've just noticed that I had 2 database files. One named vb and the other named vb_4 maybe that's the issue? I only uploaded the vb_4 one to the new webhost via FTP.



Which one of these is named in your config file?

obglobal.net
12-10-2013, 12:18 PM
Which one of these is named in your config file?

I had to add a new database name with the new webhost. That's pretty much the extent of what I know.

Cheers

DemOnstar
12-10-2013, 12:45 PM
Did you create a new DB with the webhost and import your recent DB into it?

How about the user name with new webhost? All details correct?

Disco_Dave
12-10-2013, 12:47 PM
I had to add a new database name with the new webhost. That's pretty much the extent of what I know.

Cheers


If you want I could have a look, pm if your havin no luck.

DemOnstar
12-10-2013, 01:04 PM
Another thing, when you created the new DB, did you make sure that you created the new user and assigned the new user to the DB?

Lynne
12-10-2013, 04:15 PM
In your config.php file, make sure you have a valid email in this spot:

$config['Database']['technicalemail'] = 'dbmaster@example.com';

Then the database error should get emailed to you and then you can let us know what the real error is.

Max Taxable
12-10-2013, 04:33 PM
However, I have created a connection string at: http://obglobal.net/test.php and its is connecting fine. Actually, it's not.:)

obglobal.net
12-10-2013, 10:59 PM
Did you create a new DB with the webhost and import your recent DB into it?

How about the user name with new webhost? All details correct?

Yeah man.....All seems legit!

If you want I could have a look, pm if your havin no luck.

I PM'd you, sir. Thanks a lot.

Another thing, when you created the new DB, did you make sure that you created the new user and assigned the new user to the DB?

I'll have another look now, but I'm pretty sure I did

In your config.php file, make sure you have a valid email in this spot:

$config['Database']['technicalemail'] = 'dbmaster@example.com';

Then the database error should get emailed to you and then you can let us know what the real error is.

Thanks, Lynne. I'll give that a shot. Am I able to just add any email there??????

Actually, it's not.:)

I actually didn't check to see if that was the case. That's pretty lame. I'm beginning to wonder if I've picked a bad web host now. Damn it.

--------------- Added 1386720829 at 1386720829 ---------------

In your config.php file, make sure you have a valid email in this spot:

$config['Database']['technicalemail'] = 'dbmaster@example.com';

Then the database error should get emailed to you and then you can let us know what the real error is.

Here it is, Lynne:

Database error in vBulletin 4.2.1:

Invalid SQL:

SELECT IF(thread.visible = 2, 1, 0) AS isdeleted,



post.pagetext AS description,
thread.*


FROM thread AS thread




LEFT JOIN post AS post ON(post.postid = thread.firstpostid)


WHERE thread.threadid = 805 LIMIT 1;

MySQL Error : Table 'obgdatabase.thread' doesn't exist
Error Number : 1146
Request Date : Tuesday, December 10th 2013 @ 07:11:21 PM
Error Date : Tuesday, December 10th 2013 @ 07:11:21 PM
Script : http://obglobal.net/showthread.php?805-Knicks-at-Hawks-Wed-Nov-13th-8-00-pm-Dolan-guarantees-Win&p=10886
Referrer :
IP Address : 66.249.77.89
Username : Unregistered
Classname : vB_Database
MySQL Version :

Lynne
12-10-2013, 11:24 PM
If that is the error, then you've got real problems. It is saying the table "thread" doesn't exist. Can you see that table in your database?

obglobal.net
12-10-2013, 11:28 PM
If that is the error, then you've got real problems. It is saying the table "thread" doesn't exist. Can you see that table in your database?

Real problems? Oh no.

I'm not sure where to look for the database.

ozzy47
12-10-2013, 11:32 PM
In phpmyadmin you can look there, you should find that in cPanel if you are on a shared server, or in the WHM if it is a VPS or dedi server.

obglobal.net
12-10-2013, 11:32 PM
If that is the error, then you've got real problems. It is saying the table "thread" doesn't exist. Can you see that table in your database?

Is this what I should be looking at?

If it is, then the list stops at "template"

https://vborg.vbsupport.ru/external/2013/12/22.png

ozzy47
12-10-2013, 11:34 PM
Yes, do you see one named thread?

obglobal.net
12-10-2013, 11:38 PM
Yes, do you see one named thread?

No. It's all in alphabetical order, and the list stops at "template" as you can see:

https://vborg.vbsupport.ru/external/2013/12/22.png

ozzy47
12-10-2013, 11:40 PM
Then I believe your database is incomplete.

Do you still have access to the old server with all the files still on it?

obglobal.net
12-10-2013, 11:43 PM
Then I believe your database is incomplete.

Do you still have access to the old server with all the files still on it?

Just checking.

--------------- Added 1386722648 at 1386722648 ---------------

yes, I do. Next move? Thank, ozzy

ozzy47
12-10-2013, 11:44 PM
You are checking now, or something else?

obglobal.net
12-10-2013, 11:44 PM
Yes. Sorry.

Just checked and I can access the cp

ozzy47
12-10-2013, 11:44 PM
Ok, what type of server was the old one, and what type of server is the new one?

obglobal.net
12-10-2013, 11:47 PM
both shared servers

ozzy47
12-10-2013, 11:48 PM
Did the host of the new server do the import for you, or did you do it yourself?

obglobal.net
12-10-2013, 11:50 PM
I did it myself. Apparently it was an incomplete upload.

ozzy47
12-10-2013, 11:52 PM
I suppose you did it via a cPanel backup?

How big was the site, posts / members ect?

obglobal.net
12-10-2013, 11:57 PM
Via a cPanel backup is right, yeah. I uploaded the backup via FTP (FileZilla) to the new web host as a .sql file, and also uploaded all the files; admincp etc.

ozzy47
12-11-2013, 12:00 AM
I am not sure I can do anything, but I could try.

I would need you to PM me the cPanel info for the new and old servers, and the FTP info for the new and old servers.

I could look and see if there is anything I could do.

Or you could ask your new host to do it for you, sometimes they do provide that service.

obglobal.net
12-11-2013, 12:09 AM
I might just have to go back to the old host I think. Fortunately, I can get a refund from the new one.

ozzy47
12-11-2013, 12:10 AM
Up to you, but that may be the quickest way to get your site back up.

obglobal.net
12-11-2013, 12:13 AM
Up to you, but that may be the quickest way to get your site back up.

Certainly looks that way.

ozzy47
12-11-2013, 12:16 AM
Where is the servers located at, USA or overseas?

obglobal.net
12-11-2013, 12:30 AM
Overseas

Thanks bro

ozzy47
12-11-2013, 12:33 AM
Hopefully after you change your nameservers back, to the original host, all will be ok.

obglobal.net
12-11-2013, 01:04 AM
Hopefully after you change your nameservers back, to the original host, all will be ok.

They seem to think it will be. Man....this was a whacky move on my behalf.

--------------- Added 1386727491 at 1386727491 ---------------

Thanks to everyone. You guys are awesome. Special thanks to ozzy47.....you're a diamond

ozzy47
12-11-2013, 01:11 AM
Believe me, I wish I could have helped you move to the new server. Seems a shame to go through all that and just end up at square one.

But at least you can get a refund on the new server, so all is not lost.

obglobal.net
12-11-2013, 01:51 AM
That's it man...it could've been exponentially worse.

Lesson learned: don't dabble in things that are beyond your capabilities. Mine are loooooooowwwww.

--------------- Added 1386770948 at 1386770948 ---------------

Believe me, I wish I could have helped you move to the new server. Seems a shame to go through all that and just end up at square one.

But at least you can get a refund on the new server, so all is not lost.

Everything's good now, dude. Thanks as always for everything.