upgrade error

gragland

Joined: 2005-03-07
Posts: 35
Posted: Sat, 2005-03-19 21:09

I get this error when i run the upgrader after upgrading to the latest cvs build.

Error (ERROR_STORAGE_FAILURE)
in modules/core/classes/GalleryStorage/DatabaseStorage.class at line 1158 (gallerystatus::error)
in modules/core/classes/GalleryStorage.class at line 241 (mysqldatabasestorage::execute)
in modules/core/CoreModuleExtras.inc at line 314 (gallerystorage::execute)
in modules/core/module.inc at line 513 (coremoduleextras::upgrade)
in modules/core/classes/GalleryModule.class at line 137 (coremodule::upgrade)
in upgrade/steps/UpgradeCoreModuleStep.class at line 68 (coremodule::installorupgrade)
in upgrade/index.php at line 156 (upgradecoremodulestep::loadtemplatedata)

In the debug this is where the error shows up:

mysql error: [1051: Unknown table 'gabeg2_ItemPropertiesMap'] in EXECUTE("
DROP TABLE gabeg2_ItemPropertiesMap
")

(mysql):
DROP TABLE gabeg2_ItemPropertiesMap
 

1051: Unknown table 'gabeg2_ItemPropertiesMap'

            adodb_mysql._execute(
DROP TABLE gabeg2_ItemPropertiesMap
, false) % line 833, file: adodb.inc.php
          adodb_mysql.execute(
DROP TABLE gabeg2_ItemPropertiesMap
, Array[0]) % line 1152, file: DatabaseStorage.class
        mysqldatabasestorage.execute(
DROP TABLE [GalleryItemPropertiesMap]
, Array[0]) % line 241, file: GalleryStorage.class
      gallerystorage.execute(
DROP TABLE [GalleryItemPropertiesMap]
) % line 314, file: CoreModuleExtras.inc
    coremoduleextras.upgrade(Object:coremodule, null) % line 513, file: module.inc

realpath(/home/gragland/public_html/gallery2_31805/gallery2/modules/core/classes/../../../)

Any ideas of what is wrong?

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Sat, 2005-03-19 21:25

- previous G2 version?
- activate debug mode in config.php and post the complete debug output.
- did you delete the old codebase and uploaded the new cvs version? or did you use the "cvs update" command? or did you just install the new files over the old files?

 
gragland

Joined: 2005-03-07
Posts: 35
Posted: Sat, 2005-03-19 21:35

I installed the latest cvs, not an update, but a full fresh copy. Then i installed it and after the installation it when to the upgrader (which is weird because i didnt upgrade) and i got this error. I did "cvs update" to see if that would fix it but it didn't. I posted the debug info in my first post.

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Sat, 2005-03-19 21:44

seems your installation wasn't that fresh.
when you do a fresh install, make sure...
- the g2data folder is really, really empty
- the database is empty, no g2 tables/... should exist
- you install the complete codebase

if the upgrader starts after a "fresh install", then most probably, there was still something in your g2data folder or in the database.

 
gragland

Joined: 2005-03-07
Posts: 35
Posted: Sat, 2005-03-19 21:55

It was definately completely fresh, except i did choose to reuse tables in my database. Should I not ever do that?

 
gragland

Joined: 2005-03-07
Posts: 35
Posted: Sat, 2005-03-19 22:00

Also, since my host comes with unlimited mysql databases, should I use a different database for every gallery2 install? Or should I just use one database and make sure each install uses different table names?

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Sat, 2005-03-19 22:20

if your g2data directory was empty, there's no reason why you should reuse existing database tables.
reuse db tables only, if you're running the installer again a second time to change something for a running gallery.

so, empty g2data, drop all tables and install g2 again.

you can use the same database for several G2 installations, but each G2 needs its own database prefix.