-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Closed as not planned
Labels
bug 🐛Programming errors, that need preferential fixingProgramming errors, that need preferential fixingduplicatehomedhomed, homectl, pam_homedhomed, homectl, pam_homed
Description
systemd version the issue has been seen with
v250
Used distribution
Archlinux
Linux kernel version used (uname -a)
Linux 5.16.0-arch1-1 #1 SMP PREEMPT Mon, 10 Jan 2022 20:11:47 +0000 x86_64 GNU/Linux
CPU architecture issue was seen on
x86-64
Expected behaviour you didn't see
Systemd-homed home area resized to specified size
Unexpected behaviour you saw
Home area stayed the same
Steps to reproduce the problem
- Format and mount
/homeusing XFS.- Create new user:
# homectl --storage=luks create foo- Log in with user foo and then log out (<= this is important, it changes the sparse size of
foo.home!)- Look at the actual and pre-allocated sparse size of the home area:
# ls -hals /home/foo.home
891G -rw------- 1 root root 25G Jan 14 15:42 /home/foo.home- Try resizing:
# homectl resize foo 200G
Looking at journalctl, systemd-homework tells me Couldn't change image size.
Activating debug mode shows that systemd-homework thinks there is no space left on the device.
Workaround
(hoping this will make sense and help find the bug)
- Reinitialise sparse size to actual size (
mv old tmp/cp tmp new/rm tmp):
# mv /home/foo.home /home/foo.home.tmp && cp /home/foo.home.tmp /home/foo.home && rm /home/foo.home.tmp- Without login in, resize right away:
# homectl resize foo 200G- Log in and out
# ls -hals /home/foo.home
201G -rw------- 1 root root 200G Jan 14 15:56 /home/foo.home
Note how now sparse allocation now matches the actual allocation (it does not take the full disk).
YokaiRick
Metadata
Metadata
Assignees
Labels
bug 🐛Programming errors, that need preferential fixingProgramming errors, that need preferential fixingduplicatehomedhomed, homectl, pam_homedhomed, homectl, pam_homed