Difference between revisions of "Talk:Raid"

From SME Server
Jump to navigationJump to search
m (Remove talk no longer relevant)
 
(26 intermediate revisions by 3 users not shown)
Line 1: Line 1:
from bug 5665
 
The newer e2fs tools are smart enough that if you use the resize2fs tool to do
 
the resizing with a mounted filesystem it will do the same thing ext2online
 
used to do.  They just made it so instead of having two tools you have one
 
smart tool.
 
  
That being said the documentation may need to be updated to handle the sme8
 
case.  However there are a lot of enhanced things you can do with the new tools
 
in 8 that you can't do in 7.  I'd like to see an entire new page explaining how
 
to expand/grow your filesystem on 8 instead of just adding notes for where
 
things are different.
 
 
2011-03-06: added a warning box to RAID1 -> RAID5 conversion: note taken from http://www.arkf.net/blog/?p=47
 
 
 
From Bug 6632 and 6630 a suggested sequence for Upgrading a Hard Drive size is detailed below after issue when attempting to sync a new drive when added first as sda
 
 
====Replacing and Upgrading Hard Drive after HD fail====
 
Note: these instructions are applicable if you have a faulty HD on a RAID system with more than one drive and intend to upgrade the sizes as well as replacing the failed HD. They are not applicable to a single-drive RAID 1 system, and increasing the useable space on such a system by cloning the existing single drive to a larger drive is not supported. See http://bugs.contribs.org/show_bug.cgi?id=5311
 
 
* CAUTION MAKE A FULL BACKUP!
 
* Ensure you have e-smith-base-4.16.0-33 or newer installed. [or Update to at least 7.1.3]
 
 
HD Scenario - Current 250gb drives, new larger 500gb drives
 
 
# Remove old 250gb HDD from sdb, leave old 250gb drive as sda on its own and boot up.
 
# Shutdown, connect one new 500gb drive as sdb and boot up
 
# Login to the admin panel and manage raid to add new (larger) drive to system.
 
# Wait for raid to fully sync
 
# Do full reboot with those 2 drives in place (1 original, 1 new)
 
#Shutdown again, disconnect the original drive, and connect the new drive just sync'd as sda (in place of original)
 
# Boot up again with just the one new drive in place, and confirm it boots OK.
 
#Shutdown, and connected the other 500gb drive as sdb
 
# Boot up login to admin panel and add sdb to the array, and wait for raid to fully sync.
 
# Reboot and ensure all drives have been replaced with larger drives and array is in sync and redundant!
 
# Issue the following commands:
 
 
mdadm --grow /dev/md2 --size=max
 
pvresize /dev/md2
 
lvresize -l +100%FREE main/root
 
ext2online -C0 /dev/main/root 
 
 
In the last command above, the -C0 is: dash C zero
 
 
If you receive an  "command not found" error,  try this:
 
resize2fs /dev/mapper/main-root &
 
 
TIP: I put an "&" at end to allow it to run in background even if I close ssh session.
 
 
Notes : 
 
* These instructions should work for any raid level you have as long as you have >= 2 drives
 
* If you have disabled lvm 
 
# you don't need the pvresize or lvresize command
 
# the final line becomes ext2online -C0 /dev/md2 (or whatever / is mounted to)
 

Latest revision as of 13:31, 15 February 2013