Re: [gentoo-user] /usr and /home to another partition
On Fri, 07 Oct 2005 09:07:41 +0800, W.Kenworthy wrote: If you want to move directories, avoid wholesale symlinking like this as it always ends in tears ... If you want two directories on the same partition, I prefer to mount them with --bind. I do this to have /usr, /var and /opt on a single partition, separate from/. /usr is mounted on the partition itself, which contains var and opt directories, which are mounted with the following fstab lines. /usr/var/varautobind0 0 /usr/opt/optautobind0 0 -- Neil Bothwick Headline: Explosion At Sperm Bank, Nurses Overcome pgpU5Ny2JxYzi.pgp Description: PGP signature
Re: [gentoo-user] /usr and /home to another partition
I tryed to do links to directories on other partition on my experimental server with SELinux. It had some problems with labeling filesystem. Is it possible to solve this issue? 2005/10/7, Neil Bothwick [EMAIL PROTECTED]: On Fri, 07 Oct 2005 09:07:41 +0800, W.Kenworthy wrote: If you want to move directories, avoid wholesale symlinking like this as it always ends in tears ... If you want two directories on the same partition, I prefer to mount them with --bind. I do this to have /usr, /var and /opt on a single partition, separate from/. /usr is mounted on the partition itself, which contains var and opt directories, which are mounted with the following fstab lines. /usr/var/varautobind0 0 /usr/opt/optautobind0 0 -- Neil Bothwick Headline: Explosion At Sperm Bank, Nurses Overcome -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
On Fri, 7 Oct 2005 11:40:24 +0200, capsel wrote: I tryed to do links to directories on other partition on my experimental server with SELinux. It had some problems with labeling filesystem. Is it possible to solve this issue? Yes, use mount --bind instead. read the mail you quoted. -- Neil Bothwick Top Oxymorons Number 40: Same difference pgpqkofw0E5X0.pgp Description: PGP signature
Re: [gentoo-user] /usr and /home to another partition
Hemmann, Volker Armin wrote: if you want to use copy, I would prefer cp -a ;) Use tar since cp wont preserve empty dirs. # cd /path/to/old/dir # tar cf - * | ( cd /path/to/new/dir tar xf - ) They used tar, for some reasons they mentioned and I forgot ;) :) -- Norberto Bensa 4544-9692 Ciudad de Buenos Aires, Argentina -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
Norberto Bensa wrote: Hemmann, Volker Armin wrote: if you want to use copy, I would prefer cp -a ;) Use tar since cp wont preserve empty dirs. # cd /path/to/old/dir # tar cf - * | ( cd /path/to/new/dir tar xf - ) What about rsync -a ? They used tar, for some reasons they mentioned and I forgot ;) :) -- gentoo-user@gentoo.org mailing list
[gentoo-user] /usr and /home to another partition
I want to move the /usr and /home directories to another partition, because I'm thinking of buying a new HD. It would be great if both directories were on the same partition, as splitting drives never seemed very appealing to me. As far as I know, one possibility would be to [with the boot-cd] # mv /usr /mnt/newHD/ # mv /home /mnt/newHD/ # ln -s /mnt/newHD/usr usr # ln -s /mnt/newHD/home home However, I'm not sure if this is the suggested method of doing so and to be honest, I'm not completley sure if this would even work. Any comments or suggestions ? -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
If you want to move directories, avoid wholesale symlinking like this as it always ends in tears ... Using a liveCD, create your partitions and directories, then copy everything over (rsync or tar is best to make sure its accurate), change your fstab then reboot. When you are happy its working, you can recover the old directories at leisure. For the future: I found that since I stated using LVM, this sort of exercise becomes a lot easier, safer and has less downtime. BillK On Fri, 2005-10-07 at 02:49 +0200, Matthias Langer wrote: I want to move the /usr and /home directories to another partition, because I'm thinking of buying a new HD. It would be great if both directories were on the same partition, as splitting drives never seemed very appealing to me. As far as I know, one possibility would be to [with the boot-cd] # mv /usr /mnt/newHD/ # mv /home /mnt/newHD/ # ln -s /mnt/newHD/usr usr # ln -s /mnt/newHD/home home However, I'm not sure if this is the suggested method of doing so and to be honest, I'm not completley sure if this would even work. Any comments or suggestions ? -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
On Thursday October 6 2005 7:49 pm, Matthias Langer wrote: I want to move the /usr and /home directories to another partition, because I'm thinking of buying a new HD. It would be great if both directories were on the same partition, as splitting drives never seemed very appealing to me. As far as I know, one possibility would be to [with the boot-cd] # mv /usr /mnt/newHD/ # mv /home /mnt/newHD/ # ln -s /mnt/newHD/usr usr # ln -s /mnt/newHD/home home However, I'm not sure if this is the suggested method of doing so and to be honest, I'm not completley sure if this would even work. Any comments or suggestions ? In theory I suppose that would work. Myself, I would copy the contents to /mnt/newHD/ then rename the original directories and create the links. The renamed directories can be deleted after you've verified positive results. And if it all craps out, the originals can simply be renamed back to /usr and /home. You should consider creating separate partitions for these though. At some point you may wish to blow out the install but retain your /home. Separate partitions makes this much easier. And also opens the possibility of sharing your /home with multiple installs. HTH -jm -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
Joe Menola wrote: On Thursday October 6 2005 7:49 pm, Matthias Langer wrote: I want to move the /usr and /home directories to another partition, because I'm thinking of buying a new HD. It would be great if both directories were on the same partition, as splitting drives never seemed very appealing to me. As far as I know, one possibility would be to [with the boot-cd] # mv /usr /mnt/newHD/ # mv /home /mnt/newHD/ # ln -s /mnt/newHD/usr usr # ln -s /mnt/newHD/home home However, I'm not sure if this is the suggested method of doing so and to be honest, I'm not completley sure if this would even work. Any comments or suggestions ? In theory I suppose that would work. Myself, I would copy the contents to /mnt/newHD/ then rename the original directories and create the links. The renamed directories can be deleted after you've verified positive results. And if it all craps out, the originals can simply be renamed back to /usr and /home. You should consider creating separate partitions for these though. At some point you may wish to blow out the install but retain your /home. Separate partitions makes this much easier. And also opens the possibility of sharing your /home with multiple installs. HTH -jm Well, maybe you are right and creating a /usr and a /home partition is the better choice. As I want to buy a 250GB drive, I'm thinking of 20G for /usr and 230GB for home, while still 16GB remain for /opt, /root, /bin . Now another genooist pointed out that it would be wiser to use rsync or tar instead of just # cp - r /usr /mnt/newHd_part_usr/ So, should I enter # rsync -r /usr /mnt/newHd_part_usr/ or are there some options I should activate to make sure I get what I want ? Thanks, Matthias -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
On Friday 07 October 2005 03:52, Matthias Langer wrote: Joe Menola wrote: On Thursday October 6 2005 7:49 pm, Matthias Langer wrote: I want to move the /usr and /home directories to another partition, because I'm thinking of buying a new HD. It would be great if both directories were on the same partition, as splitting drives never seemed very appealing to me. As far as I know, one possibility would be to [with the boot-cd] # mv /usr /mnt/newHD/ # mv /home /mnt/newHD/ # ln -s /mnt/newHD/usr usr # ln -s /mnt/newHD/home home However, I'm not sure if this is the suggested method of doing so and to be honest, I'm not completley sure if this would even work. Any comments or suggestions ? In theory I suppose that would work. Myself, I would copy the contents to /mnt/newHD/ then rename the original directories and create the links. The renamed directories can be deleted after you've verified positive results. And if it all craps out, the originals can simply be renamed back to /usr and /home. You should consider creating separate partitions for these though. At some point you may wish to blow out the install but retain your /home. Separate partitions makes this much easier. And also opens the possibility of sharing your /home with multiple installs. HTH -jm Well, maybe you are right and creating a /usr and a /home partition is the better choice. As I want to buy a 250GB drive, I'm thinking of 20G for /usr and 230GB for home, while still 16GB remain for /opt, /root, /bin . Now another genooist pointed out that it would be wiser to use rsync or tar instead of just # cp - r /usr /mnt/newHd_part_usr/ So, should I enter # rsync -r /usr /mnt/newHd_part_usr/ or are there some options I should activate to make sure I get what I want ? if you want to use copy, I would prefer cp -a ;) hm, go to the suse site - they have a step-by-step example to move whole directory-trees from one partition to another.. or had it some yoears ago. They used tar, for some reasons they mentioned and I forgot ;) -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
On Thursday 06 October 2005 20:52, Matthias Langer wrote: Joe Menola wrote: On Thursday October 6 2005 7:49 pm, Matthias Langer wrote: I want to move the /usr and /home directories to another partition, because I'm thinking of buying a new HD. It would be great if both directories were on the same partition, as splitting drives never seemed very appealing to me. As far as I know, one possibility would be to [with the boot-cd] Now another genooist pointed out that it would be wiser to use rsync or tar instead of just # cp - r /usr /mnt/newHd_part_usr/ So, should I enter # rsync -r /usr /mnt/newHd_part_usr/ or are there some options I should activate to make sure I get what I want ? Thanks, Matthias rsync -a will get all times and permissions, /etc. I would STRONGLY second what the other guy said about lvm, though. If you buy a new hard drive, don't just put filesystems and partitions on it, go the LVM route, make the logical volumes small, and don't use the whole drive for lvs, you can grow anything you want later. -- John Jolet Your On-Demand IT Department 512-762-0729 www.jolet.net [EMAIL PROTECTED] -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] /usr and /home to another partition
John Jolet wrote: On Thursday 06 October 2005 20:52, Matthias Langer wrote: Joe Menola wrote: On Thursday October 6 2005 7:49 pm, Matthias Langer wrote: I want to move the /usr and /home directories to another partition, because I'm thinking of buying a new HD. It would be great if both directories were on the same partition, as splitting drives never seemed very appealing to me. As far as I know, one possibility would be to [with the boot-cd] http://www.gentoo.org/doc/en/articles/partitioning-p1.xml worked nicely for me when I moved /home to a second drive... HTH, Roy -- gentoo-user@gentoo.org mailing list