lvm boot partition and grub

From: Benedict Verheyen (linux4bene_at_pandora.be)
Date: 08/30/03

  • Next message: Cam Ellison: "Re: some reality about iptables, please"
    To: debian-user@lists.debian.org
    Date: Sat 30 Aug 2003 00:17:43 +0200
    
    

    Hi,

    i have successfuly switched my system to lvm. First i had
    "normal" partitions on hda and an empty hdb. Then hda
    started to display weird problems so i thought i would
    move all to hdb and also make it all lvm. hda is an old
    small drive anyway, so it's time for it to go to the
    eternal hardware grounds to spin forever :)
    The conversion succeeded after a few stupid mistakes:

    1. Grub needs root in hex numbers. For instance mine is
    3a05. I specified the wrong id several times as well
    as trying /dev/main/lv_root
    (i followed the examples mentioned in a mail from Qian
    Qong dated 2 aug 2002. He pointed out 2 excellent docs:
    http://www-106.ibm.com/developerworks/linux/library/l-lvm/index.html
    and
    http://tldp.org/HOWTO/LVM-HOWTO/)

    2. I have different partitions for /, home, var, usr and
    tmp. When i finally switched my root over to lvm, i
    forget to make sure there are dirs named home, var, usr
    and tmp in the root lvm partition so the other partitions
    can get mounted :)

    Ahum, well, one learns by mistakes. In this case it was
    definitely so. Now, everything is solved, yet i have a
    few questions.

    1. Grub is still on hda and i want to take hda out. If
    i install grub to hdb (that will become hda after
    removal of the old hda), my initrd-lvm image will reside
    on the boot partition on the new hda but i don't have a
    seperate boot partition so this is also an lvm partition.
    I suspect that this won't work and that i actually will
    need another non lvm boot partition or not?

    Because the initrd image contains the necessary modules
    for lvm but is itself on an lvm partition.
    Can this be solved by compiling LVM in the kernel
    instead of a module?

    I have CONFIG_BLK_DEV_LVM=Y in my current kernel. If
    this activates LVM, am i correct in understanding that
    i don't actually need an initrd-lvm and that i could
    simply install grub to hdb, removed hda, adjust settings
    in /etc/fstab and /boot/grub/menu.lst and that it
    should work?

    2. Will the hex device number (3a05) also change when i
    take out the first disk (hda)?
    Is there any way to know beforehand what that number
    will become?

    Thanks

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

  • Next message: Cam Ellison: "Re: some reality about iptables, please"

    Relevant Pages

    • Re: file recovery ideas? bad boot block
      ... Disk hdb apparently failed. ... to the point where boot doesn't complete. ... /home partition readonly. ... > Install RH on hda, then try to move hdb files to hda, then ...
      (alt.os.linux)
    • change hdb to hda
      ... floppy and carried on with it on hdb. ... Now I want move the drive with suse from hdb to hda, so I can add a second ... PS When googling on instructions for moving the home partition, ...
      (alt.os.linux.suse)
    • [OT] hardware problem
      ... I put it in and after 20 minutes one disk goes ... partition on hda to another: it takes forever, ... I leave the system powered down overnight, boot a Sarge partition on ... hda and now the system can't access hdb. ...
      (Debian-User)
    • Re: Cannot mount old drive with LVM partition - help!
      ... on hdb is the boot partition, partition 2 on hdb is the LVM where my stuff ... but you should be able to turn off lvm vgchange -an. ...
      (alt.os.linux)
    • Re: [opensuse] LILO/Grub Problem
      ... root ... The initrd on that drive has the modules for the lvm in it. ... partition, and a 28G LVM (which I have my home and all other partions on as ... I did not TOUCH any of the partitions on hdb. ...
      (SuSE)