Skip to content
Snippets Groups Projects

Mention ram limits

Merged dakkar requested to merge mention-ram-limits into main
1 file
+ 28
1
Compare changes
  • Side-by-side
  • Inline
@@ -4,6 +4,31 @@ weight: 1300
toc: false
---
## My instance keeps crashing, saying "JavaScript heap out of memory", but I have plenty of RAM!
There are 2 problems here:
* `nodesjs` won't use more than a pre-determined amount of RAM (we can
change this)
* something causes Sharkey (and almost certainly Misskey) to randomly
allocate huge amounts of RAM and die (we would love to fix this, but
we haven't been able to figure out the cause, any help is
appreciated)
To tell `nodejs` to allocate up to (for example) 8GiB (8192MiB), you
can set the environment variable `NODE_OPTIONS`:
```bash
export NODE_OPTIONS='--max-old-space-size=8192'
```
in a startup script, or in your container options, or whatever works
for your particular setup. The important thing is that the `nodejs`
process (usually created via the `pnpm start` command) sees the
variable. Do *not* tell `nodejs` that it can allocate more RAM than
you have free!
## How do I enable note search?
You use the "roles" system. Log in as administrator, go to the
@@ -28,7 +53,9 @@ First of all, you need to generate a pair of so-called "VAPID" keys.
One way to do that is, from your Sharkey directory (git clone, or
inside the Docker image):
./packages/backend/node_modules/.bin/web-push generate-vapid-keys
```bash
./packages/backend/node_modules/.bin/web-push generate-vapid-keys
```
Alternatively, you can use [an online
generator](https://www.stephane-quantin.com/en/tools/generators/vapid-keys).
Loading