Re: Make LVM aware of new disk size



Dances With Crows wrote:

Gregory Shearman staggered into the Black Sun and said:
Dances With Crows wrote:
Or convert the LVM1 setup to an LVM2 setup. The LVM-HOWTO talks
about this in section 4.1.1 and 4.1.7. I hope your / wasn't on an
LV, because doing LVM things when / is on an LV can get tricky and
evil. (That's why the LVM-HOWTO says not to do that.)
Tricky, yes I agree with that. I had to hack a (Gentoo) genkernel
script to produce an initrd that will load the device mapper module

IMO, if it's necessary to boot the system, it should not be a module.

It sounds rather like blind prejudice to me. Why shouldn't it? I already
used an initrd to kick off a boot splash graphical screen so it's not much
more effort to put in a few binaries udev and a device-mapper to handle the
Logical volumes.

Modules are for plugging into your running kernel, doesn't matter where they
came from.

YMMV on this, but I always thought initrd was ugly (if useful in certain
situations, like where you have no clue about the hardware).

Beauty is in the eye of the beholder I suppose. I always think of them as an
elegant hack. A root filesystem uncompressed from your boot partition into
ram.

My initrd also loads a pretty boot splash screen instead of having writing
scrolling by... Now that is isn't ugly!

Evil? What's so evil about it? A few hundred megabytes of / as a
logical volume doesn't seem to be much of a problem.

LVM is more complex than bare partitions. As you can't have /boot on
LVM, you already need one real partition to hold your kernel image and
loading map or stage2+grub.conf. If you've got one, why not 2?

My boot partition is not mounted on my filesystem (except when adding a new
kernel). Its only purpose is to provide the kernel and initrd to the
bootloader. All other partitions are mounted and used. If I wish to get rid
of an old disk I can move the running system completely to the new disk
without a shutdown. The boot partition is never mounted anyway. It can be
moved to the boot partition on the new disk using "dd". No need to bother
shutting down and restarting under a maintenance cd.

Logical Volume management seems rather a simple system

...simple enough that you can't access LVs if you're not running Linux.

You can't access a PHYSICAL linux partition if you aren't running linux....
what's the difference?

This can cause problems in a multi-boot machine, and is why I haven't
put LVM on my laptop.

I see, sort of.. I don't run multiboot machines. I only run Linux.

Tricky yes, but evil? Think of the flexibility of moving your whole
system to a new disk while you are using it. Beeeutiful.

If you need to do this, possibly. So far, scheduling a half-hour of
downtime for moving / hasn't been difficult. I'm sure someone here will
want that capability at some point. They'll probably want the other LVM
capabilities first, though. ("Plonk in new disks, pvcreate, vgextend,
lvresize, resize2fs, now /stuff has 300 more G, users have no hassle!"
as I said to management. They didn't seem that impressed for some
reason. Sigh.)

Scheduling half an hour downtime, as opposed to less than 30 seconds running
a command..... hmmmmm! If you've got all that free time then good luck to
you.

--
Regards,

Gregory.
Gentoo Linux - Penguin Power
.



Relevant Pages

  • Re: Linux iSeries (ppc) question.
    ... Sounds like LVM may still work for you. ... > does depend on what type of disk is created. ... > normal Linux rules may not apply, as it is driven by OS/400's Guest ... > It really all depends on how the LPAR was setup un the iSeries. ...
    (comp.os.linux.powerpc)
  • Re: quck LVM question...
    ... >>Should I use LVM for all 3 disks? ... I was thinking about partitioning the first disk without LVM ... > it on a Linux production environment but my Linux server ran happily for six ... installed the database software yet so I may even redo the install. ...
    (alt.os.linux.suse)
  • Re: quck LVM question...
    ... > I decided to redo my 7.3 pro install from scratch and incorporate LVM as ... > Should I use LVM for all 3 disks? ... I was thinking about partitioning the first disk without LVM ... it on a Linux production environment but my Linux server ran happily for six ...
    (alt.os.linux.suse)
  • Re: LVM partition
    ... DB>> I am about about to install linux on a new machine. ... DB>> What are the pros and cons of LVM partitioninng compared to "standard" ... DB> can reduce the filesystem in the partition, and then put the emptied PE's ... DB> table, but a virtual disk. ...
    (comp.os.linux.misc)
  • Re: [opensuse] Creating a boot CD
    ... when loading windowz after Linux your boot partition was lost. ... to do this still only create a boot CD disk with your image on so you can re- ...
    (SuSE)