Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 569316 - Systemd error when using separate /var partition
Summary: Systemd error when using separate /var partition
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal enhancement with 1 vote (vote)
Assignee: Gentoo systemd Team
URL: https://bbs.archlinux.org/viewtopic.p...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-12-23 11:29 UTC by Paul Osmialowski
Modified: 2015-12-27 16:51 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emerge-info.txt,16.36 KB, text/plain)
2015-12-23 11:32 UTC, Paul Osmialowski
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Osmialowski 2015-12-23 11:29:18 UTC
Just to let you know that the problem exists as it is systemd-specific and therefore probably unfixable - I won't have much time to spend on it.

I spotted this recently on rarely rebooted machine:

Dec 23 10:57:25 localhost systemd[1]: Unmounted /var/tmp/portage.
Dec 23 10:57:25 localhost systemd[1]: Unmounting /var...
Dec 23 10:57:25 localhost kernel: XFS (sda7): Unmounting Filesystem
Dec 23 10:57:25 localhost kernel: XFS (sda9): Unmounting Filesystem
Dec 23 10:57:25 localhost umount[1197]: umount: /var: cel jest zajęty.
Dec 23 10:57:25 localhost umount[1197]: (W niektórych przypadkach informacje o procesach korzystających
Dec 23 10:57:25 localhost umount[1197]: z urządzenia można znaleźć przy pomocy lsof(8) lub fuser(1).)
Dec 23 10:57:25 localhost systemd[1]: var.mount: Mount process exited, code=exited status=32
Dec 23 10:57:25 localhost systemd[1]: Failed unmounting /var.
**************************************^^^^^^^^^^^^^^^^^^^^^^^
Dec 23 10:57:25 localhost systemd[1]: Unmounted /boot.
Dec 23 10:57:29 localhost systemd[1]: Unmounted /opt.
Dec 23 10:57:29 localhost systemd[1]: Unmounted /mnt/drugi.
Dec 23 10:57:29 localhost systemd[1]: Unmounted /home.
Dec 23 10:57:29 localhost systemd[1]: Unmounted /tmp.
Dec 23 10:57:29 localhost systemd[1]: Reached target Unmount All Filesystems.
Dec 23 10:57:29 localhost systemd[1]: Stopped target Local File Systems (Pre).
Dec 23 10:57:29 localhost systemd[1]: Stopped Create Static Device Nodes in /dev.
Dec 23 10:57:29 localhost systemd[1]: Stopped Remount Root and Kernel File Systems.
Dec 23 10:57:29 localhost systemd[1]: Reached target Shutdown.
Dec 23 10:57:29 localhost systemd[1]: Reached target Final Step.
Dec 23 10:57:29 localhost systemd[1]: Starting Power-Off...
Dec 23 10:57:29 localhost systemd[1]: Shutting down.
Dec 23 10:57:29 localhost systemd-shutdown: Sending SIGTERM to remaining processes...
Dec 23 10:57:29 localhost systemd-journal[169]: Journal stopped

The problem is well addressed on https://bbs.archlinux.org/viewtopic.php?id=154144
As this topic started 2012-12-05 12:28:42 and the last entry is 2015-11-09 19:32:51 I assume that if the solution was possible it whould already be fixed, therefore it's unfixable.


Reproducible: Always

Steps to Reproduce:
1. Install Gentoo with systemd and /var on separate partition
2.
3.
Actual Results:  
/var cannot be unmounted cleanly as systemd uses journal till the very end

Expected Results:  
/var unmounted cleanly

sys-apps/systemd-226-r2 installed

Relevant line of fstab is:
/dev/sda6		/var		xfs		noatime		1 2

Suggested systemd enchancement.
Comment 1 Paul Osmialowski 2015-12-23 11:32:11 UTC
Created attachment 420504 [details]
emerge --info
Comment 2 Till Schäfer 2015-12-26 12:57:55 UTC
This bug is also reported (and probably fixed in 227) upstream. Its a problem with journald that writes to var until the system stops.

https://github.com/systemd/systemd/issues/867

So maybe we should stabilize >=systemd-227 or backport the patches.

However, as far I understood the issue, the error is not causing any troubles with unclean filesystems. It seems that var is properly umounted later in the shutdown process.