[Ovirt-devel] [PATCH node] Changed how max swap size is calculated.

Alan Pevec apevec at gmail.com
Thu Jan 15 09:50:35 UTC 2009


On Thu, Jan 15, 2009 at 9:21 AM, Itamar Heim <iheim at redhat.com> wrote:

> > From: ovirt-devel-bounces at redhat.com [mailto:ovirt-devel-
> > bounces at redhat.com] On Behalf Of Darryl L. Pierce
> >
> > NOTE: this version removes the upper limit on swap size and only uses
> >       the calculated value if no size was specified.
> [IH] I assume it can't be larger than (<actual disk size>-<min space of
> other partitions>)?
> do we fail in such a case, or do we auto adjust the swap size?
>

It would fail somewhere later: Swap LV is created first, then Root, Config
and Logging and finally the rest of PV is allocated to Data LV.
Sanity checks and error recovery are not implemented, there's FIXME comment
in check_partition_sizes():

    # FIXME: use this function before performing any partitioning, auto or
> not
>     :
>     # Perform some sanity checks.  E.g.,
>     # What if DATA_SIZE ends up zero or negative?


DATA_SIZE is not calculated, so Data LV creation with 100%FREE would fail

    # What if any of those partition sizes is smaller than
>     # the minimum size for an ext3 partition?  Diagnose it here
>     # or just let the mke2fs failure suffice.
>

let mke2fs fail, but error conditions must be clearly reported. Currently
perform_partitioning() has set -e and stops silently on any failure.

To summarize, error recovery or sanity checks are not worth the effort IMO,
but we need to improve error and progress report (currently all output goes
to both logfile and console).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/ovirt-devel/attachments/20090115/2205a43c/attachment.htm>


More information about the ovirt-devel mailing list