Re: Best way to create RAID-6 for swap partition - existing one failed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 5/16/2011 4:41 PM, Gavin Flower wrote:

> Motivation, existing RAID-6 swap partition failed.  I am thinking I should recreate it in a new format, as currently it is 'Version : 0.90', rather than simply rebuild it.
<snip>

Forget using a partition.  Simply use a swap file.  This example creates
a 1GB swap file in the / filesystem.  You can locate it on any
filesystem you wish.

# swappoff -a
# dd if=/dev/zero of=/swapfile1 bs=1024 count=1048576
# mkswap /swapfile1
# swapon /swapfile1
# vi /etc/fstab
Add:
/swapfile1 swap swap defaults 0 0

and remove your old entry for the failed swap partition.

There is little performance difference between swap files and swap
partitions with modern kernels.  The kernel will map the disk location
of the swap file and perform direct disk access, bypassing the
filesystem and buffer cache.

-- 
Stan
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux