yum groupinstall "Development Tools"
yum install kernel-devel zlib-devel libuuid-devel libblkid-devel libselinux-devel e2fsprogs-devel lsscsi parted lsscsi nano mdadm bc
Obtain the latest DKMS RPM package from Dell. Note that you need the latest version 2.x above for the installation to proceed properly.
wget http://linux.dell.com/dkms/permalink/dkms-2.2.0.3-1.noarch.rpmInstall the RPM package,
rpm -Uvh dkms-2.2.0.3-1.noarch.rpm
Obtain the latest version of DKMS RPM modules for SPL and ZFS,
wget http://github.com/downloads/zfsonlinux/spl/spl-modules-dkms-0.6.0-rc11.noarch.rpm
wget http://github.com/downloads/zfsonlinux/zfs/zfs-modules-dkms-0.6.0-rc11.noarch.rpmInstall SPL module first,
rpm -Uvh spl-modules-dkms-0.6.0-rc11.noarch.rpmObtain SPL RPM, rebuild and install,
wget http://github.com/downloads/zfsonlinux/spl/spl-0.6.0-rc11.src.rpm
rpmbuild --rebuild spl-0.6.0-rc11.src.rpm
rpm -Uvh rpmbuild/RPMS/x86_64/spl-0.6.0-rc11.el6.x86_64.rpmInstall ZFS module,
rpm -Uvh zfs-modules-dkms-0.6.0-rc11.noarch.rpm
Obtain ZFS RPM, rebuild and install,
wget http://github.com/downloads/zfsonlinux/zfs/zfs-0.6.0-rc11.src.rpm
rpmbuild --rebuild zfs-0.6.0-rc11.src.rpm
rpm -Uvh rpmbuild/RPMS/x86_64/zfs-0.6.0-rc11.el6.x86_64.rpm
rpm -Uvh rpmbuild/RPMS/x86_64/zfs-devel-0.6.0-rc11.el6.x86_64.rpm
rpm -Uvh rpmbuild/RPMS/x86_64/zfs-dracut-0.6.0-rc11.el6.x86_64.rpm
rpm -Uvh rpmbuild/RPMS/x86_64/zfs-test-0.6.0-rc11.el6.x86_64.rpmRestart your system. DKMS might automatically rebuild the SPL and ZFS package during the system boot up if your kernel is updated.
To check ZFS is properly loaded, run:
lsmod | grep -i zfs
Check installed hard disk properties,zfs 1104868 0zcommon 43286 1 zfsznvpair 47487 2 zfs,zcommonzavl 6925 1 zfszunicode 323120 1 zfsspl 253420 5 zfs,zcommon,znvpair,zavl,zunicode
fdisk -l | grep GB
Create ZFS storage pool with name as "tank" consisting of sdb sdd and sde. The -f is to override any errors,Disk /dev/sdb: 1000.2 GB, 1000204886016 bytesDisk /dev/sde: 1000.2 GB, 1000204886016 bytesDisk /dev/sdd: 1000.2 GB, 1000204886016 bytesDisk /dev/sdc: 64.0 GB, 64023257088 bytesDisk /dev/sda: 64.0 GB, 64023257088 bytesDisk /dev/mapper/vg_azure0-lv_root: 50.2 GB, 50189041664 bytes
zpool create tank raidz -f sdb sdd sdeCheck the pool,
zpool status
Setup sdc as L2ARC cache drive (the -f is to override any errors),pool: tankstate: ONLINEscan: none requestedconfig:NAME STATE READ WRITE CKSUMtank ONLINE 0 0 0raidz1-0 ONLINE 0 0 0sdb ONLINE 0 0 0sdd ONLINE 0 0 0sde ONLINE 0 0 0errors: No known data errors
zpool add tank cache -f sdcFinally, let's check our ZFS pool status,
zpool status
Additionally, let's put some tuning to the file system to obtain a better performance,pool: tankstate: ONLINEscan: none requestedconfig:NAME STATE READ WRITE CKSUMtank ONLINE 0 0 0raidz1-0 ONLINE 0 0 0sdb ONLINE 0 0 0sdd ONLINE 0 0 0sde ONLINE 0 0 0cachesdc ONLINE 0 0 0errors: No known data errors
zfs set compression=on tank
zfs set dedup=on tank
zfs set atime=off tankYeay! Now things are working great! For further info, please refer to the following links:
http://pingd.org/2012/installing-zfs-raid-z-on-centos-6-2-with-ssd-caching.html
http://hub.opensolaris.org/bin/download/Community+Group+zfs/docs/zfsadmin.pdf
http://constantin.glez.de/blog/2010/04/ten-ways-easily-improve-oracle-solaris-zfs-filesystem-performance
2 comments:
thank you soooooooooo much!!!
you just made my life tons easier!!!
Great post, thanks for sharing!
Post a Comment