Re: Different sysinstall labelling behaviour when run post-install vs. during install?

From: Matthew Seaman (m.seaman_at_infracaninophile.co.uk)
Date: 07/30/04

  • Next message: Martin Hudec: "postfix, saslauthd, pam_mysql - wrong username is being send"
    Date: Fri, 30 Jul 2004 10:51:30 +0100
    To: Darren Pilgrim <dmp@bitfreak.org>
    
    
    

    On Thu, Jul 29, 2004 at 06:01:50PM -0700, Darren Pilgrim wrote:
    > Yesterday I was upgrading the disk in one of my workstations. Since I was
    > planning on growing the filesystems for my FreeBSD install at the same time,
    > I needed to manually create a new disklabel. I used sysinstall for this,
    > but ran into a problem: sysinstall doesn't allocate the partition letters,
    > with 'a' first, if you aren't doing an initial install. I ended up using
    > the "auto defaults" option to create the 'a' partition, then remove
    > everything and create them as I wanted. I'm glad to say that it worked out
    > just fine, but this problem raises a couple of questions:
    >
    > Why does sysinstall behave differently when run post-install?

    Interesting. I didn't know it did that. At a guess what may be
    happening is that sysinstall(8) is treating your disk as if it was the
    second or subsequent disk on the system. In which case, it probably
    wouldn't allocate an 'a' partition, which by convention contains a
    bootable image.
     
    > How do I manually specify or change the partition letter to use?

    Don't use sysinstall(8). sysinstall is like the training wheels
    children use when learning to ride a bike: essential in the beginning,
    but once they've achieved some proficiency, the training wheels just
    get in the way.

    Use disklabel(8), or if you're running 5.x, bsdlabel(8). It's the
    same program either way, it just got renamed for 5.x. disklabel will
    let you examine and make arbitrary edits to the disk label. You can
    also use it to generate a disklabel automatically.

    To make the sort of changes you require, use 'disklabel -e' which will
    put you into an editor session showing the current disk label. Then
    just edit the 'partitions' section as required. When creating a new
    partition, you must fill in the 'size', 'offset' and 'fstype' fields.
    for ordinary 4.2BSD (ie UFS) partitions, the next three fields are
    hints to newfs(8) -- the default settings (fsize=1024, bsize=8192,
    bps/cpg=16) are a good first choice, but you can modify those at will
    from the newfs(8) commandline. The cylinder number stuff after the
    '#' is generated automatically: you don't need to fill anything in
    there yourself.

    Once you've revamped the partitioning, you'll need to create
    filesystems to go inside those partitions. newfs(8) will create you a
    pristine new filesystem, or if you're feeling brave, you can use
    growfs(8) to extend a filesystem, but a) only where the old partition
    starts at exactly the same offset as the new one and b) only when the
    new partition is *larger* than the old one. growfs(8) is more often
    used with such things as vinum(8) -- for plain UFS partitions dumping
    the filesystem, modifying the drive layout, creating new filesystems
    and recovering the data from backup is generally the best way to do
    such things, and least likely to result in foot-shooting.

            Cheers,

            Matthew

    -- 
    Dr Matthew J Seaman MA, D.Phil.                       26 The Paddocks
                                                          Savill Way
    PGP: http://www.infracaninophile.co.uk/pgpkey         Marlow
    Tel: +44 1628 476614                                  Bucks., SL7 1TH UK
    
    



  • Next message: Martin Hudec: "postfix, saslauthd, pam_mysql - wrong username is being send"

    Relevant Pages

    • Re: Retrieving XP partition with DFSee
      ... select the disk ... ... Finished analysis: CHKPART for partition: 2 ... when possible recovery of damaged filesystems, ...
      (comp.os.os2.setup.storage)
    • Re: Problem adding new slices
      ... portion of the disk. ... Ran sysinstall again. ... Created /d partition in label editor. ... newfs /dev/ad0s3d. ...
      (freebsd-stable)
    • Re: LABEL (The FreeBSD Disklabel Editor)
      ... By filesystems I do not mean just directories within other filesystems. ... repartition the disk using disklabel and then run newfs again. ... I would guess that at the least you would have to use disklabel to remove ... the partition that is used for /var/mail. ...
      (freebsd-questions)
    • Re: Problem adding new slices
      ... I suspect I will not be the one to find anything, ... Ran sysinstall again. ... It was at this point that I tried to mount the partition, which failed with an incorrect super block error. ... Then it occurred to me that I never actually saw newfs run from sysinstall like it usually does during a fresh install or adding a new disk. ...
      (freebsd-stable)
    • Re: Sysinstalls fdisk/disklabel should be improved
      ... the Partition Editor has the 'A' option to use all of the ... US> create a DOS-compatible slice or not. ... specifying the complete disk as 'size' will ... US> to reboot sysinstall, because it doesn't re-read the partition/slice ...
      (freebsd-current)