Skip to content

Commit b08df08

Browse files
olethanhhoh
authored andcommitted
Set GOMEMLIMIT to avoid hitting the systemd limit and getting oom killed
1 parent fc961bf commit b08df08

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packaging/aleph-vm/etc/systemd/system/ipfs.service

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ ProtectHome=true
5050
RemoveIPC=true
5151
RestrictSUIDSGID=true
5252
CapabilityBoundingSet=CAP_NET_BIND_SERVICE
53+
# set memory limit to avoid taking all the CRN ressource and getting OOM
54+
# https://github.com/ipfs/kubo/blob/master/docs/config.md#swarmresourcemgrmaxmemory
55+
Environment=GOMEMLIMIT=1900m
5356
MemoryHigh=2G
5457
MemoryMax=4G
5558

0 commit comments

Comments
 (0)