On Thu, 2012-04-26 at 09:11 -0500, David Lehman wrote: > On Thu, 2012-04-26 at 15:20 +0200, Vratislav Podzimek wrote: > > On Thu, 2012-04-26 at 08:01 -0500, David Lehman wrote: > > > On Thu, 2012-04-26 at 08:35 +0200, Vratislav Podzimek wrote: > > > > On Wed, 2012-04-25 at 21:41 -0500, David Lehman wrote: > > > > > On Wed, 2012-04-25 at 15:44 +0200, Vratislav Podzimek wrote: > > > > > > Resolves: rhbz#815557 > > > > > > > > > > > > Simple patch making swap suggestions more flexible. However the new values are > > > > > > not consistent with the documentation [1] and the user may end up with a machine > > > > > > that cannot be hibernated. > > > > > > > > > > The hibernate question is a good one. Apparently there is no simple > > > > > solution that works for all cases. Go figure. > > > > > > > > > > I have one comment about the patch, below. > > > > > > > > > > > > > > > > > [1] https://bugzilla.redhat.com/show_bug.cgi?id=744129#c2 > > > > > > > > > > > > --- > > > > > > iutil.py | 12 ++++++------ > > > > > > 1 files changed, 6 insertions(+), 6 deletions(-) > > > > > > > > > > > > diff --git a/iutil.py b/iutil.py > > > > > > index f7254e2..f36ea83 100644 > > > > > > --- a/iutil.py > > > > > > +++ b/iutil.py > > > > > > @@ -455,23 +455,23 @@ def swapSuggestion(quiet=0): > > > > > > > > > > > > #table suggested in rhbz#744129 > > > > > > if mem <= 4096: > > > > > > - minswap = 2048 > > > > > > + minswap = 1024 > > > > > > maxswap = 2048 > > > > > > > > > > > > elif 4096 < mem <= 16384: > > > > > > - minswap = 4096 > > > > > > + minswap = 2048 > > > > > > maxswap = 4096 > > > > > > > > > > > > elif 16384 < mem <= 65536: > > > > > > - minswap = 8192 > > > > > > + minswap = 4096 > > > > > > maxswap = 8192 > > > > > > > > > > > > elif 65536 < mem <= 262144: > > > > > > - minswap = 16384 > > > > > > + minswap = 8192 > > > > > > maxswap = 16384 > > > > > > > > > > > > else: > > > > > > - minswap = 32768 > > > > > > + minswap = 16384 > > > > > > maxswap = 32768 > > > > > > > > > > > > if not quiet: > > > > > > @@ -488,7 +488,7 @@ def swapSameAsRam(quiet=0): > > > > > > #see #rhbz587152 > > > > > > if mem <= SWAP_SIZE_LIMIT: > > > > > > log.info("Swap attempt of %sM to %sM", mem, mem) > > > > > > - return (mem, mem) > > > > > > + return (mem / 2, mem) > > > > > > > > > > In this case I don't think you should be flexible. If they said they > > > > > want the same amount of swap as there is ram, give them exactly that. > > > > Well, the result of the discussion on rhbz#744129 was that if we change > > > > the swapSuggestion to suggest less swap than RAM, we can't use it in > > > > autopartitioning, because that would mean users with machines that > > > > cannot hibernate. So we decided to use swapSameAsRam for > > > > autopartitioning and the new bug (rhbz#815557) is the case of GUI > > > > installation with "Use all space". So summed up that means either > > > > rhbz#815557 is not a bug or this case has to be also flexible (which > > > > would resolve it). However making it flexible means again users with > > > > machines that cannot hibernate. > > > > > > So swapSuggestion produces a result that we don't think is acceptable > > > for autopart? In that case, why do we think it's acceptable for general > > > use ala kickstart's 'part swap --recommended'? It seems to me like we > > > should either never make recommendations that preclude hibernation or we > > > should never worry about hibernation when making them. > > That's beacause there is a --same-as-ram kickstart option and > > --recommended does the same that is recommended in the documentation. On > > the other hand we are expecting less experienced users will be using the > > 'GUI -> Use all space' option and such users shouldn't end up with a > > machine that cannot hibernate. > > > > > > > > If we use flexible size requests for swap, we can show a warning if swap > > > ends up being too small for hibernate. If we use fixed size requests we > > > may need to provide more information than "not enough space" when we can > > > see that swap requirement plus minimum root lv size is larger than the > > > vg. > > I am for the latter. Experienced users with a lot of RAM should be able > > to handle that situation. The former may be confusing for less > > experienced users. > > > > Do you agree? Shall I start to work on that modification? Do you mean by > > 'fixed size requests' both swapSuggestion and swapSameAsRam? > > I am okay with using same-as-ram for autopart, provided that we get > clearer error reporting for the more-ram-than-disk case. In that case, > would you leave swapSuggestion to still give flexible suggestions? According to the documentation and rhbz#744129 it shouldn't be flexible, because these values are suggested as both minimum and maximum. And the same for the swapSameAsRam. -- Vratislav Podzimek <vpodzime@xxxxxxxxxx> _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list