Skip to contentSkip to conversation

Zero free bytes incorrectly reported by initramfs

DISCUSSION Amos Waterland 1 participant 1 message Nov 26, 2007 VFS

lore
Share & tools
lore
#0 lore raw

Hi. The initramfs filesystem reports zero bytes free when queried with the statfs system call, even when there are 8 GB or more free memory.

This is a problem for me because I am building software appliances that run entirely out of an initramfs. I need to allow the user to install a package with apt-get (of course, the install will not be persistent across reboots). The apt-get source checks the f_bfree field in the statfs struct and bails out when it sees a zero.

I have submitted a patch[1] against apt-get to just blindly plow ahead if the filesystem type is RAMFS, but I would prefer to get some input from this list regarding the best way to proceed. Why does initramfs report zero bytes free?

--

[1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=448316