npm inodes issues in docker / kubernetes environment

10/28/2016

we have a kubernetes cluster environment which at any given time has around 10~20 pods/containers running on a single node. Each node has around 200k ish inodes available. However our micro service (nodejs/npm) app can each eats up around 20k+ inodes, and times that by say 10 pods/containers on a node that basically eats up all the available inodes on a server (node).

The question is if there is way to deal with this issue in the node_modules to minimize the number of files it contains or use some kind of bundler for the node_modules ??

-- Eatdoku
inode
kubernetes
microservices
node.js
npm

1 Answer

10/30/2016

There isn't really anything Kubernetes can do for you. You need to increase the number of inodes on your filesystem.

Without specifics on the size of your disks I can't give you exact advice. But, the details on the arch wiki about bytes per inode is the correct advice: https://wiki.archlinux.org/index.php/ext4#Bytes-per-inode_ratio

-- Brandon Philips
Source: StackOverflow