sakaki- / gentoo-on-rpi-64bit

Bootable 64-bit Gentoo image for the Raspberry Pi4B, 3B & 3B+, with Linux 5.4, OpenRC, Xfce4, VC4/V3D, camera and h/w codec support, weekly-autobuild binhost
GNU General Public License v3.0
918 stars 126 forks source link

F2FS on RPi4 image #138

Closed TheChymera closed 4 years ago

TheChymera commented 4 years ago

So I am trying to run my rootfs as F2FS. On a RPi3 (with the rpi3 lite image) it works fine, but on my RPi4 (with the pri4 lite image) it fails. The image works fine on the RPi4 with ext4. Here's how I do it:

mkdir myrpi
mount /dev/sdd2 /mnt/rpi
rsnyc -avP /mnt/rpi/* myrpi/
umount /dev/sdd2
mkfs.f2fs -f /dev/sdd2
mount /dev/sdd2 /mnt/rpi
rsync -avP myrpi/* /mnt/rpi/
mount /dev/sdd1 /mnt/rpi/boot
sed -i -e "s/ext4/f2fs/g" /mnt/rpi/boot/cmdline.txt
sed -i -e "s/ext4/f2fs/g" /mnt/rpi/etc/fstab
umount /dev/sdd1
umount /dev/sdd2

What happens on the rpi4 after I reboot is that:

  1. The hostname is displayed as (none).
  2. The filesystem is mounted read-only (I can remount it manually but I need to do this every time)
  3. e.g. nmtui fails with Could not contact NetworkManager: Coul not connect: No such file or directory.

Any idea what's wrong?

TheChymera commented 4 years ago

Ok, this appears to be a known f2fs-tools issue: https://bugs.gentoo.org/671786