Home  >  Article  >  Database  >  Tor Linux relay服务器内存不足引起死机事件的解决

Tor Linux relay服务器内存不足引起死机事件的解决

WBOY
WBOYOriginal
2016-06-07 16:51:251204browse

运行Linux平台的Tor relay服务器二星期多,首次发现死机事件,查询日志最后死机前有如下记录:Mar 14 16:20:23 gateway kernel:

运行Linux平台的Tor relay服务器二星期多,首次发现死机事件,查询日志最后死机前有如下记录:

Mar 14 16:20:23 gateway kernel: tor invoked oom-killer: gfp_mask=0×40d0, order=1, oomkilladj=0
Mar 14 16:20:23 gateway kernel: [] out_of_memory+0×69/0×1a7
Mar 14 16:20:23 gateway kernel: [] __alloc_pages+0×21b/0×2a2
Mar 14 16:20:23 gateway kernel: [] __slab_alloc+0×17b/0×49f
Mar 14 16:20:23 gateway kernel: [] tcp_sendmsg+0×172/0xa30
Mar 14 16:20:23 gateway kernel: [] __kmalloc_track_caller+0×5d/0xa9
Mar 14 16:20:23 gateway kernel: [] tcp_sendmsg+0×172/0xa30

记录到这里系统就马上死机了。前段时间就发现Tor relay对内存需求挺大,1G物理内存都被用满了,已经开始占用更多的swap分区。

系统进程里显示其对CPU和内存的占用率都挺不低,,都分别在20%左右:

root 1718 23.6 20.0 294432 207072 Sl 16:27 4:13 /usr/local/bin/tor

看来每过段时间都要重启一下才行。

linux

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn