WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Increase amount of inodes on rootfs  (Read 287 times)

Offline rhbvkleef

  • Newbie
  • *
  • Posts: 3
Increase amount of inodes on rootfs
« on: August 22, 2024, 08:37:38 AM »
Hi,

I am running into an issue where the root filesystem of my PiCore64 installation has run out of inodes. This is likely due to the fact that I run both a NodeJS-based application and a Python-based application on the system. Both have a significant amount of dependencies. Is there a way to alter the mount options of the root filesystem in order to increase this limit?

Regards,
Rolf

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1243
Re: Increase amount of inodes on rootfs
« Reply #1 on: August 22, 2024, 09:10:24 AM »
The calculation for inodes is done in /init   The only way to change this would be
1) Remaster the initrd
2) Since the rpi bootloader can concatenate initrd files, you can create a new initrd, with just a new version of init, then add that to the config.txt where it loads the initrds.

Offline rhbvkleef

  • Newbie
  • *
  • Posts: 3
Re: Increase amount of inodes on rootfs
« Reply #2 on: August 22, 2024, 09:17:39 AM »
Thanks for the super fast response. After looking further myself, I ended up remastering the initrd. I altered /etc/init.d/rcS to include the nr_inodes=0 flag for the root remount. I guess creating a separate initrd containing just the changed rcS is a nicer solution. I'd just have to add another initramfs entry to the config.txt? Would I have to calculate a correct offset for it, or will it figure that out itself if I set it to followkernel?

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1243
Re: Increase amount of inodes on rootfs
« Reply #3 on: August 22, 2024, 11:43:10 AM »
The pi bootloader handles the offsets automatically.  And the initrd's are concatenated in order.   We already do 2 on piCore (rootfs + kernel modules)

I use the mini initrd, when I'm experimenting.  Plus that way I'm sure I only modify the one file.