I am migrating from one server to another. I have got to the point where I am importing the database to my new server and I am getting an error and it stops. It says
INSERT INTO 'g2_FailedLoginsMap'
VALUES (
'cameleon vert',10,1266416091
);
MySQL said:
#1062 - Duplicate entry 'cameleon vert' for key 1
any suggestions?
old server:-
Gallery URL = http://gallery.barlowtyrie.co.uk/main.php
Gallery version = 2.3.2 core 1.3.0.2
API = Core 7.54, Module 3.9, Theme 2.6, Embed 1.5
PHP version = 4.3.10-2 cgi-fcgi
Webserver = Apache/2.0.51 (Debian GNU/Linux) PHP/4.3.10-2 mod_ssl/2.0.51 OpenSSL/0.9.7e
Database = mysqlt 4.0.24_Debian-10sarge3-log, lock.system=flock
Toolkits = Exif, Gd, SquareThumb
Acceleration = none, none
Operating system = Linux chimp.keme.net 2.4.27-3-386 #1 Wed Dec 6 00:38:33 UTC 2006 i686
Default theme = matrix
gettext = enabled
Locale = en_GB
Browser = Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.52 Safari/537.17
Rows in GalleryAccessMap table = 12
Rows in GalleryAccessSubscriberMap table = 1746
Rows in GalleryUser table = 470
Rows in GalleryItem table = 1746
Rows in GalleryAlbumItem table = 12
Rows in GalleryCacheMap table = 0
new one is php version 5.5.3
Posts: 8339
SOunds like you've already inserted that entry.
You cannot keep trying your import.
If it fails, you must delete the tables created by the previous try and start fresh.
-s
________________________________
All New jQuery Minislideshow for G2/G3
Posts: 21
it errored on the first import. I then cleared and dropped all the tables and tried the import again and it did it again.
Posts: 8339
failed logins are not important. open your exported sql in a text editor and remove the whole INSERT following FailedLoginsMap entry(just use the text editor's search tool and search for cameleon vert)
assuming you exported in sql format that is.
Or if you still have access to the old mysql server, clear all entries to that table and re-export
Or if you exported in an archived format you can simply unzip it and edit the sql and import the raw sql
-s
________________________________
All New jQuery Minislideshow for G2/G3
Posts: 21
thank you - that has worked
Posts: 21
Another question.... The instructions then say run the installer but as I already have everything uploaded (or could) would it be an installer and not something else?
The problem is I am at the create database stage but I already have all the tables etc and I am getting a connection error and I am concerned I should not be doing this bit.
Posts: 8339
After importing the database, do not run the installer.
Since you are using your old installation's files for /gallery2 and g2data the DB already has all the info it would need.
But you would have to edit /gallery2/config.php in a text editor w/ the new path to g2data and the new DB info.
If your gallery does not work after editing config.php you can run the upgrader yoursite.com/galllery2/upgrade and it will report any errors it may find.
-s
________________________________
All New jQuery Minislideshow for G2/G3
Posts: 21
sorry about this but my hosting company is rather unhelpful and I am struggling.
I looked at the directory structure of my current gallery and duplicated on the new server and filled it and imported the database.
The gallery2 software appears to be in /aa/bb/public_html/etc etc and my images (g2data) in /aa/bb/images/ so when I try to test the gallery I have to navigate to http://testserver/bb/public_html/main.php - would you say that was right?
My reason is that I turned on the debugger and it moans that the core version is out of date and it then attempts to run testserver/bb/upgrade/index.php which it doesn't find - well it won't as it is in testserver/bb/public_html/upgrade/index.php and if I run that I get a permissions problem on the images directory and it fails yet the images directory and subdirectories are all '777'.
Any suggestions?
Posts: 8339
all files and directories need to be 777
the command from shell would be chmod -R 0777 /aa/bb/images
where the -R is for recursive
FAQ: How can I fix the filesystem permissions of the Gallery storage folder?
this is a result of not being able to read g2data/versions.dat which should be remedied with the permissions fix.
/aa/bb/public_html/ is the root of your testserver site? then it should be http://testserver.com/upgrade/
-s
________________________________
All New jQuery Minislideshow for G2/G3