PHP in Commandline - 分段故障(内核转储) - 在Magento中运行phpindexer.php时调试 [英] PHP in Commandline - Segmentation fault (core dumped) - Debug while running phpindexer.php in Magento

查看:280
本文介绍了PHP in Commandline - 分段故障(内核转储) - 在Magento中运行phpindexer.php时调试的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在命令行中运行脚本。它运行大约5分钟,然后返回分段故障(内核转储)



脚本是一个Magento重建索引脚本。



命令行脚本运行 php indexer.php --reindex catalog_url



它只是引发分段故障(内核转储) - 我不知道在哪里寻找


解决方案

似乎脚本运行的内存不足。 Magento本地UrlRewrite索引器是相当缓慢,并使用大量的内存。如果您有26k个产品和很多类别,它可能会产生分段错误。



您可以尝试替代Url Rewrite索引器,使用更少的内存,比核心一,因为在数据库级执行所有操作。但是它需要特权来创建和使用存储的例程才能正常工作。此外,它是严格推荐在dev环境首先尝试,看到它不会被打破,因为有时开发人员添加无效记录到core_url_rewrite表打破一些操作。



该扩展可以通过以下url找到:
http://www.ecomdev.org/2011/10/08/ecomdev-breaks-magento-speed-limits.html


I'm running a script in commandline. It runs for about 5 minutes and then returns Segmentation fault (core dumped)

The script is a Magento reindexing script. Found in /shell for those familiar with the platform

Command line script running is php indexer.php --reindex catalog_url

It just throws Segmentation fault (core dumped) - I don't know where to look for any more info than that?

解决方案

It seems like the script is running out of the memory. Magento native UrlRewrite indexer is quite slow and using a lot of memory. If you have 26k products and a lot of categories it might produce a segmentation fault.

You can try alternative Url Rewrite indexer that is using much less memory and takes much less time than core one, because performing all the operations on database level. But it requires privileges for creation and using of stored routines to work properly. Also it is strictly recommended to try it on dev environment first, to see that it will not be broken, since sometimes developers adding invalid records to core_url_rewrite table that breaking some operations.

The extension can be found by the following url: http://www.ecomdev.org/2011/10/08/ecomdev-breaks-magento-speed-limits.html

这篇关于PHP in Commandline - 分段故障(内核转储) - 在Magento中运行phpindexer.php时调试的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