Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] does systemd really unmount /var (or /home)?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Vrenn
Apprentice
Apprentice


Joined: 15 Dec 2004
Posts: 286

PostPosted: Tue May 19, 2015 4:53 pm    Post subject: [solved] does systemd really unmount /var (or /home)? Reply with quote

Hello dear gentoo-experts!

I'm currently installing a gentoo-system on an UEFI-Asus G751.
It has an ssd and an hdd.
For compilation I have var on separate hdd-partition but on shutting down journalctl tells me var can't be unmounted.
Does gentoo do it afterwards?
How can I check that it really happened?
(ps: gentoo-sources with no init-ramdisk used)

Thanks for the help.

Code:
Mai 19 18:44:01 skl4 systemd[1]: Stopping Load/Save RF Kill Switch Status of rfkill0...
Mai 19 18:44:01 skl4 systemd[1]: Stopping Swap.
Mai 19 18:44:01 skl4 systemd[1]: Stopped target Swap.
Mai 19 18:44:01 skl4 systemd[1]: Stopping Update UTMP about System Boot/Shutdown...
Mai 19 18:44:01 skl4 systemd[1]: Stopping User and Session Slice.
Mai 19 18:44:01 skl4 systemd[1]: Removed slice User and Session Slice.
Mai 19 18:44:01 skl4 systemd[1]: Stopped Load/Save Random Seed.
Mai 19 18:44:01 skl4 systemd[1]: Stopped Load/Save RF Kill Switch Status of rfkill0.
Mai 19 18:44:01 skl4 systemd[1]: Stopped Update UTMP about System Boot/Shutdown.
Mai 19 18:44:01 skl4 systemd[1]: Stopping Create Volatile Files and Directories...
Mai 19 18:44:01 skl4 systemd[1]: Stopped Create Volatile Files and Directories.
Mai 19 18:44:01 skl4 systemd[1]: Stopping Local File Systems.
Mai 19 18:44:01 skl4 systemd[1]: Stopped target Local File Systems.
Mai 19 18:44:01 skl4 systemd[1]: Unmounting Temporary Directory...
Mai 19 18:44:01 skl4 systemd[1]: Unmounting /run/user/0...
Mai 19 18:44:01 skl4 systemd[1]: Unmounting /home...
Mai 19 18:44:01 skl4 systemd[1]: Stopping Flush Journal to Persistent Storage...
Mai 19 18:44:01 skl4 systemd[1]: Stopped Flush Journal to Persistent Storage.
Mai 19 18:44:01 skl4 systemd[1]: Stopping system-systemd\x2drfkill.slice.
Mai 19 18:44:01 skl4 systemd[1]: Removed slice system-systemd\x2drfkill.slice.
Mai 19 18:44:01 skl4 systemd[1]: Unmounting /var...
Mai 19 18:44:01 skl4 umount[7087]: umount: /var: Ziel ist in Benutzung.
Mai 19 18:44:01 skl4 umount[7087]: (In einigen Fällen finden Sie verwertbare Informationen
Mai 19 18:44:01 skl4 umount[7087]: über die Prozesse, die dieses Gerät nutzen, mit lsof(8)
Mai 19 18:44:01 skl4 umount[7087]: oder fuser(1)).
Mai 19 18:44:01 skl4 systemd[1]: var.mount mount process exited, code=exited status=32
Mai 19 18:44:01 skl4 systemd[1]: Failed unmounting /var.
Mai 19 18:44:01 skl4 systemd[1]: Unmounted /run/user/0.
Mai 19 18:44:01 skl4 systemd[1]: Unmounted Temporary Directory.
Mai 19 18:44:01 skl4 systemd[1]: Unmounted /home.
Mai 19 18:44:01 skl4 systemd[1]: Starting Unmount All Filesystems.
Mai 19 18:44:01 skl4 systemd[1]: Reached target Unmount All Filesystems.
Mai 19 18:44:01 skl4 systemd[1]: Stopping Local File Systems (Pre).
Mai 19 18:44:01 skl4 systemd[1]: Stopped target Local File Systems (Pre).
Mai 19 18:44:01 skl4 systemd[1]: Stopping Create Static Device Nodes in /dev...
Mai 19 18:44:01 skl4 systemd[1]: Stopped Create Static Device Nodes in /dev.
Mai 19 18:44:01 skl4 systemd[1]: Stopping Remount Root and Kernel File Systems...
Mai 19 18:44:01 skl4 systemd[1]: Stopped Remount Root and Kernel File Systems.
Mai 19 18:44:01 skl4 systemd[1]: Starting Shutdown.
Mai 19 18:44:01 skl4 systemd[1]: Reached target Shutdown.
Mai 19 18:44:01 skl4 systemd[1]: Starting Final Step.
Mai 19 18:44:01 skl4 systemd[1]: Reached target Final Step.
Mai 19 18:44:01 skl4 systemd[1]: Starting Reboot...
Mai 19 18:44:01 skl4 systemd[1]: Shutting down.
Mai 19 18:44:01 skl4 systemd-journal[226]: Journal stopped
-- Reboot --

