Welcome to Geeklog, Anonymous Saturday, December 21 2024 @ 12:17 pm EST
Geeklog Forums
Upgrade from 1.3.8-1sr3 to 1.4.0b1 fails with "An SQL error has occurred. Please see error.log
Status: offline
tingo
Forum User
Chatty
Registered: 06/05/02
Posts: 57
Location:Oslo, Norway
I am migrating a site from Geeklog 1.3.8-1sr3 to Geeklog 1.4.0b1, using the instructions from the FAQ ("Migrating a Geeklog site"). The new installation is on a new machine.
What I have done so far:
1. Made a backup of the old site (the whole directory) and the database
2. installed Geeklog 1.4.0b1 on the new server.
3. Tested that Geeklog 1.4.0b1 worked - it did.
4. Dropped the database, and created a new empty one, including granting rights for the database user.
5. Restored the database backup from the old server, using the instructions in "Restoring a database backup".
6. I had a few plugins, so I copied over the files, making sure that ownership and permissions are correct.
7. I verified settings in the new config.php against the old one.
8. Finally, it was time to run the install script in upgrade mode.. I started the script, selected "Upgrade", changed and verified the path, pressed the button, and got thie message:
Ok, so I check
Now what?
One more thing - differences between the old and the new server:
Is that a problem?
What I have done so far:
1. Made a backup of the old site (the whole directory) and the database
2. installed Geeklog 1.4.0b1 on the new server.
3. Tested that Geeklog 1.4.0b1 worked - it did.
4. Dropped the database, and created a new empty one, including granting rights for the database user.
5. Restored the database backup from the old server, using the instructions in "Restoring a database backup".
6. I had a few plugins, so I copied over the files, making sure that ownership and permissions are correct.
7. I verified settings in the new config.php against the old one.
8. Finally, it was time to run the install script in upgrade mode.. I started the script, selected "Upgrade", changed and verified the path, pressed the button, and got thie message:
An SQL error has occurred. Please see error.log for details.
.Ok, so I check
./logs/error.log
- nothing. I check the webserver logs as well - httpd-access.log
looks normal, and there is nothing in httpd-error.log
Now what?
One more thing - differences between the old and the new server:
Text Formatted Code
<br />tool old new<br />---------------------------------------<br />Apache 1.3.27 1.3.34<br />PHP 4.3.1 4.4.1<br />MySQL 3.23.55 4.1.5<br />Is that a problem?
5
7
Quote
Status: offline
Benta
Forum User
Regular Poster
Registered: 03/11/05
Posts: 80
Quote by tingo: I am migrating a site from Geeklog 1.3.8-1sr3 to Geeklog 1.4.0b1, using the instructions from the FAQ ("Migrating a Geeklog site"). The new installation is on a new machine.
What I have done so far:
1. Made a backup of the old site (the whole directory) and the database
2. installed Geeklog 1.4.0b1 on the new server.
3. Tested that Geeklog 1.4.0b1 worked - it did.
4. Dropped the database, and created a new empty one, including granting rights for the database user.
5. Restored the database backup from the old server, using the instructions in "Restoring a database backup".
6. I had a few plugins, so I copied over the files, making sure that ownership and permissions are correct.
7. I verified settings in the new config.php against the old one.
8. Finally, it was time to run the install script in upgrade mode.. I started the script, selected "Upgrade", changed and verified the path, pressed the button, and got thie message:
Ok, so I check
Now what?
One more thing - differences between the old and the new server:
Is that a problem?
What I have done so far:
1. Made a backup of the old site (the whole directory) and the database
2. installed Geeklog 1.4.0b1 on the new server.
3. Tested that Geeklog 1.4.0b1 worked - it did.
4. Dropped the database, and created a new empty one, including granting rights for the database user.
5. Restored the database backup from the old server, using the instructions in "Restoring a database backup".
6. I had a few plugins, so I copied over the files, making sure that ownership and permissions are correct.
7. I verified settings in the new config.php against the old one.
8. Finally, it was time to run the install script in upgrade mode.. I started the script, selected "Upgrade", changed and verified the path, pressed the button, and got thie message:
An SQL error has occurred. Please see error.log for details.
.Ok, so I check
./logs/error.log
- nothing. I check the webserver logs as well - httpd-access.log
looks normal, and there is nothing in httpd-error.log
Now what?
One more thing - differences between the old and the new server:
Text Formatted Code
<br />tool old new<br />---------------------------------------<br />Apache 1.3.27 1.3.34<br />PHP 4.3.1 4.4.1<br />MySQL 3.23.55 4.1.5<br />Is that a problem?
you might wanna try disbling all the plugins by changing 1 to 0 in the plugins table in the data base. anyway, that's how i find out which plugin that's messing up
4
5
Quote
Status: offline
tingo
Forum User
Chatty
Registered: 06/05/02
Posts: 57
Location:Oslo, Norway
Quote by Benta:
you might wanna try disbling all the plugins by changing 1 to 0 in the plugins table in the data base. anyway, that's how i find out which plugin that's messing up
you might wanna try disbling all the plugins by changing 1 to 0 in the plugins table in the data base. anyway, that's how i find out which plugin that's messing up
Ah, that's a great suggestion. I have tried it, and my plugins table now looks like this:
Text Formatted Code
mysql> select * from gl_plugins;
+-------------+------------+---------------+------------+---------------------------+
| pi_name | pi_version | pi_gl_version | pi_enabled | pi_homepage |
+-------------+------------+---------------+------------+---------------------------+
| staticpages | 1.3 | 1.3.8 | 0 | http://www.tonybibbs.com |
| geekary | 1.3 | 1.3.6 | 0 | http://www.bolstudios.com |
| filemgmt | 1.2 | 1.3.6 | 0 | http://www.langfamily.ca |
| weather | 2.0 | 1.3.8 | 0 | http://www.squatty.com |
+-------------+------------+---------------+------------+---------------------------+
4 rows in set (0.00 sec)
Unfortunately, it didn't help. I get the same error as before, and the error logs of Geeklog and Apache still don't tell anything.
If I try to access access the frontpage of my site (http://sitename.example.org/) directly, I get the following error message in ../logs/error.log:
Sun Nov 27 14:50:15 2005 - 1146: Table 'moromc.gl_syndication' doesn't exist. SQL in question:
SELECT format, filename, title FROM gl_syndication WHERE (header_tid = 'all')
Which is what I expect; because the database isn't upgraded yet.
This is frustrating. Any other suggestions or hints?
8
6
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by tingo: 8. Finally, it was time to run the install script in upgrade mode.. I started the script, selected "Upgrade", changed and verified the path, pressed the button, and got thie message:
An SQL error has occurred. Please see error.log for details.
.So you're getting the SQL error before you even get to the page where you can select which Geeklog version you're coming from?
In that case, open the install script and find the function INST_identifyGeeklogVersion. Below the "global" statement (and above the comments that follow), add this line:
Text Formatted Code
$_DB->setDisplayError (true);What's (probably) happening here is that Geeklog now tries to identify the Geeklog version your database was used with and it seems that test failed. It doesn't even know about error.log at that point and so can't log anything there ...
With the above change, the error message should be displayed on screen instead.
bye, Dirk
5
7
Quote
Status: offline
tingo
Forum User
Chatty
Registered: 06/05/02
Posts: 57
Location:Oslo, Norway
Quote by Dirk: So you're getting the SQL error before you even get to the page where you can select which Geeklog version you're coming from?
Correct. Sorry for not making that more clear earlier.
In that case, open the install script and find the function INST_identifyGeeklogVersion. Below the "global" statement (and above the comments that follow), add this line:
Text Formatted Code
$_DB->setDisplayError (true);I had to add
$_DB
to the global statement, or I would get a different errror. [quote[
What's (probably) happening here is that Geeklog now tries to identify the Geeklog version your database was used with and it seems that test failed. It doesn't even know about error.log at that point and so can't log anything there ...
[/quote]
I see, that explains it.
With the above change, the error message should be displayed on screen instead.
It is, but the message is
1146: Table 'moromc.gl_syndication' doesn't exist
.:-/
That shouldn't happen here, should it?
4
11
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by tingo: I had to add
$_DB
to the global statement, or I would get a different errror. Good catch. Sorry about that.
Quote by tingo: It is, but the message is
:-/
That shouldn't happen here, should it?
1146: Table 'moromc.gl_syndication' doesn't exist
.:-/
That shouldn't happen here, should it?
Okay, looks like I have to redesign the test for old Geeklog versions there ...
For now, find the line that reads
Text Formatted Code
$curv = INST_identifyGeeklogVersion ();(in function INST_getDatabaseSettings) and simply comment it out. That should get you past this stage and I'll come up with an improved install script in beta 2 ...
bye, Dirk
5
7
Quote
Status: offline
tingo
Forum User
Chatty
Registered: 06/05/02
Posts: 57
Location:Oslo, Norway
Quote by Dirk:
Okay, looks like I have to redesign the test for old Geeklog versions there ...
For now, find the line that reads
(in function INST_getDatabaseSettings) and simply comment it out. That should get you past this stage and I'll come up with an improved install script in beta 2 ...
bye, Dirk
Okay, looks like I have to redesign the test for old Geeklog versions there ...
For now, find the line that reads
Text Formatted Code
$curv = INST_identifyGeeklogVersion ();(in function INST_getDatabaseSettings) and simply comment it out. That should get you past this stage and I'll come up with an improved install script in beta 2 ...
bye, Dirk
I'll try that. For the improved install script, a quick search on Google seems to imply that
Text Formatted Code
SHOW TABLES LIKE tablename
8
4
Quote
Status: offline
tingo
Forum User
Chatty
Registered: 06/05/02
Posts: 57
Location:Oslo, Norway
Quote by Dirk:
(in function INST_getDatabaseSettings) and simply comment it out. That should get you past this stage and I'll come up with an improved install script in beta 2 ...
(in function INST_getDatabaseSettings) and simply comment it out. That should get you past this stage and I'll come up with an improved install script in beta 2 ...
It worked perfectly. The upgrade succeded.
Thanks a lot!
8
3
Quote
All times are EST. The time is now 12:17 pm.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content