node's spawn internally uses fork() which duplicates the memory of the parent process. On systems where the node heap is larger than 50% of the host memory, this results in spawn ENOMEM errors when spawning ffprobe.
Ideally the ffprobe check should be split out into a separate process from the beginning to avoid needing to fork the main process for each lookup. Eventually I want to move all the media lookup logic into a separate daemon but for now forking a dummy process at startup and using that to fork future ffprobes might work.
Has happened a few times now.
node's
spawn
internally usesfork()
which duplicates the memory of the parent process. On systems where the node heap is larger than 50% of the host memory, this results inspawn ENOMEM
errors when spawningffprobe
.Ideally the ffprobe check should be split out into a separate process from the beginning to avoid needing to fork the main process for each lookup. Eventually I want to move all the media lookup logic into a separate daemon but for now forking a dummy process at startup and using that to fork future ffprobes might work.