{"id":300,"date":"2020-06-14T04:41:27","date_gmt":"2020-06-14T04:41:27","guid":{"rendered":"http:\/\/byomkesh.in\/wordpress\/?p=300"},"modified":"2024-02-06T18:59:08","modified_gmt":"2024-02-06T13:29:08","slug":"zfs-instalation-in-ictuxen1","status":"publish","type":"post","link":"http:\/\/byomkesh.in\/wordpress\/zfs-instalation-in-ictuxen1\/","title":{"rendered":"ZFS instalation in ictuxen1"},"content":{"rendered":"\n<p> dd if=\/dev\/zero count=8192000 bs=1024 of= test.hdd<\/p>\n\n\n\n<p>dd if=\/dev\/zero count=20480000 bs=1024 of=cam1.hdd<br> dd if=\/dev\/zero count=20480000 bs=1024 of=cam2.hdd<\/p>\n\n\n\n<p>yum install -y http:\/\/download.zfsonlinux.org\/epel\/zfs-release.el6.noarch.rpm<\/p>\n\n\n\n<p>;;; lost lot of time due to following error <br> ;; Error: Package: zfs-dkms-0.8.4-1.el6.noarch (zfs)<br> ;;           Requires: dkms &gt;= 2.2.0.3<br> ;;<br> ;; tried several things, al last I found that by default &#8220;zfs-kmod&#8221; repo is disabled by enabling it the yum install was success<br> ;;<\/p>\n\n\n\n<p>yum install &#8220;kernel-devel-uname-r == $(uname -r)&#8221; zfs &#8211;enablerepo zfs-kmod<\/p>\n\n\n\n<p>\/sbin\/modprobe zfs<br>\nzpool create testpool \/home\/test.hdd<\/p>\n\n\n<p>[root@ictuxen1 ~]<\/p>\n\n\n\n<p># zfs list<br>\nNAME       USED  AVAIL     REFER  MOUNTPOINT<br>\ntestpool  91.5K  7.27G       24K  \/testpool\n<\/p>\n\n\n<p>[root@ictuxen1 ~]<\/p>\n\n\n\n<p># zpool list<br>\nNAME       SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT<br>\ntestpool  7.50G   116K  7.50G        &#8211;         &#8211;     0%     0%  1.00x    ONLINE  &#8211;\n<\/p>\n\n\n<p>[root@ictuxen1 ~]<\/p>\n\n\n\n<p># zpool status<br>\n  pool: testpool<br>\n state: ONLINE<br>\n  scan: none requested<br>\nconfig:\n<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>    NAME              STATE     READ WRITE CKSUM\n    testpool          ONLINE       0     0     0\n      \/home\/test.hdd  ONLINE       0     0     0<\/code><\/pre>\n\n\n\n<p>errors: No known data errors<\/p>\n\n\n<p>[root@ictuxen1 ~]<\/p>\n\n\n\n<p># zpool destroy testpool<br><\/p>\n\n\n<p>[root@ictuxen1 home]<\/p>\n\n\n\n<p># rm test.hdd\n<\/p>\n\n\n\n<p>zpool create cam1pool \/home\/cam1.hdd <br>\nzpool list<\/p>\n\n\n\n<p>zfs create -o mountpoint=\/home\/cam1 cam1pool\/fs1<br>\nzfs set quota=19g cam1pool\/fs1<br>\nzfs set reservation=1g cam1pool\/fs1<\/p>\n\n\n<p>[root@ictuxen1 home]<\/p>\n\n\n\n<p># zfs list<br>\nNAME           USED  AVAIL     REFER  MOUNTPOINT<br>\ncam1pool      1.00G  17.9G       24K  \/cam1pool<br>\ncam1pool\/fs1    24K  18.9G       24K  \/home\/cam1\n<\/p>\n\n\n\n<p>zpool create cam2pool \/home\/cam2.hdd <\/p>\n\n\n<p>[root@ictuxen1 home]<\/p>\n\n\n\n<p># zpool list<br>\nNAME       SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT<br>\ncam1pool  19.5G   174K  19.5G        &#8211;         &#8211;     0%     0%  1.00x    ONLINE  &#8211;<br>\ncam2pool  19.5G    88K  19.5G        &#8211;         &#8211;     0%     0%  1.00x    ONLINE  &#8211;\n<\/p>\n\n\n\n<p>zfs create -o mountpoint=\/home\/cam2 cam2pool\/fs1<br>\nzfs set quota=19g cam2pool\/fs1<br>\nzfs set reservation=1g cam2pool\/fs1<\/p>\n\n\n<p>[root@ictuxen1 home]<\/p>\n\n\n\n<p># zfs list<br> NAME           USED  AVAIL     REFER  MOUNTPOINT<br> cam1pool      1.00G  17.9G       24K  \/cam1pool<br> cam1pool\/fs1    24K  18.9G       24K  \/home\/cam1<br> cam2pool      1.00G  17.9G       24K  \/cam2pool<br> cam2pool\/fs1    24K  18.9G       24K  \/home\/cam2<\/p>\n\n\n\n<p>REMOVING ZFS<\/p>\n\n\n\n<p>[root@ictuxen1 tmp]# zfs unmount cam1pool\/fs1<br>[root@ictuxen1 tmp]# zfs unmount cam2pool\/fs1<\/p>\n\n\n\n<p>[root@ictuxen1 tmp]# zfs list<br>NAME USED AVAIL REFER MOUNTPOINT<br>cam1pool 1.00G 17.9G 24K \/cam1pool<br>cam1pool\/fs1 54.5M 18.8G 54.5M \/home\/cam1<br>cam2pool 1.00G 17.9G 24K \/cam2pool<br>cam2pool\/fs1 59.8M 18.8G 59.8M \/home\/cam2<\/p>\n\n\n\n<p>[root@ictuxen1 tmp]# zfs destroy cam1pool\/fs1<br>[root@ictuxen1 tmp]# zfs destroy cam2pool\/fs1<\/p>\n\n\n\n<p>[root@ictuxen1 tmp]# zfs list<br>NAME USED AVAIL REFER MOUNTPOINT<br>cam1pool 207K 18.9G 24K \/cam1pool<br>cam2pool 314K 18.9G 24K \/cam2pool<\/p>\n\n\n\n<p>[root@ictuxen1 tmp]# zpool destroy cam1pool<br>[root@ictuxen1 tmp]# zpool destroy cam2pool<\/p>\n\n\n\n<p>[root@ictuxen1 tmp]# zpool list<br>no pools available<br>[root@ictuxen1 tmp]# zfs list<br>no datasets available<\/p>\n\n\n\n<p>To add deduplication which is by default is off. Check using(replace poolname with your own poolname):<\/p>\n\n\n\n<p>zfs get all poolname |grep -i dedup<\/p>\n\n\n\n<p>Then use the following after pool creation to enable it:<\/p>\n\n\n\n<p>zfs set dedup=on poolname<\/p>\n\n\n\n<p>To add compression first check with (use your own poolname) :<\/p>\n\n\n\n<p>zfs get all poolname | grep compress<\/p>\n\n\n\n<p>Then the following to add compression<\/p>\n\n\n\n<p>zfs set compression=lz4 poolname<\/p>\n","protected":false},"excerpt":{"rendered":"<p>dd if=\/dev\/zero count=8192000 bs=1024 of= test.hdd dd if=\/dev\/zero count=20480000 bs=1024 of=cam1.hdd dd if=\/dev\/zero count=20480000 bs=1024 of=cam2.hdd yum install -y http:\/\/download.zfsonlinux.org\/epel\/zfs-release.el6.noarch.rpm ;;; lost lot of time due to following error ;; Error: Package: zfs-dkms-0.8.4-1.el6.noarch (zfs) ;; Requires: dkms &gt;= 2.2.0.3 ;; ;; tried several things, al last I found that by default &#8220;zfs-kmod&#8221; repo is disabled &hellip; <a href=\"http:\/\/byomkesh.in\/wordpress\/zfs-instalation-in-ictuxen1\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">ZFS instalation in ictuxen1<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-300","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"aioseo_notices":[],"_links":{"self":[{"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/posts\/300","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/comments?post=300"}],"version-history":[{"count":5,"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/posts\/300\/revisions"}],"predecessor-version":[{"id":340,"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/posts\/300\/revisions\/340"}],"wp:attachment":[{"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/media?parent=300"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/categories?post=300"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/byomkesh.in\/wordpress\/wp-json\/wp\/v2\/tags?post=300"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}