On Dec 10, 2007 5:14 PM, SJS <[EMAIL PROTECTED]> wrote:
> begin  quoting Gus Wirth as of Mon, Dec 10, 2007 at 02:09:49PM -0800:
> > SJS wrote:
> > > begin  quoting Tracy R Reed as of Mon, Dec 10, 2007 at 11:56:48AM -0800:
> > >> Todd Walton wrote:
> > >>> I partitioned my hard drive at something less than optimal.  Now I'd
> > >>> like to put /usr on a different partition.  How do I do this?
> > >> Most modern distros use LVM don't they? If you aren't on LVM yet be sure
> > >> to use it in the future. It makes this sort of problem go away.
> > >
> > > Hm...
> > >
> > > Let's say I have 3 disks and 1 CDROM drive and two IDE channels.
> > >
> > > I want to upgrade one of the disks.
> > >
> > > So... without LVM, it's simple. I pull the CDROM, drop in the disk,
> > > partition, format, mount, and play with tar or rsync, modify fstab,
> > > pull the old disk, move the new disk, reconnect the CDROM, and bob's
> > > your uncle.
> > >
> > > With LVM, is it even simpler?
> >
> > Yes. But you have to have empty space beforehand to allocate. Or you
> > have to do some gyrations to shrink a filesystem that has excess space
> > in order to reallocate it to the filesystem that needs it. Answers at
> > <http://www.tldp.org/HOWTO/LVM-HOWTO/index.html>
>
> Specifically,
>
> http://www.tldp.org/HOWTO/LVM-HOWTO/removeadisk.html
>
> ...although it seems to require my changing where the CD-ROM drive
> connects into the IDE chain(s).  I would not consider this a _good_
> solution to the single most common disk-space problem I've ever had.

That's only if you don't have another place to connect the extra drive.

> It's rare that I can just _add_ disk; most often, I need to replace
> a disk with a bigger one, on a system that has no room for new devices
> or spare disk.
>
> So I think it's "no, it's not simpler", rather than "yes, it is simpler".
>
> Hm. Given TWO disks, it might be simpler. Connect spare disk #1, pvmove
> everything off the disk-to-be-replaced, vgreduce out the disk-to-be-replaced,
> pull disk-to-be-replaced, connect spare disk #2, pvmove everything off of 
> spare
> disk #1 on to spare disk #2, vgreduce out spare disk #1, and you're done with
> nary a tar nor rsync in sight.
>
> Although tar or rsync might be faster than all that pvmoving.
>
> (And if you're backing up everything anyway... would restoring be faster?)
>

It seems to me that the above gyrations are logically equivalent to
the classic approach:
1) Dump from old drive to intermediate storage medium.
2) Restore to new drive from intermediate storage.

I seem to remember something like this from 6th Edition Unix in a
discussion of how to increase the size of a file system.

Of course nowadays the intermediate storage would be another disk
drive rather than magtape.

    carl
-- 
    carl lowenstein         marine physical lab     u.c. san diego
                                                 [EMAIL PROTECTED]


-- 
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list

Reply via email to