Difference between revisions of "ZFS Installation"

From GridPP Wiki
Jump to: navigation, search
Line 1: Line 1:
 
More detailed information can be found in this link --->  [http://gridpp-storage.blogspot.com/2016/04/setting-up-of-zfs-based-storage-server.html here]
 
More detailed information can be found in this link --->  [http://gridpp-storage.blogspot.com/2016/04/setting-up-of-zfs-based-storage-server.html here]
  
The omreport/omconfig commands are special to Dell machines but there should be similar commands available for other installations.
+
The omreport/omconfig commands are special to Dell machines but there should be similar commands available for other installations.<br>
 
+
You should have installed ZFS for Linux from the [http://zfsonlinux.org/ official repository] instead of using it from a a 3rd party repository.
  
  

Revision as of 15:38, 22 February 2017

More detailed information can be found in this link ---> here

The omreport/omconfig commands are special to Dell machines but there should be similar commands available for other installations.
You should have installed ZFS for Linux from the official repository instead of using it from a a 3rd party repository.


1) find out which disks are there to be used, IF you have a raid controller only and no HBA, otherwise continue at 3)

  omreport storage pdisk controller=0|grep -E "^ID|Capacity"


2) for the disks id found above create single raid0 IF you have a raid controller only and no HBA:

 for i in $(seq 0 11); 
 do 
   omconfig storage controller controller=NUMBER action=createvdisk raid=r0 size=max pdisk=0:0:$i; 
 done

The pdisk id needs to be adapted!


3) look if all disks are available

  lsblk |grep disk


4) find the correct disks to be put in the storage zpool (example for 2TB disks)

  lsblk |grep 1.8T


5) with the names returned by lsblk create a raidz2 or raidz3 depending on your needs

Be sure not to forget to configure the spare!

 zpool create -f POOLNAME raidz3 sdb sdc sdd sde sdf sdg sdh sdi sdj sdk sdl sdm sdab sdad sdae sdag sdah sdaj spare sdak


6) enable different features of zpool and zfs and configure it correctly

  zfs set compression=lz4 POOLNAME;
  zpool set autoreplace=on POOLNAME;
  zpool set autoexpand=on POOLNAME;
  zfs set relatime=on POOLNAME;
  zfs set xattr=sa POOLNAME;
  zpool export POOLNAME;
  zpool import -d /dev/disk/by-id POOLNAME;

7) for usage with DPM:

  zfs create POOLNAME/gridstorage01
  chown -R dpmmgr:dpmmgr /POOLNAME