Re: Fix SWSUSP & !SWAP

John Bradford (john@grabjohn.com)
Thu, 24 Apr 2003 09:48:40 +0100 (BST)


> > That may be simple for you, but for lots of users, adding a partition
> > (to a ususally full disk drive) isn't simple. It means backups,
> > shrink a filesystem, shrink a partition, add a partition, and run
> > mkswap on it. Yes, the latter 2 are simple, but the former ones
> > are not.
>
> Yeah. swsusp is pretty much the only reason why you would want to have a
> swap partition at all in a 2.5/2.6 kernel.

A lot of users still follow the 'swap space twice the size of physical
RAM' rule of thumb.

Now that physical RAM sizes have increased by an order of magnitude
since that advice was given, there are a lot of systems with far more
swap than they need, which provides the solution to our problem - if
there is a single swap partition which is twice the size of physical
RAM, just split it in to SWAP and SWSUSP slices, (not separate
partitions, slices in the same way BSD subdivides a partition).

2.4 kernels will see a big swap area, and use all of it as swap, 2.5
kernels will see a smaller swap area, (equal to physical RAM size, and
therefore sufficient in a lot of cases), and a SWSUSP area the same
size as physical RAM.

John.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/