_________________
With nice greetings
Vrenn


Last edited by Vrenn on Sun May 24, 2015 5:50 pm; edited 1 time in total
Back to top
View user's profile Send private message
steveo314
n00b
n00b


Joined: 08 Sep 2006
Posts: 34
Location: 38.7789° N, 90.6031° W

PostPosted: Tue May 19, 2015 7:12 pm    Post subject: Reply with quote

try shutting down from the terminal by entering "systemctl poweroff" and see if you get the same error. Run that after you enter su or sudo su. I dont remember if non-root can use systemctl.


It has been a known issue for some years though:
http://lists.freedesktop.org/archives/systemd-devel/2014-October/024373.html
https://bbs.archlinux.org/viewtopic.php?id=150442
Back to top
View user's profile Send private message
Vrenn
Apprentice
Apprentice


Joined: 15 Dec 2004
Posts: 286

PostPosted: Wed May 20, 2015 8:40 am    Post subject: Reply with quote

Quote:
try shutting down from the terminal by entering "systemctl poweroff" and see if you get the same error.
My eyes are old and my system is a core i7 on an pci-ssd. shutting down just gives me some too fast green and white lights before power off ;-)

I don't know if i can rely on journald's Reached target Unmount All Filesystems. How can I check it?
Does systemd do a second unmount-try after stopping journald?
Can I stop journald before var.mount?
_________________
With nice greetings
Vrenn
Back to top
View user's profile Send private message
Vrenn
Apprentice
Apprentice


Joined: 15 Dec 2004
Posts: 286

PostPosted: Sun May 24, 2015 5:48 pm    Post subject: Reply with quote

solved problem by move all /var back to root-partition (cp -av for the permissions) and making the old /var partition a /var/tmp partition for compile and other things.

