Bug 165863
Summary: | swsusp swaps should be reinitialized | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Jeremy Katz <katzj> |
Component: | util-linux | Assignee: | Karel Zak <kzak> |
Status: | CLOSED RAWHIDE | QA Contact: | Ben Levenson <benl> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | rawhide | CC: | davej, notting |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2005-09-06 06:23:25 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | |||
Bug Blocks: | 150222 |
Description
Jeremy Katz
2005-08-12 21:38:53 UTC
I vote for swapon. :) Doesn't seem insane, so -> util-linux I'm really not sure if destroy data on any partition automatically without user's confirmation is good idea. I think clean solution should be something like: "Detected old swsuspend partition. Do you want to re-initialize it to standard system swap? (y/N)" ... and it's work for system startup scripts of course :-) It should not be problem add one "if [...]" before swapon call in rc.sysinit. Comments? The problem is that if you _don't_ do it, then we get data corruption the next time you boot the older kernel that you had suspended on. Also, doing it from initscripts is not at all trivial given things like swap labeling. How can I detect swsuspend-swap partition? I mean difference between standard system swap and swap with old swsuspend data. I need a way how determine when call mkswap. I think better than change something in the swapon command will be create new swapstatus command that we can use in some if[...] in rc.sysinit. Things like swap labeling aren't problem (see the blkid command) -- but label and uuid could be part of swapstatus output too. swsuspend changes the swap space header (typically SWAPSPACE2) to contain either S1SUSP or S2SUSP, thus it's really easy to tell the difference. Well, after investigation I think implement it to swapon is more simple way :-) Implemented: util-linux-2.13-0.3.pre2 |