[NTLUG:Discuss] RAID-1 server goes down after disk failure/SWAP -- musings..

Leroy Tennison leroy_tennison at prodigy.net
Tue Nov 21 22:40:54 CST 2006


Michael Barnes wrote:
> Richard Geoffrion told me on 11/21/2006 12:14:
>   
>> Before asking the group 'why', I did my obligatory google search and I 
>> think I came up with a rather common sense answer!
>>
>> The situation I have is that servers using software RAID-1 don't seem 
>> very stable when one of the hard drive fails.   When a hard drive does 
>> crash, the server locks up.  I think I have finally identified 'the 
>> smoking gun'[tm].  See, since the beginning of my using software raid-1 
>> in linux, I have created a separate swap partition on each drive.  My 
>> thoughts were that there would be a speed increase along with space 
>> savings if I split my swap partitions across two physical 
>> drives/controllers.  The problem with this setup (as described in the 
>> Software-Raid-HOWTO FAQ) is that if you swap to a drive then lose the 
>> drive---well.. you're goin down!
>>
>> Reference:  
>> http://www.faqs.org/docs/Linux-HOWTO/Software-RAID-HOWTO.html#ss2.5
>>
>> As I am currently rebuilding a few servers, I will need to do 
>> 'something' about my swap partitions.  So... What is the current wisdom 
>> concerning setting up Software Raid-1?   What are the prevailing 
>> recommendations concerning swap files?   I've heard  everything from 
>> SWAP=2 times the system's RAM to SWAP= 1/2 the system's RAM.  It seems 
>> that swap will only use up to 2 gigabytes of a swap partition, so a 4gig 
>> swap partition on a 2gig of RAM server is....wasteful.  In today's 
>> multi-gig RAM climate, I can't seem to agree with the ever climbing SWAP 
>> space configurations.  Back in the days, 128Meg of swap on a 64Meg 
>> machine was plenty. Now that we have GIGs of RAM it would seem that the 
>> increase of all this RAM should obsolete the need for swap altogether?
>>
>> And what about using a FILE for swap space instead of a partition??
>>
>> And what about using TMPFS?   What *IF* you used tmpfs for your /tmp 
>> partition.  That would seem to reduces the amount of RAM available thus 
>> creating the need for more SWAP space??  Can one configure tmpfs to use 
>> swap space??   That would seem to be a cool way to have a totally 
>> temporary file system.
>>
>> What practical applications and/or pitfalls am I missing?
>>
>>     
>
> Regarding swap partitions.
> The advice I have been given in the past was
> RAM < 128 then swap = 2xRAM
> RAM > 256 then swap = RAM
> RAM > 1 GB then no swap
>
> Regarding RAID1.
> In my experience, in a RAID1 system, when one drive fails, the entire 
> machine becomes unstable and should be shutdown and repaired ASAP. In 
> fact just this last Sunday we had a client machine lose a hard drive. 
> It is a Dell dual processor server with a hardware RAID running Windows 
> XP.  One drive croaked. The POST data said the RAID was 'degraded' and 
> reported one drive as 'error occured'. The machine would not boot.  A 
> few boot attempts and it started reporting corrupted/missing files and 
> XP could not start.  Since it was under a maintenance contract, I just 
> left it until the Dell guy showed up today with a new hard drive. 
> Replaced the drive, fired it up, and all was well again.
> So, the RAID1 crumping had nothing to do with swap space.
>
> Michael
>
>
>
>
>
>
>
> _______________________________________________
> http://www.ntlug.org/mailman/listinfo/discuss
>
>   
This is pathetic, why have RAID1 when the system crashes if a drive goes 
bad?  This is NOT the way it is supposed to work.



More information about the Discuss mailing list