Now journald just complies of unmount fail of /home
Code:
Mai 24 18:05:19 skl4 systemd[1]: Stopped target System Initialization.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Load/Save RF Kill Switch Status of rfkill0...
Mai 24 18:05:19 skl4 systemd[1]: Stopping Apply Kernel Variables...
Mai 24 18:05:19 skl4 systemd[1]: Stopped Apply Kernel Variables.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Setup Virtual Console...
Mai 24 18:05:19 skl4 systemd[1]: Stopped Setup Virtual Console.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Update UTMP about System Boot/Shutdown...
Mai 24 18:05:19 skl4 systemd[1]: Stopping Load Kernel Modules...
Mai 24 18:05:19 skl4 systemd[1]: Stopped Load Kernel Modules.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Load/Save RF Kill Switch Status of rfkill1...
Mai 24 18:05:19 skl4 systemd[1]: Stopping Load/Save Random Seed...
Mai 24 18:05:19 skl4 systemd[1]: Stopping Swap.
Mai 24 18:05:19 skl4 systemd[1]: Stopped target Swap.
Mai 24 18:05:19 skl4 systemd[1]: Stopped Load/Save RF Kill Switch Status of rfkill0.
Mai 24 18:05:19 skl4 systemd[1]: Stopped Update UTMP about System Boot/Shutdown.
Mai 24 18:05:19 skl4 systemd[1]: Stopped Load/Save RF Kill Switch Status of rfkill1.
Mai 24 18:05:19 skl4 systemd[1]: Stopped Load/Save Random Seed.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Create Volatile Files and Directories...
Mai 24 18:05:19 skl4 systemd[1]: Stopped Create Volatile Files and Directories.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Local File Systems.
Mai 24 18:05:19 skl4 systemd[1]: Stopped target Local File Systems.
Mai 24 18:05:19 skl4 systemd[1]: Unmounting Temporary Directory...
Mai 24 18:05:19 skl4 systemd[1]: Unmounting /var/tmp...
Mai 24 18:05:19 skl4 systemd[1]: Unmounting /run/user/1000...
Mai 24 18:05:19 skl4 umount[1024]: umount: /tmp: Ziel ist in Benutzung.
Mai 24 18:05:19 skl4 umount[1024]: (In einigen Fällen finden Sie verwertbare Informationen
Mai 24 18:05:19 skl4 umount[1024]: über die Prozesse, die dieses Gerät nutzen, mit lsof(8)
Mai 24 18:05:19 skl4 umount[1024]: oder fuser(1)).
Mai 24 18:05:19 skl4 systemd[1]: Unmounting /run/user/0...
Mai 24 18:05:19 skl4 umount[1027]: umount: /run/user/1000: Ziel ist in Benutzung.
Mai 24 18:05:19 skl4 umount[1027]: (In einigen Fällen finden Sie verwertbare Informationen
Mai 24 18:05:19 skl4 umount[1027]: über die Prozesse, die dieses Gerät nutzen, mit lsof(8)
Mai 24 18:05:19 skl4 umount[1027]: oder fuser(1)).
Mai 24 18:05:19 skl4 systemd[1]: Unmounting /home...
Mai 24 18:05:19 skl4 systemd[1]: Stopping system-systemd\x2drfkill.slice.
Mai 24 18:05:19 skl4 umount[1030]: umount: /home: Ziel ist in Benutzung.
Mai 24 18:05:19 skl4 umount[1030]: (In einigen Fällen finden Sie verwertbare Informationen
Mai 24 18:05:19 skl4 umount[1030]: über die Prozesse, die dieses Gerät nutzen, mit lsof(8)
Mai 24 18:05:19 skl4 umount[1030]: oder fuser(1)).
Mai 24 18:05:19 skl4 systemd[1]: Removed slice system-systemd\x2drfkill.slice.
Mai 24 18:05:19 skl4 systemd[1]: tmp.mount mount process exited, code=exited status=32
Mai 24 18:05:19 skl4 systemd[1]: Failed unmounting Temporary Directory.
Mai 24 18:05:19 skl4 systemd[1]: run-user-1000.mount mount process exited, code=exited status=32
Mai 24 18:05:19 skl4 systemd[1]: Failed unmounting /run/user/1000.
Mai 24 18:05:19 skl4 systemd[1]: home.mount mount process exited, code=exited status=32
Mai 24 18:05:19 skl4 systemd[1]: Failed unmounting /home.
Mai 24 18:05:19 skl4 systemd[1]: Unmounted /run/user/0.
Mai 24 18:05:19 skl4 systemd[1]: Unmounted /var/tmp.
Mai 24 18:05:19 skl4 systemd[1]: Starting Unmount All Filesystems.
Mai 24 18:05:19 skl4 systemd[1]: Reached target Unmount All Filesystems.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Local File Systems (Pre).
Mai 24 18:05:19 skl4 systemd[1]: Stopped target Local File Systems (Pre).
Mai 24 18:05:19 skl4 systemd[1]: Stopping Create Static Device Nodes in /dev...
Mai 24 18:05:19 skl4 systemd[1]: Stopped Create Static Device Nodes in /dev.
Mai 24 18:05:19 skl4 systemd[1]: Stopping Remount Root and Kernel File Systems...
Mai 24 18:05:19 skl4 systemd[1]: Stopped Remount Root and Kernel File Systems.
Mai 24 18:05:19 skl4 systemd[1]: Starting Shutdown.
Mai 24 18:05:19 skl4 systemd[1]: Reached target Shutdown.
Mai 24 18:05:19 skl4 systemd[1]: Starting Final Step.
Mai 24 18:05:19 skl4 systemd[1]: Reached target Final Step.
Mai 24 18:05:19 skl4 systemd[1]: Starting Power-Off...
Mai 24 18:05:19 skl4 systemd[1]: Shutting down.
Mai 24 18:05:19 skl4 systemd-shutdown[1]: Sending SIGTERM to remaining processes...
Mai 24 18:05:19 skl4 systemd-journal[245]: Journal stopped
-- Reboot --
Solution for me at now: KillUserProcesses=1 in logind.conf (or in kde-misc/kcmsystemd)
This should be save?
Please leave your opinion!
_________________
With nice greetings
Vrenn
Back to top
View user's profile Send private message
gsurbey
Apprentice
Apprentice


Joined: 24 Mar 2003
Posts: 212
Location: Nashua, NH

PostPosted: Mon Dec 18, 2017 3:08 am    Post subject: Reply with quote

This issue where systemd can't unmount a separately mounted /var partition because journald is still writing to /var is known about in the upstream systemd project. Here, poettering says that this issue is simply a cosmetic error and that the unmount will ultimately happen later on in the whole shutdown process. I want to believe him, but I'm still worried about data integrity. Here, mbiebl suggests a workaround, and in a follow-up post describes some minor downsides to using his workaround.

Here is my attempt at mbiebl's workaround:
Code:
mkdir -p /etc/systemd/system/systemd-journald.service.d/
echo "[Unit]" > /etc/systemd/system/systemd-journald.service.d/00-var-umount-workaround.conf
echo "RequiresMountsFor=/var/log/journal" >> /etc/systemd/system/systemd-journald.service.d/00-var-umount-workaround.conf
systemctl daemon-reload
systemctl restart systemd-journald
# You'll now see the new setting listed at the bottom of:
systemctl cat systemd-journald.service


Although, my attempt at implementing the above workaround did not actually fix it for me, and I still get the umount error. So if anyone wanted to reply with any additional suggestions, they are welcome :-)
_________________
-Greg Surbey
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum