简体   繁体   English

Laravel 主管随机卡住

[英]Laravel supervisor stuck randomly

I am using Laravel supervisor for running job in background on AWS ec2 instance.我正在使用 Laravel 主管在 AWS ec2 实例的后台运行作业。 It is using for very big files import to mysql and its randomly stuck the supervisor.它用于将非常大的文件导入到 mysql 并且它随机地卡住了主管。 There is no any logs in the log files.日志文件中没有任何日志。 How can we check what cause this?我们如何检查是什么原因造成的?

When a job crashes and there is no log, in the Laravel storage folders.当作业崩溃并且没有日志时,在Laravel存储文件夹中。 Most of the times this is due to the PHP environment crashing.大多数情况下,这是由于 PHP 环境崩溃造成的。 This means that you should probably check where PHP store the errors logs , as when an out of memory exception happens, the process is dead and can't write to Laravels handler.这意味着您可能应该检查 PHP 存储错误日志的位置,因为当 out of memory 异常发生时,进程已死并且无法写入Laravels处理程序。

In have had this a couple of times, all of the times it is each process exceeding it's memory limits.已经有过几次了,每次都是每个进程都超过了它的 memory 限制。 When you talk about big files to import, this can quickly chug up a lot of memory, due to having creating objects with different kind of data.当您谈论要导入的大文件时,由于使用不同类型的数据创建对象,这会很快产生大量 memory。 I believe this is the route you should go down and check.我相信这是你应该 go 下来检查的路线。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM