Gallery 2 to 2.04 Upgrade

ptalk

Joined: 2005-11-25
Posts: 26
Posted: Sat, 2012-09-15 20:28

Hi,

Trying to upgrade from Gallery 2 to 2.04 (Trying to get to an upgradeable version that will run on php5) and this is the error I'm getting, when trying to run Step 4 "Upgrade Modules".

Warning: requireonce(modules/notification/classes/NotificationHelper.class) [function.requireonce]: failed to open stream: No such file or directory in /home/ptalkm/public_html/gallery2/modules/core/classes/GalleryCoreApi.class on line 2505

The file actually does exist.

Thanks in advance for the help.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Sun, 2012-09-16 19:34

make sure modules/notification/classes/NotificationHelper.class is 644 at least and gallery on linux is case sensitive.

-s
All New jQuery Minislideshow for G2/G3

 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Sun, 2012-09-16 20:07

All files are 644. Folders usually 755.

Do you know if this is the first file in the upgrade process that gets upgraded ? or is it in the middle somewhere ?

The next line is this:

Fatal error: requireonce() [function.require]: Failed opening required 'modules/notification/classes/NotificationHelper.class' (include_path='.:/usr/php4/lib/php') in /home/user/public_html/gallery2/modules/core/classes/GalleryCoreApi.class on line 2505

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Sun, 2012-09-16 20:14

can't you skip the upgrade of that module?

-s
All New jQuery Minislideshow for G2/G3

 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Sun, 2012-09-16 20:20

Sure, I'm ultimately headed to version 3 anyway....

How do I skip it ?

Then I could move on to the 2.0.4 upgrade to the next version.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Sun, 2012-09-16 20:25

doesn't the upgrader present you with a list of plugins to upgrade after the core gets upgraded?
I don't have that old version to check

-s
All New jQuery Minislideshow for G2/G3

 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Sun, 2012-09-16 20:31

I guessing I'm not getting that far.

It completes the Core module upgrade (step 3), I go to click on step 4 (upgrade modules), and that's when I get the error.

So the core modules are upgraded.

Step 5 is to empty cache.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Sun, 2012-09-16 20:36

core is upgraded
move on

-s
All New jQuery Minislideshow for G2/G3

 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Sun, 2012-09-16 20:57

OK. Will do. Thanks.

 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Sun, 2012-09-16 22:14

OK... I'm using the 2.0.4 failed upgrade as above. And running the 2.1 upgrade as indicated in the other thread.

I get to step 3 and get the followin error:

Stack Trace:

Error (ERROR_STORAGE_FAILURE)
in modules/core/classes/GalleryStorage/GalleryStorageExtras.class at line 948 (gallerycoreapi::error)
in modules/core/classes/GalleryStorage.class at line 489 (gallerystorageextras::execute)
in modules/core/CoreModuleExtras.inc at line 1379 (mysqlstorage::execute)
in modules/core/module.inc at line 487 (coremoduleextras::upgrade)
in modules/core/classes/GalleryModule.class at line 157 (coremodule::upgrade)
in upgrade/steps/UpgradeCoreModuleStep.class at line 83 (coremodule::installorupgrade)
in upgrade/index.php at line 221 (upgradecoremodulestep::processrequest)

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Sun, 2012-09-16 23:22

is your gallery operational?
if so, disable as many non critical plugins as possible

Also make sure you are indeed replacing the codebase w/ your upgrade code.

-s
All New jQuery Minislideshow for G2/G3

 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Mon, 2012-09-17 00:10

I don't know because when I go to the main.php, it always redirects me to the upgrade.

So right now, I don't have any way to disable the non-critical plugins. Unless I can do so in the SQL db.

As for replacing, when I upload, I'm doing an overwrite of everything, even if the file on the server is newer.

This looks like the first error near the end of the file.

(mysql):
ALTER TABLE g2_AccessMap
DROP INDEX g_accessListId_2,
ADD INDEX g2_AccessMap_83732(g_accessListId);

1091: Can't DROP 'g_accessListId_2'; check that column/key exists

adodb_mysql._execute(
ALTER TABLE g2_AccessMap
DROP INDEX g_accessListId_2,
ADD INDEX g2_AccessMap_83732(g_accessListId);, false) % line 855, file: adodb.inc.php
adodb_mysql.execute(
ALTER TABLE g2_AccessMap
DROP INDEX g_accessListId_2,
ADD INDEX g2_AccessMap_83732(g_accessListId);, Array[0]) % line 941, file: GalleryStorageExtras.class
gallerystorageextras.execute(
ALTER TABLE g2_AccessMap
DROP INDEX g_accessListId_2,
ADD INDEX g2_AccessMap_83732(g_accessListId);, Array[0]) % line 489, file: GalleryStorage.class
mysqlstorage.execute(
ALTER TABLE g2_AccessMap
DROP INDEX g_accessListId_2,
ADD INDEX g2_AccessMap_83732(g_accessListId);) % line 1357, file: CoreModuleExtras.inc
coremoduleextras.upgrade(Object:coremodule, null,
Object:statustemplate) % line 487,
file: module.inc

file_exists(/home/ptalkm/public_html/gallery2/modules/core/classes/helpers/../../../../modules/core/classes/GalleryStorage/schema.tpl)
file(/home/ptalkm/public_html/gallery2/modules/core/classes/helpers/../../../../modules/core/classes/GalleryStorage/schema.tpl,
)

(mysql): SHOW TABLES

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Mon, 2012-09-17 02:46
 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Tue, 2012-09-18 23:23

Which modules should I focus on removing ?

theme matrix 1
module albumselect 1
module captcha 0
module cart 0
module colorpack 1
module customfield 1
module debug 1
module exif 0
module icons 1
module imageblock 1
module imageframe 0
module members 1
module mime 1
module multilang 1
module netpbm 0
module newitems 1
module panorama 0
module photoaccess 0
module quotas 1
module randomhighlight 1
module rearrange 1
module register 1
module remote 1
module search 0
module sizelimit 1
module slideshow 0
module slideshowapplet 0
module thumbnail 1
module uploadapplet 1
module useralbum 1

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2012-09-18 23:51

you really only need matrix
the ones w/ 0 after are already inactive.
Don't uninstall/delete, just deactivate.

-s
All New jQuery Minislideshow for G2/G3

 
ptalk

Joined: 2005-11-25
Posts: 26
Posted: Wed, 2012-09-19 00:04

I found the answer while I was waiting for reply.....

http://gallery.menalto.com/node/48461

The upshot is you have to run this SQL, and then that fixes it.

alter table g2_AccessMap add column g_userId int;
alter table g2_AccessMap add column g_groupId int;
alter table g2_AccessMap alter column g_userId set default 0;
alter table g2_AccessMap alter column g_groupId set default 0;
update g2_AccessMap set g_userId = 0;
update g2_AccessMap set g_groupId = g_userOrGroupId;

I also had to add a "sessions" direcoty in the g2data to complete the install.

I'm done with 2.1!!! Onward to 2.2