Bug#406007: installation-report: RC1 installer (NSLU2) does not use swap before partitioning - Debian

This is a discussion on Bug#406007: installation-report: RC1 installer (NSLU2) does not use swap before partitioning - Debian ; reassign partman-base retitle problems with activating swap before partitioning thanks * R. Clobus [2007-01-07 22:28]: > I've partitioned a 1GB pendrive: > /dev/sda1 768MB ext3 > /dev/sda2 256MB swap > > When the sda1 partition is formatted, the installer quits, ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: Bug#406007: installation-report: RC1 installer (NSLU2) does not use swap before partitioning

  1. Bug#406007: installation-report: RC1 installer (NSLU2) does not use swap before partitioning

    reassign partman-base
    retitle problems with activating swap before partitioning
    thanks

    * R. Clobus [2007-01-07 22:28]:
    > I've partitioned a 1GB pendrive:
    > /dev/sda1 768MB ext3
    > /dev/sda2 256MB swap
    >
    > When the sda1 partition is formatted, the installer quits, because mkfs.ext3 segfaulted because
    > it ran out of memory.
    > I restarted the installer after I first had activated the swap partition, and then all went well.
    >
    > Could it be possible (especially in low-memory mode) to initialize and use the swap partition first,
    > and then try to run the remainder of the installer?


    Actually, this is what the installer does, are or least is supposed to
    do. Kevin Price ran into this problem too recently and I'm not sure
    how to interpret his finding. Maybe someone more familiar with
    partman (or the kernel?) can comment.

    Here is what Kevin found:

    | >> I think it should have formatted and activated swap first, and then
    | >> afterwards start formatting the ext3 partitions. That would avoid the error.
    | >
    | > That's what the installer does. It partitions the disk, formats and
    | > activates swap and then formats the other partitions.
    |
    | That surprises me. On a closer look into the log, you're right.
    |
    | From a user's POV, the first mkfs-ext3 attempt failed, but just starting
    | it again worked out ok.
    |
    | Now from looking into the log, it looks strange: It adds swap, then
    | attempts to format ext3, then comes OOM and kills mkfs.ext3. Then comes
    | the interesting part: It seems to add swap again. That time mkfs.ext3
    | runs OK. So maybe the first time adding swap, the swap gets disbled
    | immediately after, triggering OOM?
    |
    | See the attached log excerpt.

    --
    Martin Michlmayr
    http://www.cyrius.com/


  2. Bug#406007: installation-report: RC1 installer (NSLU2) does not use swap before partitioning

    On Sat, Sep 13, 2008 at 05:35, Martin Michlmayr wrote:

    > Actually, this is what the installer does, are or least is supposed to
    > do. Kevin Price ran into this problem too recently and I'm not sure
    > how to interpret his finding. Maybe someone more familiar with
    > partman (or the kernel?) can comment.
    >
    > Here is what Kevin found:
    >
    > | >> I think it should have formatted and activated swap first, and then
    > | >> afterwards start formatting the ext3 partitions. That would avoid the error.
    > | >
    > | > That's what the installer does. It partitions the disk, formats and
    > | > activates swap and then formats the other partitions.
    > |
    > | That surprises me. On a closer look into the log, you're right.
    > |
    > | From a user's POV, the first mkfs-ext3 attempt failed, but just starting
    > | it again worked out ok.
    > |
    > | Now from looking into the log, it looks strange: It adds swap, then
    > | attempts to format ext3, then comes OOM and kills mkfs.ext3. Then comes
    > | the interesting part: It seems to add swap again. That time mkfs.ext3
    > | runs OK. So maybe the first time adding swap, the swap gets disbled
    > | immediately after, triggering OOM?
    > |
    > | See the attached log excerpt.


    I don't see this problem on the NSLU2 with the default partitioning scheme.

    Sep 14 20:16:00 kernel: [42949829.950000] Adding 248968k swap on
    /dev/sda5. Priority:-1 extents:1 across:248968k
    Sep 14 20:16:04 partman: mke2fs 1.41.1 (01-Sep-2008)
    Sep 14 20:18:41 kernel: [42949991.560000] kjournald starting. Commit
    interval 5 seconds
    Sep 14 20:18:41 kernel: [42949991.560000] EXT3 FS on sda2, internal journal
    Sep 14 20:18:41 kernel: [42949991.560000] EXT3-fs: mounted filesystem
    with ordered data mode.

    Kevin, what partitioning scheme were you trying to implement?

    What is also interesting in Kevin's logs is that the kernel log
    messages indicate that swap was present and available.

    Aug 20 01:04:50 kernel: [42950317.650000] mkfs.ext3 invoked
    oom-killer: gfp_mask=0x1200d2, order=0, oomkilladj=0
    ....
    Aug 20 01:04:50 kernel: [42950317.660000] Free swap = 206988kB
    Aug 20 01:04:50 kernel: [42950317.660000] Total swap = 248968kB
    Aug 20 01:04:50 kernel: [42950317.660000] 8192 pages of RAM
    Aug 20 01:04:50 kernel: [42950317.660000] 381 free pages
    Aug 20 01:04:50 kernel: [42950317.660000] 817 reserved pages
    Aug 20 01:04:50 kernel: [42950317.660000] 675 slab pages
    Aug 20 01:04:50 kernel: [42950317.660000] 0 pages shared
    Aug 20 01:04:50 kernel: [42950317.660000] 2354 pages swap cached
    Aug 20 01:04:50 kernel: [42950317.660000] Out of memory: kill process
    7270 (mkfs.ext3) score 617 or a child
    Aug 20 01:04:50 kernel: [42950317.660000] Killed process 7270 (mkfs.ext3)

    I wonder if the system had nothing else left to page out to swap [1].
    I'm not sure what to do about this problem through, but it would be
    nice to know whether there is a partitioning scheme that causes the
    problem to occur.

    [1] http://kerneltrap.org/mailarchive/li...8/6/11/2092024

    --
    Gordon Farquharson
    GnuPG Key ID: 32D6D676



    --
    To UNSUBSCRIBE, email to debian-bugs-dist-REQUEST@lists.debian.org
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

  3. Bug#406007: installation-report: RC1 installer (NSLU2) does not use swap before partitioning

    Gordon Farquharson schrieb:
    > Kevin, what partitioning scheme were you trying to implement?


    >From memory, it was something like


    sda1 1 GB swap
    sda2 5 GB ext3 /
    sda3 995 GB ext3 /media/data

    I don't have access to my slug at this moment, but will have soon (this
    week most probably) and will re-test if you have any good ideas.



    --
    To UNSUBSCRIBE, email to debian-bugs-dist-REQUEST@lists.debian.org
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

  4. Bug#406007: installation-report: RC1 installer (NSLU2) does not use swap before partitioning

    Hi Kevin

    On Mon, Sep 15, 2008 at 00:47, Kevin Price wrote:

    > From memory, it was something like
    >
    > sda1 1 GB swap


    Are you sure the swap size was 1 GB? The swap size listed in the
    kernel OOM logs was only 248968kB:

    Aug 20 01:04:50 kernel: [42950317.650000] mkfs.ext3 invoked
    oom-killer: gfp_mask=0x1200d2, order=0, oomkilladj=0
    ....
    Aug 20 01:04:50 kernel: [42950317.660000] Free swap = 206988kB
    Aug 20 01:04:50 kernel: [42950317.660000] Total swap = 248968kB
    Aug 20 01:04:50 kernel: [42950317.660000] 8192 pages of RAM
    Aug 20 01:04:50 kernel: [42950317.660000] 381 free pages
    Aug 20 01:04:50 kernel: [42950317.660000] 817 reserved pages
    Aug 20 01:04:50 kernel: [42950317.660000] 675 slab pages
    Aug 20 01:04:50 kernel: [42950317.660000] 0 pages shared
    Aug 20 01:04:50 kernel: [42950317.660000] 2354 pages swap cached
    Aug 20 01:04:50 kernel: [42950317.660000] Out of memory: kill process
    7270 (mkfs.ext3) score 617 or a child
    Aug 20 01:04:50 kernel: [42950317.660000] Killed process 7270 (mkfs.ext3)

    Gordon

    --
    Gordon Farquharson
    GnuPG Key ID: 32D6D676



    --
    To UNSUBSCRIBE, email to debian-bugs-dist-REQUEST@lists.debian.org
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

+ Reply to Thread