MG 1.1 Importing from Photopost

DragonFlames

Active member
Hi,

MG 1.1.1 XEN 1.5.1

I am trying to import from Photopost running on XenForo.

The import ran for about 6 hours importing media and then it just showed a blank white screen. Looking at the Server Error Log it shows this:

ErrorException: Fatal Error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 55776 bytes) - library/XenGallery/Helper/Image.php:294

Stack Trace

#0 [internal function]: XenForo_Application::handleFatalError()
#1 {main}


Request State

array(3) {
["url"] => string(53) "http://www.mysite.com/admin.php?import/import"
["_GET"] => array(1) {
["import/import"] => string(0) ""
}
["_POST"] => array(1) {
["_xfToken"] => string(8) "********"
}
}

I have tried running it again several times but it gives the same white screen and server error.

Hoping you can help.

Steve
 
It looks as though it's struggling to resize a particular image.

It's quite a memory intensive operation. Are you able to ascertain what image in Photopost is causing the problem? Is your host able to increase the resources you have available?
 
Chris,

You clever man you. I went in and increased the memory available and the import has restarted OK this time!

I did consider that with the error report we got but thought it should be plenty of memory and nothing ever normally fails due to that setting so I didn't try it, silly me it seems.

It is running on a dedicated server with hefty resources so it was simple for me to make changes.

The error reports only gave the info I quoted.

Whilst writing, I guess you have seen what has happened over at the photopost site but I may as well mention it in case not. I would guess that if nothing changes there you may have thousands more folks coming your way and doing the same sort of imports I am in the coming months. My only real reservation over the change over is the thumbnails not showing the full photo at present, I'm not sure I'll ever get used to square bits of photos, and I have my fingers crossed for a full photo thumbnail option down the line. Once I get used to the software I'll probably make some actual suggestions for consideration in the correct area. So far XFMG looks like an amazing piece of work, and thank you for that and your help here.

Steve
 
Glad that worked.

I actually haven't seen what's going on at PhotoPost has development stopped?

Thumbnails can be any size. So if you mostly specialise in landscape photos you can opt for a 300x200 thumbnail (or similar). Sadly it's not dynamic so you just have to choose a resolution that suits the bulk of your photos which I appreciate doesn't work in all cases.

Thanks for your kind words.
 
Glad that worked.

Me too, and I now have XFMG installed on my live system. I do seem to have a problem though, I keep running into this error:

Mysqli statement execute error : Out of range value for column 'xengallery_media_quota' at row 1

As far as I can see that column of XF_user is all zeros.

Anything I can do?

Steve
 
Can you include the full backtrace of the error?

You may need to run the "Rebuild XenForo Media Gallery User Media Quota" option in rebuild caches.
 
Can you include the full backtrace of the error?

You may need to run the "Rebuild XenForo Media Gallery User Media Quota" option in rebuild caches.

Thanks for your help Mike.

Sadly running that rebuild is one of the things that brings up that error.

Is this the further info you meant?

Server Error
Mysqli statement execute error : Out of range value for column 'xengallery_media_quota' at row 1

  1. Zend_Db_Statement_Mysqli->_execute() in Zend/Db/Statement.php at line 297
  2. Zend_Db_Statement->execute() in Zend/Db/Adapter/Abstract.php at line 479
  3. Zend_Db_Adapter_Abstract->query() in Zend/Db/Adapter/Abstract.php at line 632
  4. Zend_Db_Adapter_Abstract->update() in XenGallery/Model/Media.php at line 617
  5. XenGallery_Model_Media->rebuildUserMediaQuota() in XenGallery/Deferred/UserMediaQuota.php at line 26
  6. XenGallery_Deferred_UserMediaQuota->execute() in XenForo/Model/Deferred.php at line 295
  7. XenForo_Model_Deferred->runDeferred() in XenForo/Model/Deferred.php at line 429
  8. XenForo_Model_Deferred->_runInternal() in XenForo/Model/Deferred.php at line 374
  9. XenForo_Model_Deferred->run() in XenForo/ControllerAdmin/Tools.php at line 159
  10. XenForo_ControllerAdmin_Tools->actionRunDeferred() in XenForo/FrontController.php at line 351
  11. XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 134
  12. XenForo_FrontController->run() in /forum/admin.php at line 13

The XF forums and the XFMG are running. This crash happens when I try and run some of the rebuilds or if I try and alter some settings. I don't know if it is a clue that I see: Your Usage: 0 bytes under Your Statistics on the Media Index. It also says I have thousands of media items, which is correct.

My only guess was that it was perhaps the settings for the quota systems. I did try changing those as I had not entered anything at first as the defaults looked fine. It didn't seem to help.

Steve
 
When I originally saw that it was an out of range error, I assumed that we were perhaps trying to set a negative number somewhere - this is the kind of thing that can come up when deleting media (though we have code to prevent that so I was somewhat confused). However, seeing that this is happening when the quota is being rebuilt, suggests that a single one of your users has over 4.2GB of uploaded media - could that be correct?
 
In retrospect, as this field is for storing the number of bytes being used, the field being an unsigned INT was somewhat restrictive.

We'll add this change to XFMG 1.1.2, please run this query now on your database and see if that solves the problem:
Code:
ALTER TABLE xf_user
CHANGE COLUMN xengallery_media_quota xengallery_media_quota BIGINT UNSIGNED NOT NULL DEFAULT 0
 
Chris,

Yep, that worked. The rebuild then took place and it also rebuilt the EXIF info as I clicked that earlier too.

I checked the largest uploaded media for one ID that we have at present and it is around 14gb. I'd expect those figures to grow a lot in the future as new cameras make larger and larger files/images. There will be things like 4K/8K video down the line too.

I have XFMG installed and running but I have it hidden a little at present as I am manually redoing the 900+ category positions as they got shuffled in the import. They seem to have the correct positioning info on each category, like that they are in spot 21 of 30 or whatever, but it is the info on which category a category is below which seems to often be missing or shuffled to something new.

Our videos didn't generally make it across, particularly the larger ones. I think maybe I could do away with our video areas and upload the originals to suitable photo areas and allow them to be mixed together in that way. My only problem though is I don't think we have the ability to upload as the original uploader, so how to put them up here and there without them being seen as mine is something I'll have to figure.

Thanks for your help. I hope you get lots more folks moving over.

That comment I made about Photopost is best checked out by looking at their Web site by the way. The home page at photopost.com says what they are not now doing. Then looking at the few forums you can view and seeing what all the messages of recent weeks are should tell you all you need to know. I hope nobody there got ill or anything like that.... sadly even with 3 licenses I can't see most of the forum areas nor download the current software version due to the reasons they state on their home page etc.

All the best,

Steve
 
Top Bottom