Out of memory: Killed process 442 (node) total-vm:23193060kB

I am on the cheapest, near-free tier of Fly, using a wasp app. I upload a 20 mb audio file and my app does some processing on it–think transcribing, pulling out keywords, etc.

Any idea why this happens? How much memory is available on this tier of Fly and how do I know how much more to buy?

Out of memory: Killed process 442 (node) total-vm:23193060kB, anon-rss:809028kB, file-rss:0kB, shmem-rss:0kB, UID:0 pgtables:3992kB oom_score_adj:0

Media processing can eat up a lot of memory. You’ll have to look at the logs to see how much the process is consuming. If the library you’re using as a max memory limit, set that.
You could use swap_size_mb and rent additional memory for spiky events but you won’t be able to use suspend w/ swap_size_mb.

How do I find that information in the logs?

I am at 1024MB memory, which I would think should be enough for uploading a 20mb file :slight_smile:

Ill look into swap_size_mb, thank you.

Looks like a combination of
[env]
NODE_OPTIONS=‘–max-old-space-size=1000’

swap_size_mb = 512

and setting available memory to 2gb has solved the problem.

My main concern here it that there is no “early warning” about servers crashing. Is there a good way to profile memory/predict potential issues with fly?

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.