File Server and Raid

ruscook ruscook_oz at yahoo.com.au
Wed Nov 15 07:41:23 UTC 2006


Hi Richard,
I'm not an expert and the installer did the next step for me so we'll
need to get help on that from this list (hey folks????)

Basically as I understand it you have to have the partition marked as a
Raid partition (which you do). You also have to put a file system on it
(I'm using XFS where I can and ext2/3 where I must). You now need to use
the mdadm command to make raidsets of the corresponding raid partitions.
"man mdadm" will help, but as I said, maybe someone here can provide the
correct syntax to make this painless (ie. no errors :-)).

The following is what needs correct/validation from an expert. It is my
current understanding of the process, but as I said, I've not done it as
it worked from the installer for me.

a) format each partition (not already formatted with a file system, but
not swap of course)
b) do a) for each drive
c) use sudo mdadm command to create a raidset
d) add the source partition from sda (as I assume this is the one you've
been using todate) to each set. This is a "degraded" raid as it only has
one drive/partition in it.
e) add the mirror from the corresponding partition on sdb and allow to
raid set to resync

Then when formatted and set up as a raidset you mount the partitions as
devices and make sure (for example) /dev/md2 (counting starts from 0)
is /dev/sda3 and /dev/sdb3 and mounted as /home. Then edit /etc/fstab to
ensure it is automounted.
entry for this would be something like:

/dev/md0        /           xfs     defaults        0       1
/dev/md1        /boot       ext3    defaults        0       2
/dev/md2        none        swap    sw              0       0
/dev/md3        /home       xfs     defaults        0       2


I note you don't have a separate /boot partition. It is advisable to
have to one, simply and non-technically it helps minimise the risk of
grub getting confused and is relatively easy to repair if you get a
problem without destroying your other settings (which can happen
if /boot is part of /).


On Wed, 2006-11-15 at 06:57 +0000, Richard Brown wrote:

> Hi Russell
> 
> 
> On 15/11/06, ruscook <ruscook_oz at yahoo.com.au> wrote:
> 
>         On Tue, 2006-11-14 at 18:23 +0000, Richard Brown wrote:
>         
>         Yes don't use /home from the first  disk, edit /etc/fstab to
>         ensure that whatever partition is you want for /home is
>         mounted.
>         Please post the results of your fdisk -l command
>         
>         
>         
>         
>         Hopefully these will help.
>         
> 
> Thank you so much - yes they do help. Here is the output from fdisk
> -l:
> Disk /dev/sda: 250.0 GB, 250059350016 bytes
> 255 heads, 63 sectors/track, 30401 cylinders 
> Units = cylinders of 16065 * 512 = 8225280 bytes
> 
>    Device Boot      Start         End      Blocks   Id  System
> /dev/sda1   *           1        1216     9767488+  83  Linux
> /dev/sda2            1217        1338      979965   82  Linux swap /
> Solaris 
> /dev/sda3            1339       30401   233448547+  fd  Linux RAID
> autodetect
> 
> Disk /dev/sdb: 250.0 GB, 250059350016 bytes
> 255 heads, 63 sectors/track, 30401 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes 
> 
>    Device Boot      Start         End      Blocks   Id  System
> /dev/sdb1               1        1216     9767488+  83  Linux
> /dev/sdb2            1217        1338      979965   82  Linux swap /
> Solaris
> /dev/sdb3            1339       30401   233448547+  fd  Linux RAID
> autodetect 
> 
> Disk /dev/md0: 239.0 GB, 239051210752 bytes
> 2 heads, 4 sectors/track, 58362112 cylinders
> Units = cylinders of 8 * 512 = 4096 bytes
> 
> Disk /dev/md0 doesn't contain a valid partition table
> 
> I can see that /dev/sda3 is the /home partition and that it is running
> as raid. How do I mount this as /home please and then get it to stay
> mounted as /home when I boot up? I'll then need to work out how to add
> shares!
> 
> Many thanks once again for your invaluable help.
> -- 
> Rich
> http://www.cregy.co.uk
> Embracing what God does for you is the best thing you can do for him.
> Romans 12 v 1

Kind Regards Russell
==================
www.windsorcycles.com.au
sales at windsorcycles.com.au
ph. 02 4577 3209
bikes.no-ip.info
Linux user #369094
================== 


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20061115/5478bc64/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smiley-3.png
Type: image/png
Size: 819 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20061115/5478bc64/attachment.png>


More information about the ubuntu-users mailing list