LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 09-11-2006, 04:01 PM   #1
kenneth.ramsey
LQ Newbie
 
Registered: Sep 2005
Posts: 23

Rep: Reputation: 15
Moving Home directories to a new hard drive


I'm wanting to add 2 80 GB hard drives, configured as a RAID 1 to my server. It's running Debian 3.1, the kernal is 2.4. I feel I can tar the current /home directory and untar it on the RAID. I can then edit my fstab to mount the RAID as /home, my concern is how do I tell adduser where the new /home directories go?
 
Old 09-11-2006, 04:21 PM   #2
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
Mmm, maybe I'm missing something, but once the system is set up to mount the new /home directory instead of the old one, shouldn't everything work just the same as before? I mean, it doesn't matter what physical disk /home is on, as long as the system knows where to find it, right?
 
Old 09-11-2006, 05:22 PM   #3
Dutch Master
Senior Member
 
Registered: Dec 2005
Posts: 1,686

Rep: Reputation: 124Reputation: 124
David is right. Build the RAID as you should, then create a filesystem on the disks, open /etc/fstab and comment out the existing /home entry. Add the new /home space to the fstab file, adapt the device path to suit your system.

To copy the old /home to the new /home, uncomment the old /home entry (in /etc/fstab), make sure to change it's path (like /home/oldhome) but create the new directory beforehand. Copy the files to their new home (), make sure you've got them all (there are several hidden files, all starting with a dot) and when you're done, remove the entry in /etc/fstab to the old /home.
 
Old 09-11-2006, 09:59 PM   #4
kenramsey
LQ Newbie
 
Registered: Apr 2006
Posts: 7

Rep: Reputation: 0
One thing I forgot to add, the RAID is seperate from the system drive. I just want /home diretories on the RAID. Will tha tmake a difference?
Thaniks for the answers so far. I'm about to start on this in the near future.
 
Old 09-12-2006, 04:09 AM   #5
Dutch Master
Senior Member
 
Registered: Dec 2005
Posts: 1,686

Rep: Reputation: 124Reputation: 124
Separating your /home from the rest of the system is generally a good idea, so go ahead. For Linux it doesn't matter your RAID for /home is on separate disks, just make sure you set the RAID up correctly.
 
Old 09-12-2006, 04:40 AM   #6
fotoguy
Senior Member
 
Registered: Mar 2003
Location: Brisbane Queensland Australia
Distribution: Custom Debian Live ISO's
Posts: 1,291

Rep: Reputation: 62
What everyone here is saying is correct, if the mount point is the same the user will not know the difference. The device which it is mounted under is totally transparent to the user, so whether is is /dev/hda1, /dev/hda7 or /dev/hdb6 etc.... Also before you do anything make sure you backup all the data first, nothing like getting a call from an angry user who just losts some important data. Also depending on what raid you setup make sure you have a good backup plan, if you use mirroring raid your ok, but if you use stripping raid that splits the data onto both drives and one drive fails, you'll lose all your data.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
An easy way of moving /home and other directories 1kyle SUSE / openSUSE 1 09-23-2005 02:53 AM
moving /home to a new drive? tardigrade Linux - Newbie 5 10-18-2004 05:56 PM
Moving partitions from one hard drive to another robthebob Linux - Software 2 07-15-2004 04:47 AM
moving to a new hard drive n1wil Linux - Software 4 05-21-2003 02:38 PM
moving my hard drive illtbagu Linux - General 2 02-08-2003 04:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 02:49 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration