Running out of inodes during "pmbootstrap install"
For some device + UI combinations, copying data into the image at the end of pmbootstrap install
fails with errors like (job):
[09:22:24] (native) % cd /mnt/rootfs_pine64-pinebookpro; cp -a usr lib run sys srv tmp mnt var media root boot dev sbin proc opt bin etc /mnt/install/
cp: can't create '/mnt/install/etc/skel/.profile': No space left on device
cp: can't create directory '/mnt/install/etc/skel/.config': No space left on device
cp: can't create directory '/mnt/install/etc/signon-ui': No space left on device
cp: can't create '/mnt/install/etc/fstab': No space left on device
cp: can't create '/mnt/install/etc/doas.conf': No space left on device
I have mostly seen this with plasma mobile and plasma desktop, for example: master:pine64-pinebookpro:plasma-desktop
. But this doesn't mean it is the fault of these UIs, these just happen to install a lot of small files.
df -i
shows that we are running out of inodes:
build:~$ df -i -h
Filesystem Inodes IUsed IFree IUse% Mounted on
devtmpfs 487K 185 487K 1% /dev
shm 491K 2 491K 1% /dev/shm
/dev/vda3 1.4M 120K 1.3M 9% /
tmpfs 800K 68 800K 1% /run
/dev/vda1 25K 25 25K 1% /boot
tmpfs 491K 22 491K 1% /home/build/.local/var/pmbootstrap/chroot_native/dev
tmpfs 491K 1 491K 1% /home/build/.local/var/pmbootstrap/chroot_native/dev/shm
/dev/installp2 98K 98K 0 100% /home/build/.local/var/pmbootstrap/chroot_native/mnt/install
/dev/installp1 58K 124 57K 1% /home/build/.local/var/pmbootstrap/chroot_native/mnt/install/boot
Looking at pmb/install/format.py
, we actually hardcode the ~100K inodes currently.
This has been previously discussed here years ago:
- https://gitlab.com/postmarketOS/pmbootstrap/-/issues/1717
- https://gitlab.com/postmarketOS/pmbootstrap/-/issues/1845
The key takeaway was that we do need to specify an amount of inodes as the default is not enough. But the default we used earlier is clearly too small, I'll prepare a patch to increase it.
Created this issue so we don't need to reference the old ones in the source anymore.