Bug 1123170

Summary: shutdown often fails entirely or hangs for a very long time (Fedora 21, ~2014-07)
Product: [Fedora] Fedora Reporter: Adam Williamson <awilliam>
Component: dracutAssignee: dracut-maint-list
Status: CLOSED WORKSFORME QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 21CC: awilliam, dracut-maint-list, harald, johannbg, jonathan, j, kevin, lnykryn, msekleta, s, systemd-maint, vpavlin, zbyszek
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-09-11 02:44:50 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
log extract from just before i triggered the shutdown to where it cuts off none

Description Adam Williamson 2014-07-25 04:16:39 UTC
Created attachment 920781 [details]
log extract from just before i triggered the shutdown to where it cuts off

For the last few weeks I've noticed my desktop (running Fedora 21) has often failed to shut down properly, but haven't had time to get proper debugging on it.

Yesterday I left it shutting down for like five hours while I was working on some laptop testing and it eventually actually did power off, but today I've tried leaving it for 2-3 hours and it didn't complete shutdown. I have systemd.debug log from that failed attempt, up until when the journal stopped logging, and I'll attach those.

nirik says he's seen something similar but also hadn't had time to trace it out yet. I'll try and get a *full* debug log soon.

Comment 1 Lennart Poettering 2014-08-05 10:59:26 UTC
This happens after systemd transitioned into "systemd-shutdown". WHich is the last step of everything, where we simply kill all remaining processes (of which journald is one) and then go back to the initrd to do the last bits. Since there's very little code in systemd itself that runs that late, I'd bet this hang is in dracut. 

Do you have any kind of complex storage? LVM? RAID? iscsi?

Comment 2 Harald Hoyer 2014-08-15 09:44:02 UTC
to debug the dracut shutdown, do:

# mkdir -p /run/initramfs/etc/cmdline.d
# echo "rd.debug rd.break=pre-shutdown rd.break=shutdown" \
  > /run/initramfs/etc/cmdline.d/debug.conf
# touch /run/initramfs/.need_shutdown

Comment 3 Adam Williamson 2014-08-21 21:13:13 UTC
Thanks guys, I'll check if this is still happening soon and debug if necessary. Yes, I have LVM, I also have NFS and CIFS shares, and SSSD (FreeIPA) auth.

Comment 4 Adam Williamson 2014-09-11 02:44:50 UTC
My last couple of reboots seem to have gone OK, so let's call this working for now.

Comment 5 Adam Williamson 2014-11-05 07:27:27 UTC
FWIW this is actually still happening all the time, but it's probably the same thing as (at least one of the bugs in) https://bugzilla.redhat.com/show_bug.cgi?id=1088619 , and I never seem to have time to sit down and debug it properly, so I'll leave it until I do have some decent data to re-open or whatever.