Import errors

  • Thread starter Thread starter Nelson T.
  • Start date Start date
N

Nelson T.

Guest
Tried to import from VB, and got these errors, then it died at 36.99%:

Mysqli statement execute error : Duplicate entry '34861' for key 'PRIMARY'

  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 574
  4. Zend_Db_Adapter_Abstract->insert() in XenForo/DataWriter.php at line 1624
  5. XenForo_DataWriter->_insert() in XenForo/DataWriter.php at line 1613
  6. XenForo_DataWriter->_save() in XenForo/DataWriter.php at line 1405
  7. XenForo_DataWriter->save() in XenGallery/Model/Importers.php at line 166
  8. XenGallery_Model_Importers->importMedia() in XenGallery/Importer/vBulletin42x.php at line 506
  9. XenGallery_Importer_vBulletin42x->stepMedia() in XenForo/Importer/Abstract.php at line 97
  10. XenForo_Importer_Abstract->runStep() in XenForo/ControllerAdmin/Import.php at line 187
  11. XenForo_ControllerAdmin_Import->_runStep() in XenForo/ControllerAdmin/Import.php at line 135
  12. XenForo_ControllerAdmin_Import->actionImport() in XenForo/FrontController.php at line 347
  13. XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 134
  14. XenForo_FrontController->run() in /home/hobbymac/public_html/Xen/admin.php at line 13
 
If you check Tools > Server Error Log

What was the first error you received? Unless you're trying to import data into an existing gallery, or trying to re-run the importer after it failed, the initial error would have probably been something different.
 
Chris:

They all appeared at once.

Idea- Could this be because I am out of disk space on the server? I don't think I am but I am just trying to figure it out.

I am at 84% full and got a warning, so I am not full.
 
The best way to start over is to uninstall XFMG and reinstall again.

That will mark the stuff imported so far for deletion and clear any data that has been imported so far.

If you continue to have problems, please open a ticket from your Customer Area with login details for your Admin CP, FTP and PhpMyAdmin (the latter two may not be needed if you have access to cPanel or similar).
 
Ok, question...

It wants to use /home/hobbymac/attachments as the gallery directory to import from. That is the main attachment directory with thousands of files. I am worried that is not the correct album directory.

Can you clarify please Chris, this may be the problem.

Thanks.
 
Chris,

When I hit 36.99 after reinstalling the MG, it happens again.....
Admin Control Panel - The Hobby-Machinist
Server Error
Mysqli statement execute error : Duplicate entry '34861' for key 'PRIMARY'

  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 574
  4. Zend_Db_Adapter_Abstract->insert() in XenForo/DataWriter.php at line 1624
  5. XenForo_DataWriter->_insert() in XenForo/DataWriter.php at line 1613
  6. XenForo_DataWriter->_save() in XenForo/DataWriter.php at line 1405
  7. XenForo_DataWriter->save() in XenGallery/Model/Importers.php at line 166
  8. XenGallery_Model_Importers->importMedia() in XenGallery/Importer/vBulletin42x.php at line 506
  9. XenGallery_Importer_vBulletin42x->stepMedia() in XenForo/Importer/Abstract.php at line 97
  10. XenForo_Importer_Abstract->runStep() in XenForo/ControllerAdmin/Import.php at line 187
  11. XenForo_ControllerAdmin_Import->_runStep() in XenForo/ControllerAdmin/Import.php at line 135
  12. XenForo_ControllerAdmin_Import->actionImport() in XenForo/FrontController.php at line 347
  13. XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 134
  14. XenForo_FrontController->run() in /home/hobbymac/public_html/Xen/admin.php at line 13
 
It usually suggests that PHP has hit some sort of error so when it tries to resume it comes across images that it has already imported.

Was there any errors that you could see before this came up? Anything in your PHP or wbeb server error logs?
 
Found this in the php log
PHP Fatal error: Maximum execution time of 120 seconds exceeded in C:\wamp\www\xf\library\Zend\Db\Statement\Mysqli.php on line 208

What do I need to delete in order for the import to continue?
 
Hmm that's an intersting error because nothing should be executing for longer than 120 seconds. The error suggests it's executing a query, at that point. None of the queries should be particularly stressful.

Are you just on the Media step at the moment?

In case it is something else causing it... Do you have many animated images and do you have enabled the option to create animated thumbnails? (That option requires ImageMagick to be enabled).

That might be worth disabling.

Ultimately, though, it might just be worth trying again.

Assuming you're getting the same error as Nelson, above, and you're now getting duplicate entry errors. If the duplicate entry is e.g. 1234 you would need to delete that and the subsequent images currently in the xengallery_media table, then try and refresh the importer. It should continue where it left off.

If you continue to receive these errors, it may be simply down to some sort of corrupted image. To identify it, look in the xengallery_media table for the last entry. If the last entry is 12345 then the one causing the problem is likely to be 12346. Deleting that entry from the source data may allow the importer to continue. Sometimes you might have to do this a few times if there are a few "bad" images.
 
This was at the import media step. According to phpinfo(), I dont have ImageMagick installed.
Deleting the latest two records in xengallery_media allowed the importer to continue.

Thanks.
 
Back
Top Bottom