⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 raidtab.5

📁 create raid tool at linux
💻 5
字号:
.\" -*- nroff -*-.TH raidtab 5.SH NAMEraidtab \- configuration file for md (RAID) devices.SH DESCRIPTION\fB/etc/raidtab\fR is the default configuration file for the raidtools (\fBraidstart\fP and company). It defines how RAID devices areconfigured on a system..SH FORMAT\fB/etc/raidtab\fP has multiple sections, one for each md device whichis being configured. Each section begins with the \fBraiddev\fR keyword.The order of items in the file is important. Later \fBraiddev\fR entriescan use earlier ones (which allows RAID-10, for example), and the parsingcode isn't overly bright, so be sure to follow the ordering in thisman page for best results.Here's a sample md configuration file:.nf.ta +3i## sample raiddev configuration file# 'old' RAID0 array created with mdtools.#raiddev /dev/md0    raid-level              0    nr-raid-disks           2    persistent-superblock   0    chunk-size              8    device                  /dev/hda1    raid-disk               0    device                  /dev/hdb1    raid-disk               1raiddev /dev/md1    raid-level              5    nr-raid-disks           3    nr-spare-disks          1    persistent-superblock   1    parity-algorithm        left-symmetric    device                  /dev/sda1    raid-disk               0    device                  /dev/sdb1    raid-disk               1    device                  /dev/sdc1    raid-disk               2    device                  /dev/sdd1    spare-disk              0.fiHere is more information on the directives which are in raid configurationfiles; the options are listen in this file in the same order they shouldappear in the actual configuration file..TP\fBraiddev \fIdevice\fRThis introduces the configuration section for the stated device..TP\fBnr-raid-disks \fIcount\fRNumber of raid devices in the array; there should be \fIcount\fR\fIraid-disk\fR entries later in the file. (current maximum limitfor RAID devices -including spares- is 12 disks. This limit isalready extended to 256 disks in experimental patches.).TP\fBnr-spare-disks \fIcount\fRNumber of spare devices in the array; there should be \fIcount\fR\fIspare-disk\fR entries later in the file. Spare disks may onlybe used with RAID4 and RAID5, and allow the kernel to automaticallybuild new RAID disks as needed. It is also possible to add/removespares runtime via raidhotadd/raidhotremove, care has to be takenthat the /etc/raidtab configuration exactly follows the actualconfiguration of the array. (raidhotadd/raidhotremove does notchange the configuration file).TP\fBpersistent-superblock \fI0/1\fRnewly created RAID arrays should use a persistent superblock. Apersistent superblock is a small disk area allocated at the endof each RAID device, this helps the kernel to safely detect RAIDdevices even if disks have been moved between SCSI controllers.It can be used for RAID0/LINEAR arrays too, to protect againstaccidental disk mixups. (the kernel will either correctly reorderdisks, or will refuse to start up an array if something hashappened to any member disk. Of course for the 'fail-safe' RAIDvariants (RAID1/RAID5) spares are activated if any disk fails.)Every member disk/partition/device has a superblock, which carriesall information necessary to start up the whole array. (forautodetection to work all the 'member' RAID partitions should bemarked type 0xfd via fdisk) The superblock is not visible in thefinal RAID array and cannot be destroyed accidentally throughusage of the md device files, all RAID data content is availablefor filesystem use..TP\fBparity-algorithm \fIwhich\fRThe parity-algorithm to use with RAID5. It must be one of\fBleft-asymmetric\fR, \fBright-asymmetric\fR, \fBleft-symmetric\fR, or\fBright-symmetric\fR. left-symmetric is the one that offers maximumperformance on typical disks with rotating platters..TP\fBchunk-size \fIsize\fRSets the stripe size to \fIsize\fR kilobytes. Has to be a power of 2 andhas a compilation-time maximum of 4M. (MAX_CHUNK_SIZE in the kerneldriver) typical values are anything from 4k to 128k, the best valueshould be determined by experimenting on a given array, alot dependson the SCSI and disk configuration..TP\fBdevice \fIdevpath\fRAdds the device \fIdevpath\fR to the list of devices which comprise theraid system. Note that this command must be followed by one of\fBraid-disk\fR, \fBspare-disk\fR, or \fBparity-disk\fR. Also note thatit's possible to recursively define RAID arrays, ie. to set up a RAID5array of RAID5 arrays. (thus achieving two-disk failure protection, atthe price of more disk space spent on RAID5 checksum blocks).TP\fBraid-disk \fIindex\fRThe most recently defined \fBdevice\fR is inserted at position \fIindex\fRin the raid array..TP\fBspare-disk \fIindex\fRThe most recently defined \fBdevice\fR is inserted at position \fIindex\fRin the spare disk array..TP\fBparity-disk \fIindex\fRThe most recently defined \fBdevice\fR is moved to the end of theraid array, which forces it to be used for parity..TP\fBfailed-disk \fIindex\fRThe most recently defined \fBdevice\fR is inserted at position \fIindex\fRin the raid array as a failed device. This allows you to create raid 1/4/5devices in degraded mode - useful for installation. Don't use the smallest device in an array for this, put this after the raid-disk definitions!.SH NOTESThe raidtools are derived from the md-tools and raidtools packages, whichwere originally written by Marc Zyngier, Miguel de Icaza, Gadi Oxman, Bradley Ward Allen, and Ingo Molnar..SH SEE ALSO.IR raidstart (8),.IR raid0run (8),.IR mkraid (8),.IR raidstop (8)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -