Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Fatal error when upgrading from cpg1.4.25 to cpg1.5.8  (Read 3280 times)

0 Members and 1 Guest are viewing this topic.

JohnH

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
Fatal error when upgrading from cpg1.4.25 to cpg1.5.8
« on: October 31, 2010, 03:58:49 pm »

Gallery URL: http://www.billyelliottheforum.me.uk/gallery/

Upgrading from 1.4.25 to 1.5.8 with no plug-ins.  Using FileZilla as FTP client.

I followed the upgrade docs and copied all of the files up to the server and tried to run update.php and got the generic Fatal error page.  Searching the forums I discovered that I should have disabled bridging before upgrading so I restored all of the 1.4.25 files, logged in and disabled the bridge.  I also followed the suggestion of deleting all the files in the gallery except for the albums folder and include/config.inc.php.

I uploaded all the 1.5.8 files and ran update.php.  It seemed to run for a few seconds with no output and then displayed the index page using the curve theme but it didn't ask me for a username/password.  As soon as I clicked on any of the links in the menu I got the generic Fatal error page.  Using the instructions at http://documentation.coppermine-gallery.net/en/errors.htm#errors_fatal I used phpMyAdmin to enable debug_mode.  The debug output gave me the error: mySQL error: Unknown column 'access_level' in 'field list'.

I started working through the suggestions in this post: http://forum.coppermine-gallery.net/index.php/topic,65521.0.html and taking the advice offered by Joachim in this post I started running all the queries in sql/update.sql using phpMyAdmin.  I got errors on some of the queries (sorry dev team but it was now 2am and it didn't occur to me to keep a record of the error messages) but my years of fiddling with various flavours of SQL allowed me to rectify all the errors except one.

When I run the query
Code: [Select]
ALTER TABLE cpg_filetypes DROP INDEX `EXTENSION`, ADD PRIMARY KEY ( `extension` );
I get the error message
Code: [Select]
#1091 - Can't DROP 'EXTENSION'; check that column/key exists
I have checked the structure of cpg_filetypes and the field 'extension' exists.

I don't know if it helps or not but I also ran
Code: [Select]
SHOW INDEX FROM `cpg_filetypes'
and got the following
Code: [Select]
Table       Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
cpg_filetypes 0        PRIMARY               1 extension       A    105          NULL          NULL   BTREE

Can I get away without running this query or can some tell me what is wrong with it/my database?

The gallery seems to be working now in that I am no-longer getting the fatal error message and I am able to log in.  However versioncheck.php is reporting a lot of the files (501) as having been modified so I'm going to re-upload all of the files showing an error with a fresh download of 1.5.8.
Logged

JohnH

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
Re: Fatal error when upgrading from cpg1.4.25 to cpg1.5.8
« Reply #1 on: October 31, 2010, 09:01:14 pm »

Some additional information:

Now that I've had time to look properly at the gallery all is not well.  I can change the theme in the config and it remembers my selection but the theme isn't activated, it stays on the curve theme.

Also the front page isn't showing any categories or albums, just the latest additions.  When I select a thumbnail from the latest additions it takes me to the intermediate picture but the breadcrumb list is showing all the categories & albums inside one another.

I have included 2 screen shots of this, one of the front page and the other showing the crazy breadcrumb.

Anyone have any ideas of where I go from here?

Thanks,

John
Logged

Nibbler

  • Guest
Re: Fatal error when upgrading from cpg1.4.25 to cpg1.5.8
« Reply #2 on: October 31, 2010, 09:17:06 pm »

Theme changing works for me. Clear your cookies.
The messed up categories are a result of not having run update.php. Create a new category and then it will sort itself out.
Logged

JohnH

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
Re: Fatal error when upgrading from cpg1.4.25 to cpg1.5.8
« Reply #3 on: October 31, 2010, 09:40:38 pm »

Nibbler you're an absolute star! :)  I couldn't see the wood for the trees, didn't think of clearing the cookies!

Should I have another go at running update.php even though I got all but one SQL query to work?  Would it do any harm?
Logged

JohnH

  • Coppermine newbie
  • Offline Offline
  • Posts: 9
Re: Fatal error when upgrading from cpg1.4.25 to cpg1.5.8
« Reply #4 on: November 01, 2010, 01:04:20 am »

I re-ran update.php while logged in as admin and it worked.  It seemed to fix the last remaining glitches and so I'm marking this as solved.
Logged
Pages: [1]   Go Up
 

Page created in 0.017 seconds with 21 queries.