GithubHelp home page GithubHelp logo

pm2 状态问题 about antcolony HOT 18 CLOSED

keenwon avatar keenwon commented on May 22, 2024
pm2 状态问题

from antcolony.

Comments (18)

keenwon avatar keenwon commented on May 22, 2024

id是3的这个是worker吗?你看看pm2 logs有什么错误信息没,还有log文件夹下也看看。
一般情况下,没报错的话,内存超过限制,也会重启的,尽量避免频繁重启。
如果你服务器内存足够的话,可以把内存限制调大,配置看这里 config.js:35

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

pm2 logs:
[female[1]-3 (out)] ##############################################################
[female[1]-3 (out)] #
[female[1]-3 (out)] # !!! MONGOOSE WARNING !!!
[female[1]-3 (out)] #
[female[1]-3 (out)] # This is an UNSTABLE release of Mongoose.
[female[1]-3 (out)] # Unstable releases are available for preview/testing only.
[female[1]-3 (out)] # DO NOT run this in production.
[female[1]-3 (out)] #
[female[1]-3 (out)] ##############################################################
[female[1]-3 (out)]
[female[1]-3 (out)] Warning: Redis server does not require a password, but a password was supplied.
[worker[3009]-14 (out)] '[bencode decode error] 81.163.27.232:1027'
[female[1]-3 (err)] FATAL ERROR: CALL_AND_RETRY_2 Allocation failed - process out of memory
[female[1]-3 (out)]
[female[1]-3 (out)] ##############################################################
[female[1]-3 (out)] #
[female[1]-3 (out)] # !!! MONGOOSE WARNING !!!
[female[1]-3 (out)] #
[female[1]-3 (out)] # This is an UNSTABLE release of Mongoose.
[female[1]-3 (out)] # Unstable releases are available for preview/testing only.
[female[1]-3 (out)] # DO NOT run this in production.
[female[1]-3 (out)] #
[female[1]-3 (out)] ##############################################################
[female[1]-3 (out)]
[female[1]-3 (out)] Warning: Redis server does not require a password, but a password was supplied.

有很多错误。我的内存是16G的。那内存限制调成100M?

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

本地log:
2015-04-09T16:56:50.593Z - error: [bencode decode error] 109.106.141.34:5285
2015-04-09T16:57:10.789Z - error: [bencode decode error] 77.163.226.136:6881
2015-04-09T16:57:45.202Z - error: [bencode decode error] 92.105.21.205:51413
2015-04-09T16:58:03.076Z - error: [bencode decode error] 109.106.141.34:5285
2015-04-09T17:00:21.122Z - error: [bencode decode error] 194.186.211.6:62835
2015-04-09T17:05:01.802Z - error: [bencode decode error] 77.253.228.83:6881
2015-04-09T17:05:02.220Z - error: [bencode decode error] 194.158.205.190:62323
2015-04-09T17:08:55.604Z - error: [bencode decode error] 39.78.55.30:1059
2015-04-09T17:09:15.488Z - error: [bencode decode error] 81.163.27.232:1027
2015-04-09T17:12:48.539Z - error: [bencode decode error] 5.40.23.4:6881

from antcolony.

keenwon avatar keenwon commented on May 22, 2024

我只看到一个内存溢出,其他的无关紧要,bencode decode error这个错误没影响,是种子文件有问题
默认的配置是运行在1G的机器上的,你是16G的话,可以把限制提高点
也可以运行更多的进程,这样效率更高

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

调大female及其它内存限制到120,增加了3个female 仍然female内存溢出,是不是要重启下female,如何重启?

from antcolony.

keenwon avatar keenwon commented on May 22, 2024

重启就是pm2 restart id
如果是female的话,你看下.temp下是不是有很大的种子文件,解析太大的文件会比较占内存
不过你内存16G那么多,可以再调大点

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

我感觉怎么不像是内存限制的问题,我都调大到8000了还是有出错

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

目前启动了11个worker, 1个male, 3个female,是不是male太少了?

from antcolony.

keenwon avatar keenwon commented on May 22, 2024

关于比例问题,规则参考这个

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

female内存调到10000,开了5个,基本没问题了。现在又出来worker内存不够。
还有个问题想问下你的elasticsearch现在还需要不每天手动更新下?能不能自动更新?

from antcolony.

keenwon avatar keenwon commented on May 22, 2024

可以自动更新的,但是最初的方法效率比较低,没有正真使用。

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

现在worker老是重启,提示内存不够。我都把内存限制提到1000了,怎么还这样?

from antcolony.

keenwon avatar keenwon commented on May 22, 2024

还真没遇到过worker经常重启的,有可能是你的内存不足,或则你的频率太高了,调整试试
整套的AntColony是要“调教”的,每个时间段的配比是不一样的。

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

还有个问题。搜索你为什么选择elasticsearch, 为什么不选择sphinx呢

from antcolony.

keenwon avatar keenwon commented on May 22, 2024

@wdfsinap 随便选的,你熟悉sphinx的话,也可以用

from antcolony.

wdfsinap avatar wdfsinap commented on May 22, 2024

为毛mongodb能占用3.1G的内存?
6
开了21个worker,负载太大。

from antcolony.

keenwon avatar keenwon commented on May 22, 2024

正常的,mongodb本来就很占内存和硬盘,可以把数据库部在另一台机器上,这样影响小点。

from antcolony.

lock avatar lock commented on May 22, 2024

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

from antcolony.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.