You are not logged in.
I'm on a new Dell XPS 13 that I've just set up.
Right now, when I boot, there is a minute and a half delay waiting for "dev-mapper-home.device" and "Create Volatile Volatile Files and Directories", which ultimately time out. After the timeout, I can log in normally to my user account and even start X (I am posting this from the same machine).
A relevant sample from journalctl -r (reversed):
May 15 15:29:05 rosemary systemd[1]: Failed to start Create Volatile Files and Directories.
May 15 15:29:05 rosemary systemd[1]: systemd-tmpfiles-setup.service: Main process exited, code
May 15 15:29:05 rosemary systemd-tmpfiles[257]: Cannot set file attribute for '/var/log/journa
May 15 15:29:05 rosemary systemd-tmpfiles[257]: Cannot set file attribute for '/var/log/journa
May 15 15:29:05 rosemary systemd-tmpfiles[257]: Cannot set file attribute for '/var/log/journa
May 15 15:29:05 rosemary systemd-tmpfiles[257]: Failed to adjust quota for subvolume "/home":
May 15 15:29:05 rosemary systemd[1]: dev-mapper-home.device: Job dev-mapper-home.device/start
May 15 15:29:05 rosemary systemd[1]: home.mount: Job home.mount/start failed with result 'depe
May 15 15:29:05 rosemary systemd[1]: user@1000.service: Job user@1000.service/start failed wit
May 15 15:29:05 rosemary systemd[1]: Dependency failed for User Manager for UID 1000.
May 15 15:29:05 rosemary systemd[1]: Dependency failed for /home.
May 15 15:29:05 rosemary systemd[1]: Timed out waiting for device dev-mapper-home.device.
May 15 15:29:05 rosemary systemd[1]: dev-mapper-home.device: Job dev-mapper-home.device/start
On my system, I followed the instructions on these two pages:
* https://wiki.archlinux.org/index.php/Dm … ile_system
* https://wiki.archlinux.org/index.php/Dm … g_at_login
to set up an encrypted /home partition that is decrypted through PAM when I enter my login password. My fstab is:
#
# /etc/fstab: static file system information
#
# <file system> <dir> <type> <options> <dump> <pass>
# /dev/nvme0n1p3
UUID=<redacted> / ext4 rw,relatime,data=ordered 0 1
# /dev/nvme0n1p4
/dev/mapper/home /home ext4 rw,noatime,noauto,nofail,x-systemd.automount 0 0
# /dev/nvme0n1p1
UUID=<redacted> /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro 0 2
And the relevant line from /etc/pam.d/system-local-login:
auth optional pam_exec.so expose_authtok /usr/bin/cryptsetup open /dev/disk/by-partlabel/home home
I removed the entry from /etc/crypttab because I don't want it to be mounted at *boot*, but rather at *login*, through the pam_exec script.
As you can see from the fstab, I also set the passno to 0 on /dev/mapper/home, to test the theory that it was systemd-fsck@.service that was trying to access /dev/mapper/home before login, but that hasn't solved the problem either. I also added noauto and even nofail in an attempt to skip it if the mapping doesn't exist. If I take off x-systemd.automount, the hang goes away, but /home never gets mounted, so I end up logged in at / with an empty /home.
My theory is that something during boot is trying to do disk i/o in /home, causing x-systemd.automount to attempt to mount the partition. But I'm not sure how to test that theory, or if it was correct how I would find out what that process is.
Last edited by jneen (2017-05-15 23:12:45)
Offline
The fstab entry is for /home not /home/username
Edit:
Welcome to the arch linux forums jneen.
Edit2:
The journal also seems to note what caused the access to /home
May 15 15:29:05 rosemary systemd-tmpfiles[257]: Failed to adjust quota for subvolume "/home":
Last edited by loqs (2017-05-15 23:37:20)
Offline
There's this mount option that might help somehow:
x-systemd.requires=
Configures a Requires= and an After= dependency between the created mount unit and
another systemd unit, such as a device or mount unit. The argument should be a unit
name, or an absolute path to a device node or mount point.
Offline
@Ropid, no, the only thing needed by home.mount is dev-mapper-home.device (/dev/mapper/home), which will only present after the the encrypted partition is opened; it is already in home.mount's BindsTo= anyway, while BindsTo= implies Requires= as well.
May 15 15:29:05 rosemary systemd[1]: user@1000.service: Job user@1000.service/start failed wit May 15 15:29:05 rosemary systemd[1]: Dependency failed for User Manager for UID 1000
Why would these show up before you got the login prompt?
P.S. Do you use a Display Manager (simply put, GUI login prompt)? If so, what if you boot the system with it disabled?
Last edited by tom.ty89 (2017-05-16 17:03:25)
Offline