importing from G1 times out (no specific error)
Nobodys Hero
Joined: 2005-09-16
Posts: 25 |
Posted: Wed, 2005-09-21 02:06 |
I have a fairly large gallery 1.5.1-RC3 install at http://www.michaelmolino.com/gallery/ that I'm trying to upgrade to Gallery 2; Every time I try to import G1 though, it just stops at some point... anytime from 30 seconds to 1 minute in. I checked and safe_mode is not enabled nor are any functions disallowed by php.ini. I've enabled debug mode, but I don't get any debug messages or error messages when it stops... it's just the the progress bar stops moving, mozilla indicates that the page is fully loaded, and if I go to my gallery in a different browser window and keep refreshing it, I can see that nothing is happening Here is a link to php_info(): Here is my host's php.ini (my host is 1and1.com): memory_limit = 40M; Here is the requested support info: Gallery version = 2.0 core 1.0.0 I hope someone can help. I've tried reading as much documentation as I can and I tried searching the forums, but couldn't find anything relevant. If you need to, you can email me at Thanks. |
|
Posts: 198
I have about 15,000 photos on my gallery. I just finished migrating from G1 to G2 and saw the same issue you're having. What I did was import between 4-6 albums at a time. Give that a go and let me know how it goes.
Jeff
Posts: 25
First of all, thank you very much for the quick response...
Unfortunately, that doesn't work though... I tried doing it 1 album at a time... some of them migrated ok (the smaller ones), but some didn't. I gave up a couple of albums in because I figured it wasn't worth migrating all the small albums and then having to re-upload all the large ones...
Also, some more details I thought of that might help... I've tried using both Firefox 1.5 beta 1 and IE 6.0 SP2. I've also tried both from home and at work (thinking maybe my cable modem was just crapping out).
Posts: 111
I migrated over 17,000 images without the problem you are describing. Could you look up your image toolkit priority (under Site Admin -> Graphics Toolkits -> Toolkit Priority). I've read that Gd is a resource hog, so if it's first in the list, try making it last (assuming you have more than just that toolkit installed).
Posts: 3236
He said GD module is deactivated and stuff, plus his info implies that is true. I would try checking your apache's error_log and perhaps trying with GD *on* and NetPBM *off* (help eliminate the toolkit as the problem).
Like Gallery? Appreciate my help? Think I'm an asshole? Make your point by donating to the Gallery project! Or maybe just visit my website.
Posts: 25
I disabled NetPBM and enabled GD.... same problem so I guess that means it's not the image toolkit.
I also noticed it gives the memory usage at the top... everything looks fine, so it's not a memory issue.
Memory used: 12295520, total: 40M (at the time when it stops).
Unfortunately, I don't think 1and1.com gives me access to the error logs... I'll look into that later though, right now I'm late for work!
Posts: 111
Sorry - I missed that salient fact. FWIW, I migrated using the following priority: ImageMagick, NetPBM, Gd
Posts: 25
1and1 doesn't have ImageMagick installed... when i get home from work, i'll look into seeing if i can install it and get it working under my home directory...
Posts: 111
OK. I'd be very interested to hear if that makes a difference for you. To date, I've not found a conclusive pro/con list between those two toolkits.
Posts: 25
It's been a while since I ran linux on any of my machines... I had forgotten how fun it was to install software from source, especially when you don't have root! ;)
Anyway, after some tinkering, I got ImageMagick installed using the folling configure parameters: --prefix=/kunden/homepages/46/d89726853/htdocs/local --exec-prefix=/kunden/homepages/46/d89726853/htdocs/local --without-ttf --without-perl
I'm having the exact same problem still with only ImageMagick activated... Considering I've tried using each of the 3 image toolkits at this point with the exact same results, I think it's fair to say it's not an image toolkit problem.
Any other suggestions? I'm nearing 3,000 photos in my G1 and I'd really like to be able to manage them better.
Posts: 111
What's the "du -sk" of the albums directory in your G1 installation?
Posts: 25
1957172
(my quota is 4 gigs... so i realize space might be a problem, but it "times out" even when i try importing just 1 gallery, so it's not a space issue.)
Posts: 111
Yeah, but I wasn't asking that. ;-) I was going to offer to do it for you, but I need to know how much size we're talking about.
Posts: 25
i don't understand how you would do it.
download my G1 to your server, migrate to G2, then reupload? yikes! i think i'm too stubborn to resort to something like that... I want to try and figure out why I can't do it myself!!
is it possible apache has a timeout set???
(thanks for all the help so far though... i really appreciate it).
Posts: 25
I'd really like to see the apache error logs, but 1and1 doesn't provide them for shared hosting users such as myself... I found this in their FAQ though:
Is there someplace I can add this code to have it globally affect all the PHP scripts in G2?
Posts: 111
I would think that if you were running into an Apache limit, your browser would return some sort of indiciation. Have you tried from a machine that has a different ISP? I've run into something similar to what you are describing when trying to perform time-consuming processes from work (using a client at work, running the process on my server). When I did the same thing at home, I didn't have the issue. My thought, in my scenario, was that the proxy server through which I was connecting my client was causing the issue.
Posts: 111
With respect to your question about the PHP error reporting, the import module already does error reporting. The way you are describing the problem, it's as if someone clicked the Stop button in your browser. It doesn't sound like the error is occuring on the server end.
Posts: 25
Yes, I've tried it both from work (t1) and home (cable) using both IE and Firefox... although, i haven't tried all 12 permutations of ISP, browser, and image toolkit, i've tried enough to rule out those 3 as problems... I've also tried it from at least 2 different computers (addendum: and by at least 2 different computers, I mean exactly 2 different computers).
Your description is perfect - it's exactly as if someone hit the stop button.
Posts: 974
Nobody's Hero:
Heh, 17 messages before I managed to intervene. The reason that I ask about your APACHE error log is that if php runs out of memory it dies instantly and silently except for an inscrutable message in the apache error log. You will not be able to catch this with any sort of pure php function.
First try shutting off the exif module. If you are not seeing the memory get used up, then exif may be exploding (as usual) and trying to read 4 gigabytes out of a 4 megabyte file. Yes, this happens.
If turning off the exif module doesn't help, please try alloting more memory -- like 64M or 128M. g1 is very inefficient, and the migration module has to load a bunch of g1 data all at once while running a bigger chunk of code than g1. Your g1 might be just squeaking by for global operations, but g2 might run out of memory for those same operations.
If you can't get a full migration to work, please try migrating in chucks of albums, like five or ten or twenty at a time. If you find that one album or image always fails, see if you can add just that album. If it's just one image that is failing, please try downloading that image and manually uploading it to g2. If it works then the migration module has some sort of problem. If not, the problem is probably somewhere else in your gallery.
Good luck. Now that I have responded to this thread I will be notified of any further updates.
Posts: 25
1) I actually already tried disabling EXIF. I read about it in this thread: http://gallery.menalto.com/node/37016 ... I forgot to mention that in my last post.
2) My gut tells me it's a memory issue. Unfortunately, since I'm on a shared hosting plan with 1and1.com, I don't have access to modify my php.ini file. I did some googling to see if I could override the settings there, and I found this:
Can I just add
to the beginning of main.php?
3) I already tried doing a couple galleries at a time (I mentioned this in a previous post)... I have at least 2 galleries that fail even when I try importing them 1 at a time. It's not always the same photo where it times out.
... and thanks for jumping in on this thread. i need all the help i can get ;)
Posts: 25
I guess that doesn't work... Every time I add that ini_set line (i've tried adding it in main.php, bootstrap.inc, and Gallery.class, and all 3), I get a message similar to the following... I've even tried values other than 128 (such as 40, 39, and 1).
Posts: 25
ok, nevermind my last post... i forgot the 'M'
when I add
to the top of main.php, I don't get that error... now for the moment of truth. i'm about to try the import... cross your fingers for me!
Posts: 25
I tried the import twice with the new memory limit and it still fails... The first time it failed on IMGP1885.jpg and then on IMGP1883.jpg. I can tell the ini_set() function is working because it shows 128M at the top as the memory limit instead of 40M, so apparently that wasn't the problem.
I was beginning to think 1and1 (my host) just had their server set to kill any script after 30 seconds or something... but that can't be the problem because I've had no problem running G1 and I've uploaded some pretty large albums all at once.
Posts: 111
Let me know if you change your mind on my offer. ;-) If bandwidth is an issue, and it's no larger than 4 GB, you might be able to snail me a DVD-R of the files, and I could send back the modifications the same way.
Posts: 25
haha... i really appreciate it, but i want to try and figure this out...
if i can't get it to work, i'll do 1 of 2 things:
1) stick with G1 until G2.x comes out and fixes my problem...
2) i have a desktop that still has linux installed... i'll just rsync my G1 onto the local machine, migrate there, and rsync it back... but i'm not ready to give up yet!
Posts: 974
Nobody's Hero:
Since I wrote the migration module and mindless is the only other person to work on it, your problem probably won't be solved for gallery 2.x unless we can figure out exactly what your problem is so we can fix it. Try visiting the failing albums in g1, maybe change the properies so they get resaved. Sometimes that helps.
You might want to extend the timeouts.
Look for these lines in modules/migrate/ConfirmImport.inc and replace the 30 with a larger number like 180. Just for fun.
$gallery->guaranteeTimeLimit(30);
Posts: 25
still doesn't work.. i changed that line from 30 to 180 for 3 instances in ConfirmImport.inc and once in ChooseObjects.inc...
it still "timed out" at the same approximate place it always does.
Posts: 25
and for the other suggestion about changing the properties... one of the failing galleries has had several updates (adding photos, resorting, moving sub albums around) since i first started this thread.
Posts: 974
Can you move that album to the root of your gallery, tarball it, then move it back and send me a link to download that album? This is probably going to require me to investigate more directly. Let me know.
Posts: 974
michalp, I moved your post into a new thread for your problem.
Read this:
http://codex.gallery2.org/index.php/Gallery2:migration
Go to your new post here:
http://gallery.menalto.com/node/37168
Posts: 8
I am yet another person using 1and1 hosting, trying to migrate my g1 to g2 with the exact same results. Perhaps this PHP based migration solution that is dependant on defined memory contraints isn't the best choice. Anyone up for the task of writing a binary to perform the migration?
Posts: 974
myn, open a new thread.
READ THE MIGRATION STICKY!
Posts: 25
Here's one of them...
http://www.michaelmolino.com/albums/Zakopane-Slovakia.tar.gz
Posts: 8
I'm going to follow along with this one. Since we are having the exact same issue.
Posts: 111
If you do that, then they can't properly keep track of the metrics for problem resolution.
Posts: 8
I wasn't aware there were metrics on problem resolution. Is there paid staff? Why does this bureaucratic metrics policy exist? I feel like I am at work
Support is about giving people answers. It would be a waste of time for me to create another post and have more time wasted by more people reading it. Especially since we share the exact same issue and hosting provider.
Just my 2 cents.
I appreciate all and any help I receive in these forums.
Thanks for helping.
Posts: 974
Myn, while your problems might seem similar, they might be caused by different things. Plus, if I ask Nobody's Hero a specific question, I may or may not want to ask you the same question. The first question that I want to ask you is if you have read the Migration guide. Have you read the migration guide? If not, please go read it. While you read it, take note of any questions that I ask in it. The more information that you give me, the faster I will be able to figure out if you are experiencing the exact same problem or just a very similar one.
The second question that I want to ask is if you can fill out the support template.
Posts: 111
Why do you need paid staff to have metrics on problem resolution? It's just good quality assurance and it helps keep track of how many people are having problems in a specific area, so it can be determined if more time needs to be devoted to a particular area because of usability issues. ...and is it less of a waste of time to not follow the pre-written steps that the people giving you free help ask of you, only to have them ask you directly, because you didn't do it the first time? ;-)
Posts: 974
Uh, I'm not paid staff and I wrote the migration module. I want it to work for you, but I need you to answer questions for me and I don't want you to mix your answers in with Nobody's Hero's answers. Now, once you start a new thread I will delete this extraneous discussion out of this thread.
Posts: 25
hey jmullan... i've been looking through the posts over the past week, and i see a few people are having my same problem... i was wondering if you had gotten any closer to a solution... thanks for all your help so far.
Posts: 28
bump...
I am having a smiliar problem, any resolution to this?
http://gallery.menalto.com/node/39530
Thanks for any info!
Posts: 1
I had what I suspect is the same problem with my install. What's going on appears to be completely unrelated to any memory management issues. Rather, on some web service providers the install script is messing up with activating the image processing modules. I took the steps at the bottom of this thread: http://gallery.menalto.com/node/40480
After I did that, the migration works fine.