On Sat, 15 Nov 2003, Stefan Rijnhart wrote:

> This is actually straightforward on Linux, which is why we like it :).
> Just boot into a different system, like with a boot disk or live image
> (e.g.  Knoppix), and copy the contents of your /mount/point/of/dev/hdc1
> to /mount/point/of/rootdir/usr with the rsync command:
> 
> rsync -av [source/] [desitination]
> 
> Read the rsync man page and mind the trailing slash on the source. The
> hard part is to know your drives' partition tables, which you already
> do. Note that the 'df' command is a comfortable way of finding out what
> is mounted where, instead of reading /etc/mtab.

[Quoted text snipped, because I can't be bothered cleaning up after top 
posters, but don't want that nonsense to appear in messages I send <g>]

It should be mentioned that there is one more step in the process - fixing
the /etc/fstab file to reflect the new configuration. If this bit is left
out, his previous /usr partition will be mounted again just as it has been
in the past (right over his fresh new copy of the /usr tree), and the only
difference he'll notice is that he now has a lot less free space on his /
partition than he did before. :)

To the OP:

First off, the advice is sound, as far as it goes. Me, I'd use the rescue
system on CD #1 to do it; it doesn't have rsync, I don't think, but using
"cp -a" ought to do the trick nicely. But using Knoppix is much easier, if
for no other reason than it makes entirely separate mount points for all
detected partitions automatically (but remember, you'll need to remount
your / partition in read-write mode to be able to write to it - but that
can be done by right-clicking on its icon, and choosing that option from
the menu shown).

But before you shut down to boot whichever CD-based system you choose to 
use, make a copy of your /etc/fstab file, doing this at a root prompt:

cp /etc/fstab /etc/fstab.old

Then, still at that root prompt, edit /etc/fstab with your favorite editor
(kate is good for this sort of thing, if you don't like CLI editors):

kate /etc/fstab

Delete the line that refers to your current /usr partition, then save the
file. Now you can boot to that CD and copy the files over, and when you
reboot back to your on-disk system, the system will use the new versions
of those files (the ones on the / partition), and not the old.

Don't delete the old files or remove the disk on which they reside until 
you are satisfied that the system boots and runs properly in all respects. 
If you run into a problem, boot to the CD again, and copy /etc/fstab.old 
over /etc/fstab, then reboot - and all will be back like it was before, 
with the system mounting (and then using) your "old" /usr partition.

HTH!

-- 
Bill Mullen   [EMAIL PROTECTED]   MA, USA   RLU #270075   MDK 8.1 & 9.0
"Top posting because that's where the cursor happens to be is like shitting
your pants because that's where your ass hole is." - Blinky the Shark

Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to