rwfus
rwfus copied to clipboard
RWFus failing to mount on brand new SteamOS Install
Hi there, I have a little issue 😅.
I followed the steps on your GitHub Readme to install RWFus on my brand new SteamOS install (SteamOS 3.3.1). But everytime (done multiple reinstalls) the mount systemd targets fail to mount because of a bad option in the mount command. Since I'm a Linux novice and not sure what I should do here I am asking you directly if you know anything.
I've been trying to reproduce this problem for a while now! Thanks for letting me know it happens on a fresh install. I'll do a fresh install on my Deck and get back to you as soon as I can!
I spent a good 12 hours troubleshooting this, and as it turns out, there's a major difference between how Valve formats the Deck at the factory, and a Deck that's been "recovered" using Valve's so-called recovery image.
Sometime between then and now, Valve started formatting the home partition with -O casefold
, and overlayFS will always fail when that option is enabled. This is never stated in any documentation AT ALL, ANYWHERE.
There are a few options from this point:
- Boot into a linux image that has a nightly build of tune2fs, and then use that to disable casefolding
- Resize nvme0n1p8 (/home) to provide more space for Rwfus, and then create a new partition to store Rwfus stuff in
- Repartition your Deck to use a filesystem which overlayfs supports (ext4, btrfs, ...), without casefolding enabled
As for me, I'm going to err on the side of caution, and test if casefolding is enabled on the target filesystem before proceeding, for now. It may be possible to fix this problem in a shell script, but I can't guarantee it'll work, and it has the potential to bork the deck bad enough to require reimaging with the recovery image. Rwfus was never meant to be anywhere near that invasive.
Here's my plan for solving this issue:
- Create a large, empty file
- Format the file with mkfs.[ext4|btrfs], without case-folding
- Bind-mount the file somewhere (maybe in a subdirectory of /opt?)
- Create the overlays as usual
TODO: How large should the file be?
Disabling Casefold is greatly discuraged if you work with Windows Applications. Especially on the Steam Deck. Games WILL break with it off.
Disabling Casefold is greatly discuraged if you work with Windows Applications. Especially on the Steam Deck. Games WILL break with it off.
Wine/Proton implements user-space casefolding, which will kick in if native casefolding is not available. It's just slower than the filesystem driver implementation. If you haven't reimaged your Deck, your home partition will have ext4 casefolding disabled. You'll know this is the case if Rwfus works for you. Windows games still work, falling back to Wine/Proton's casefolding implementation.
I had multiple games failing while loading dlls with diffrent names in the Hardcoding than they have in the Folder.
Wines Casefolding is not a catch all. Just as a Information. In case people wonder why their stuff is not working.
This should be fixed on dev branch as of this morning. I've instituted a workaround, creating a 4GB (sparse, it doesn't actually take up 4GB even if it says it does) disk image w/ btrfs on it, and storing all the upper and workdirs in that. Hopefully, that doesn't have any weird gotchas.
This should be fixed on dev branch as of this morning. I've instituted a workaround, creating a 4GB (sparse, it doesn't actually take up 4GB even if it says it does) disk image w/ btrfs on it, and storing all the upper and workdirs in that. Hopefully, that doesn't have any weird gotchas.
It is useful,but it only 4GB can be used?
4GB at the moment, yeah. I should probably add that to the config file, but I chose 4GB because it's ~4x the size of the largest Rwfus directories I found when asking around on the Steam Deck Homebrew discord. The size doesn't matter in my testing. With compression enabled, mine is 56MB, down from 480MB I think I'll double it for the main release, and add some way to grow the maximum size of the disk.
Rwfus 0.4.0 defaults to 8GB, and the size can be increased by editing /etc/opt/rwfus.conf and uncommenting the Disk_Image_Size
line. It takes any size you can pass to truncate -s
(because that's what ends up happening.)
Some examples: 8G, 8192M, 8388608K
Once the config file has been edited, run rwfus --update
to apply the new config.
Rwfus 0.4.0 defaults to 8GB, and the size can be increased by editing /etc/opt/rwfus.conf and uncommenting the
Disk_Image_Size
line. It takes any size you can pass totruncate -s
(because that's what ends up happening.) Some examples: 8G, 8192M, 8388608KOnce the config file has been edited, run
rwfus --update
to apply the new config.
It's perfect!
(deck@dodfsk rwfus)$ sudo systemctl status rwfusd.service
● rwfusd.service - Rwfus: Carry Pacman across SteamOS updates!
Loaded: loaded (/etc/systemd/system/rwfusd.service; enabled; vendor preset: disabled)
Active: active (exited) since Mon 2022-11-14 02:22:35 CST; 8s ago
Process: 21030 ExecStart=/opt/rwfus/service/rwfusd.sh --start (code=exited, status=0/SUCCESS)
Main PID: 21030 (code=exited, status=0/SUCCESS)
CPU: 69ms
11 14 02:22:35 dodfsk rwfusd.sh[21030]: Creating overlay (/opt/rwfus/mount/upper/etc-pacman.d, /opt/rwfus/mount/work/etc-pacman.d) on /etc/pacman.d
11 14 02:22:35 dodfsk rwfusd.sh[21057]: mount: overlay mounted on /etc/pacman.d.
11 14 02:22:35 dodfsk rwfusd.sh[21030]: Successfully overlaid /opt/rwfus/mount/upper/etc-pacman.d on /etc/pacman.d
11 14 02:22:35 dodfsk rwfusd.sh[21030]: Creating overlay (/opt/rwfus/mount/upper/var-lib-pacman, /opt/rwfus/mount/work/var-lib-pacman) on /var/lib/pacman
11 14 02:22:35 dodfsk rwfusd.sh[21059]: mount: overlay mounted on /var/lib/pacman.
11 14 02:22:35 dodfsk rwfusd.sh[21030]: Successfully overlaid /opt/rwfus/mount/upper/var-lib-pacman on /var/lib/pacman
11 14 02:22:35 dodfsk rwfusd.sh[21030]: Creating overlay (/opt/rwfus/mount/upper/var-cache-pacman, /opt/rwfus/mount/work/var-cache-pacman) on /var/cache/>
11月 14 02:22:35 dodfsk rwfusd.sh[21061]: mount: overlay mounted on /var/cache/pacman.
11月 14 02:22:35 dodfsk rwfusd.sh[21030]: Successfully overlaid /opt/rwfus/mount/upper/var-cache-pacman on /var/cache/pacman
11月 14 02:22:35 dodfsk systemd[1]: Finished Rwfus: Carry Pacman across SteamOS updates!.
lines 1-17/17 (END)
(148)(deck@dodfsk rwfus)$ ./rwfus --status
● rwfusd.service - Rwfus: Carry Pacman across SteamOS updates!
Loaded: loaded (/etc/systemd/system/rwfusd.service; enabled; vendor preset: disabled)
Active: active (exited) since Mon 2022-11-14 02:22:35 CST; 5min ago
Process: 21030 ExecStart=/opt/rwfus/service/rwfusd.sh --start (code=exited, status=0/SUCCESS)
Main PID: 21030 (code=exited, status=0/SUCCESS)
CPU: 69ms
Label: 'Rwfus' uuid: 85b9fe8e-b211-4c41-b717-b321bf4be428
Total devices 1 FS bytes used 115.52MiB
devid 1 size 8.00GiB used 428.00MiB path /opt/rwfus/rwfus.btrfs
Rwfus 0.4.0 defaults to 8GB, and the size can be increased by editing /etc/opt/rwfus.conf and uncommenting the
Disk_Image_Size
line. It takes any size you can pass totruncate -s
(because that's what ends up happening.) Some examples: 8G, 8192M, 8388608KOnce the config file has been edited, run
rwfus --update
to apply the new config.
Hey!there is a issue.When I reboot steamos, /var/cache/pacman will fail to mount with wrong fs type. This directory is from /home/.steamos/offload/var/cache. So i remove this path from /etc/opt/rwfus.conf. Then I reboot system and the service can be loaded correctly. Now,I add /var/cache/pacman path into config,it works. But after rebooting the system, it will print an error with mount /var/cache/pacman wrong fs type . cycle like this
of course,/usr /etc/pacman.d /var/lib/pacman,these three directories are enough
Ah! Knew something from steamos-offload would kick me in the butt. Seems overlayfs won't even accept a case-folding lowerdir. Shame on it, but I suppose that makes some sense. I'll have a fix soon, hopefully. My ideal is to have all the pacman state stored inside Rwfus, so when you wipe Rwfus or use the backup/restore functionality it's actually gone. Thanks for testing it out!