RE: Move directory from one petition/device to another

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Had you picked almost any other directory, there'd have probably been no problem in doing so...

However, /etc is necessary very early in the boot process. (i.e. before all the mounts are done.) Things like /etc, /bin, /sbin, /var need to be in the root so that they can be used during the boot. Other things, like /usr, /tmp, /opt can be moved into other partitions or devices / filesystems, and can be set up in /etc/fstab to be mounted during the boot process, without any harm to the system. 

Doing so is just a matter of mounting the new filesystem at a convenient mount point, cloning the directory structure over to it (tar is useful for this), getting into single user mode, deleting the original files and then mounting the new filesystem over the old directory as a mountpoint. 

If you're not completely brave (reckless), mount the new filesystem over the old directory first without removing the old files, and test it to be sure everything is happy, before going into single user mode and deleting the files. Testing saves much time and effort.


-- 
Robert P. Nix		Mayo Foundation
RO-CE-8-857		200 First Street SW
507-284-0844		Rochester, MN 55905
-----
"In theory, theory and practice are the same, but
 in practice, theory and practice are different."

-----Original Message-----
From: fedora-list-bounces@xxxxxxxxxx [mailto:fedora-list-bounces@xxxxxxxxxx] On Behalf Of Cameron Beattie
Sent: Friday, September 16, 2005 3:41 PM
To: For users of Fedora Core releases
Subject: Move directory from one petition/device to another

I would like to move a directory from one petition to another. For example 
/dev/sdb1 is mounted on /.
I would like to move directory /etc to /dev/sda2.

Could anyone offer advice on the easiest way to achieve this?

I have had a look at dd but that seems to allow for copying files or an 
entire device, not a directory.

Many thanks

Cameron 

-- 
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux