|
Bugzilla – Full Text Bug Listing |
| Summary: | HALT_POWERDOWN_INSERT is ignored under systemd | ||
|---|---|---|---|
| Product: | [openSUSE] openSUSE 12.2 | Reporter: | Andrei Borzenkov <arvidjaar> |
| Component: | Basesystem | Assignee: | Frederic Crozat <fcrozat> |
| Status: | RESOLVED FIXED | QA Contact: | E-mail List <qa-bugs> |
| Severity: | Minor | ||
| Priority: | P5 - None | CC: | bpetkov, forgotten_Ld-QSk4UDc, sbrabec |
| Version: | Final | ||
| Target Milestone: | --- | ||
| Hardware: | Other | ||
| OS: | openSUSE 12.2 | ||
| Whiteboard: | |||
| Found By: | --- | Services Priority: | |
| Business Priority: | Blocker: | --- | |
| Marketing QA Status: | --- | IT Deployment: | --- |
|
Description
Andrei Borzenkov
2012-10-18 15:20:23 UTC
Thanks, I'll try to integrate your solution *** Bug 788165 has been marked as a duplicate of this bug. *** Well, there is a question: Do we need to support HALT_POWERDOWN_INSERT in systemd? (Not thinking the about the late powerdown command feature, just about the HALT_POWERDOWN_INSERT sysconfig variable.) I introduced HALT_POWERDOWN_INSERT several years ago, because there was no easy way to create init script running in the late halt sequence. (There was only /etc/init.d/halt.local, but its use is a bit complicated for packages. (The file is intended for admin, and it had to be auto-edited by rpm scriptlets.) And it is called before stopping software RAID.) If systemd has a clean way to perform action just before calling the final poweroff, then HALT_POWERDOWN_INSERT is no more needed, and packages can use standard systemd integration. If it is true, we can update HALT_POWERDOWN_INSERT description and say, that it is systemv specific. What it would mean? Do not introduce the service proposed by you in the core systemd package, but add needed service to apcupsd and nut. I think that there were no other packages using this feature. (In reply to comment #3) > If systemd has a clean way to perform action just before calling the final > poweroff, then HALT_POWERDOWN_INSERT is no more needed, and packages can use > standard systemd integration. It has: final.target is run just before shutting down, so it can be used like HALT_POWERDOWN_INSERT. > If it is true, we can update HALT_POWERDOWN_INSERT description and say, that it > is systemv specific. > > What it would mean? Do not introduce the service proposed by you in the core > systemd package, but add needed service to apcupsd and nut. I think that there > were no other packages using this feature. I could integrate Andrey fix for 12.2 (since it is already released) and we follow your suggestion for Factory. WDYT ? I think I was mistaken. When this issue was raised on forums I did not get clear picture where packages originated. But now I see that both apcupsd and nut are in standard openSUSE 12.2 repositories. That makes it really problem of packages integration which has to be fixed in respective packages, not in systemd. I will rebuild apcupsd with proper system-shutdown script and ask user to test it. To Andrey: Thanks. It seems that this approach is upstream-able, as it will work on all distros. Note to HALT_POWERDOWN_INSERT introduction 6 years ago: In an ideal situation, it should be possible to shutdown correctly even without late poweroff command: Just initiate UPS grace period during the standard init script stop, and hope, that machine powers itself off in say 30 seconds. Real life is different: However it should not happen with a properly configured nut, we should be prepared for situation, when network storage is already out of power and unmounting network storage fails on timeout. Initiating grace period as late as possible gives as much time as battery permits. I'm not sure if this bug is related to my issue. I've got the problem of the PC never powering down even though I get the "System Halted" message ok (i escaped the shutdown splash to watch the shutdown). I expect the PC then to power off. (In reply to comment #7) > I'm not sure if this bug is related to my issue. I've got the problem of the > PC never powering down even though I get the "System Halted" message ok (i > escaped the shutdown splash to watch the shutdown). I expect the PC then to > power off. This is unrelated, you need to use "halt -p" to shutdown your computer (as explained in the manual). With sysvinit, we had a patch which was injecting "-p" on x86/x86_64 hardware without you noticing. (In reply to comment #8) > (In reply to comment #7) > > I'm not sure if this bug is related to my issue. I've got the problem of the > > PC never powering down even though I get the "System Halted" message ok (i > > escaped the shutdown splash to watch the shutdown). I expect the PC then to > > power off. > > This is unrelated, you need to use "halt -p" to shutdown your computer (as > explained in the manual). With sysvinit, we had a patch which was injecting > "-p" on x86/x86_64 hardware without you noticing. Unfortunately that made no difference at all. There is "Bug 794889 - Shutdown does not power off machine" created by someone else which is more relevant but no-one has looked at it. I had also posted to that one. I installed Fedora on an old laptop to check another issue and noticed it used "poweroff". So i tried it as well but it did the same thing, shut everything down okay but did not power off. if halt -p doesn't work, it is a kernel issue. (In reply to comment #10) > if halt -p doesn't work, it is a kernel issue. Unfortunatly it doesn't work either, nothing seems to power off the machine. so, it is not about this bug report. (In reply to comment #12) > so, it is not about this bug report. so it would appear. just hope someone gets time to look at logged fault to check to see if it affects 12.3 closing as fixed, since andrej pushed fixes for proper systemd integration in Factory So which systemd version has the fixes and how can I point people to it to try it out? I have a bug of two machines with similar symptoms (bnc#813244). Thanks. I think affected packages (UPS related) has been fixed in 12.3 to not rely on HALT_POWERDOWN_INSERT anymore. But we didn't integrate HALT_POWERDOWN_INSERT support in systemd for 12.3 (nor Factory) since it is deprecated. |