ไม่สามารถเล่นวิดีโอนี้
ขออภัยในความไม่สะดวก

ZFS on Linux the Billion dollar file system

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ส.ค. 2024
  • In this episode of the CyberGizmo we explore ZFS on Linux (ZoL). I wanted to cover this now because Ubuntu 19.10 will have an experimental mode to use ZFS as the root file system. I am by no means a ZFS expert I have used it in a massively large file store in production and switched over to using it at home about 2 years ago. I use BSD for my ZFS, so I am learning the linux side of things with you.
    I cover the commands you need to get started, how to add on additional storage, troubleshooting failures, replacing drives, improve performance and export your data to any system running ZFS
    Follow me:
    Twitter @djware55
    Facebook: / don.ware.7758
    Music Used in this video
    "NonStop" Kevin MacLeod (incompetech.com)
    Licensed under Creative Commons: By Attribution 3.0 License

ความคิดเห็น • 83

  • @ricebowl___
    @ricebowl___ 4 ปีที่แล้ว +5

    Thanks for the great ZoL overview. I have a bit more confidence managing ZFS pools and datasets now.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว

      Jesse, thank you for the kind comment and enjoy your ZFS pool

  • @AlexChambersXYZ
    @AlexChambersXYZ 4 ปีที่แล้ว +5

    Quality video. I like this format and teaching style. Thank you for this video! Would nice to see a Samba / NFS crash course from you

  • @drkskwlkr
    @drkskwlkr 4 ปีที่แล้ว +1

    I enjoyed immensely the format of this video, and subscribed to the channel immediately afterwards. I have a feeling this will become one of my favorite TH-cam channels!

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      Thank Ivan and welcome to the channel :)

  • @dragontav
    @dragontav 4 ปีที่แล้ว +28

    Good information. Please consider not using an animated background. The text flying by was distracting since I was trying to read along in your shell.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +9

      Check out the newer videos, the animated backgrounds have been replaced. And thanks for kind comment and suggestion

    • @davidinvenio3094
      @davidinvenio3094 4 ปีที่แล้ว

      I started feeling motion sick and didn't even notice the background at first! LOL Then I was laughing so hard because all I could think of was what a GREAT April Fools joke this is going to make, if I can wait that long, it may be a "June Fools" joke for some of my colleagues! LOL

    • @XArchangelofsexX
      @XArchangelofsexX 3 ปีที่แล้ว

      A.D.D. it's a hell of a disorder.

    • @hamesparde9888
      @hamesparde9888 3 ปีที่แล้ว

      @@CyberGizmo Bring back the animated backgrounds!

  • @DanielPeraalta
    @DanielPeraalta 4 ปีที่แล้ว +2

    Much obliged for this amazing class, so useful.. I got rid of many questions. But this transfer speed though (12:31) such an eye candy!

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว

      Thanks Daniel..yeah transfer speed is a more about bandwidth and latency...look for a more advanced video coming soon

  • @f1aziz
    @f1aziz 4 ปีที่แล้ว +2

    Thank you for to the point intro to ZFS. Please do a video on Samba sharing with ZFS. Thanks.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +2

      Thanks Faisal, and yeah good idea also maybe do the NFS side of that as well. Thanks for the suggestion

  • @DanCalloway
    @DanCalloway 4 ปีที่แล้ว +1

    Nice. Great video. Lots of info. Just for your edification, the command to display the QUOTA assigned to djware @ 25:24 in the video should have been: zfs get quota zfspool/djware. Replace ALL with QUOTA and it will list out only the quota for djware and not all status.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      Thanks Datapioneer, I am a bit of a ZFS noob still when it comes to the fancier config stuff, but am getting there

  • @andreigiubleanu
    @andreigiubleanu 2 ปีที่แล้ว

    DJ Ware is the man !

  • @ericneo2
    @ericneo2 ปีที่แล้ว

    Thank you for covering all this.

  • @BassBastiforever
    @BassBastiforever 3 ปีที่แล้ว

    Thanks a lot for the easy explained basics of zfs! I'm going to my build a NAS Server for my flat and I'm planning to use TrueNas.

  • @eznix
    @eznix 4 ปีที่แล้ว +6

    Thanks for the intro into ZFS on Linux. ZFS looks like overkill for my home use, but I can see why there is such interest.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      Thanks eznix I wanted to use to store my videos as i make them and want to expand it when i need more space

    • @bertnijhof5413
      @bertnijhof5413 4 ปีที่แล้ว +2

      I moved to ZFS, because it stopped the file corruption on my desktop due to the frequent power-fails. I now use it on laptop (1TB SSHD) and desktop (128GB SSD and 3 striped (raid-0) HDDs (2.5" 320GB, 3.5" 500GB and 1TB). Half of the SSD is used for booting from ZFS and the other half is used as SSD cache for the HDD datapools. Almost all files are LZ4 compressed and as a consequence so are memory and SSD caches.
      My SSHD works better, because due to the compression it can keep ~15GB instead of 8GB in the SS-Part of the SSHD. Due to the compression only half of the disk IO is needed to load programs or boot the system.
      I snapshot the OSes and if the system has problem, I roll back to one of the previous versions in approx 1 second. Also creating the snapshot takes approx 1 second. Recently I rolled back Ubuntu 19.10 to the last 19.04 snapshot, because Linux 5.3 of 19.10 had no support for Virtualbox.
      I backup my stuff to a 32-bits Pentium 4 with FreeBSD 12.0 and ZFS, using the send/receive from ZFS. It only transfers the changed records, so the backup beats rsync in speed easily. For me it is amazing:
      from Linux to Unix BSD
      from 2019 to 2003
      from AMD to Intel
      from 64 bits to 32 bits
      from SATA-3 to a striped mix (raid-0) of IDE + SATA-1 and both sides with 2.5" and 3.5" HDDs.

    • @Souls4Roca
      @Souls4Roca 4 ปีที่แล้ว +4

      how is it overkill? are you pairing it with raid 10 with 4 m.2 drives? zfs should have been the standard if oracle was not in the middle...

    • @iscariotproject
      @iscariotproject 4 ปีที่แล้ว +2

      there is no such thing as overkill for storage,pictures is memories of your life zfs will keep them safe,shadow copies also you saves you when you screw up something.

    • @AlexChambersXYZ
      @AlexChambersXYZ 4 ปีที่แล้ว +2

      @eznix if you want to consider the fact that ZFS offers more data stability than standard RAID, it can be worth it. As @iscariot project mentioned, if it's for pictures and memories of your life, it's important to keep them stored securely and avoid bit rot. But regardless of which path, offsite backup is a must.

  • @prashanthb6521
    @prashanthb6521 2 ปีที่แล้ว

    Clear demo & explanation. Thanks a lot sir.

  • @edwardg6721
    @edwardg6721 4 ปีที่แล้ว +1

    Thanks a lot. Good pace and very helpful!!!!!!!! great graphics too :)

  • @richardbennett4365
    @richardbennett4365 11 หลายเดือนก่อน

    It's for when deduplication is set to On. When deduplication for a dataset is on, then it is said for a rough rule of thumb one needs another GB RAM for each TB reduplicated. And, it's worse than that, because ZFS only allows 25% of RAM to be used for metadata, and the deduplication table that's held in RAM is part of / considered metadata, so multiply by 4 to end up with 4 GB RAM for V1 TB DEDUPLICATED data.

  • @demerit5
    @demerit5 2 ปีที่แล้ว

    Another great video. Thank you for the upload

  • @johnware1057
    @johnware1057 4 ปีที่แล้ว +1

    Really interesting! I was looking for something like this when my file server was hosted with Linux Mint. It's not up yet, but it will be using FreeNAS since I can integrate it with my Active Directory server.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      FreeNAS is really good, let me know how you like it when you get it all running

  • @themistoclesnelson2163
    @themistoclesnelson2163 ปีที่แล้ว

    I enjoyed the video and feel it was a good explanation.

  • @nielderfp
    @nielderfp 2 ปีที่แล้ว

    Brilliant! Thank you.

  • @lsatenstein
    @lsatenstein 3 ปีที่แล้ว

    Hi DJ.
    First of all, today, inauguration day, the USA has a new captain to steer the boat. The choice of captain and co-captain do know how to avoid the rocks, and where it is safe to dock.
    I am following up on a earlier email message from you that I took to heart and did something. I installed a version of Ubuntu 2010 with zfs .
    After watching your zfs on Linux Billion dollar question, I allocated a 120gig SSD to Ubuntu 2010 ZOL. My experience has been different from day to day.
    On the first reboot, I had to install software that I use daily (clang, meld, vim, and some others). Each use of apt install/upgrade automatically generated a new sub-volume.,
    Thus far I have about 30 sub-volumes and have not discovered a zfs method to eliminate the older ones.
    The first few days, as I did my testing, the system performance was slow but improving. zfs has a very large cache and manages it as a repository for short term and long term management. I takes time to fill that cache to where a probe into it is rapid.
    A program that I use over several days tends to reside almost permanently within the cache, while a reload or two of the same program within some hours of each other offers benefits for the second and later program reloads. Without reading the source code, I will assume that the cache also serves to hold some data in it's store. (config files, etc). During my evaluation, Ubuntu provided some linux software and some zfs updates. These updates were bug fixes, and not performance fixes. After a few days, system response time was slower than if I used btrfs, but good enough to consider remaining with zfs, , given zfs's crash and other recovery abilities. In terminal mode, a file save appears to occur some 1/4 second after the actual file was closed.
    After a week of UBUNTU 2010 ZFS use, I have to say that there were only a few issues with my Ubuntu 2010 and zfs installation. These are:
    a) The terminal handler for the keyboard goes through the file system, which results in the keyboard input, appearing on the screen only after some delay of perhaps 1/4 second. I can type the letter a, and wait to watch it appear some time after I entered the character. UBUNTU 2010 with zfs is based on the current gnome version. I noted nothing special about the Gnome installation.
    b) another quirk about the UBUNTU 2010 installation was the blocked - non-ability to log into the system directly, by foregoing the GUI interface. This access method is blocked or does not exist, or is broken. When trying direct terminal access the gui software shuts down---passwords are refused. However, if I log into the system, and then enter terminal mode, this route works fine.
    c) Updating grub fails, to replace an original grub.cfg. The latter, created at time of Ubuntu installation remains in effect. Updates to grub.cfg do not seem to take effect. My proof: "I had removed a Linux that was installed alongside of Ubuntu, and I was unable to update grub to show that the other distro was no longer installed". It's entry remained within the grub menu.
    d) I was able to install my brother printer and print a test page. So, printing is working.
    e) I have not been able to remove older zfs snapshots, and I feel that the ones that were created at time or installation should be purge-able .
    f) I did like the fact that my user number was 1000, with default group being 1000, consistent with Fedora, and Centos. Sudo setup works as expected.
    So, here is my opinion about zfs on Ubuntu2010 Linux. Ubuntu2010 with zfs is not yet ready for prime time. It is ok to use if all you do is desktop work or games. There is really no emergency access by direct terminal mode if a need arose. I believe that btrfs is better suited to the desktop than is zfs.
    What I would like to see in zfs for the future.
    a) To be able to setup by partition, rather than by disk. As I do not store gigabytes or terrabytes of files on my desktop system two 50 gig partitions would suffice. The most I have ever stored on my active distribution is 10 gits of data. I would have liked to partition my 120gig SSD tUbuntu2010 installation, into two parts of 55 gigs, and use each part as a raid pair. I did not see anywhere in the literature where I could fake a partition into emulating a physical disk. (aside, yes, separate disks for raid).
    In closing. I appreciate your youtube presenations and commentary and your discussion as a prelude to your physical installation demonstration. I look forward daily to your you-tube videos. You fill a void that is not covered by other presenters of Linux/bsd related software.

    • @CyberGizmo
      @CyberGizmo  3 ปีที่แล้ว

      Yep a new team at the helm, will be interesting to see how things unfold

    • @lsatenstein
      @lsatenstein 3 ปีที่แล้ว

      @@CyberGizmo An interesting phenomena. My text posted to You-Tube was error free, yet the one on you-tube had one or two missing characters and a switched character. Now for me, the mystery is: My home system or You-tube, which one is losing or modifying randomly, a text character.
      One final update about ZFS experience regarding my keyboard use and the delay. I added a tmpfs ram partition and working from it, the hesitation I was experiencing, as expected, is gone.

  • @davidinvenio3094
    @davidinvenio3094 4 ปีที่แล้ว

    Great video, very useful and as always very professional and easy to listen to and watch (so happy to read you won't do the animated backgrounds anymore although I've already seen newer videos and would have noticed it - and quick question about backgrounds, on your main workstation do you use transparency for your terminal windows etc.? or was it just for the video? I could never use it myself and wondered what the benefit was!)
    Thanks again for another great video and I hope you don't take my criticisms too seriously! Your videos are far far better than the vast majority here! Far far far far far :-)

  • @hamesparde9888
    @hamesparde9888 3 ปีที่แล้ว

    You should have showed it on BSD :). I'm typing this on a computer running FreeBSD and I'm going to be using ZFS on another computer running NetBSD.

  • @Nimitz_oceo
    @Nimitz_oceo 4 ปีที่แล้ว

    Fist time I'm here and automatically subscribed

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว

      Welcome to the channel, Christian and thanks for the sub!

  • @s9209122222
    @s9209122222 4 ปีที่แล้ว +1

    Hi, I have some questions about the ZFS.
    1. Do we need the same volume size of disks in the same mirror if it is equivalent to RAID1?
    2. Is there any GUI way to install it on Linux?
    3. Is there any benefit compare to EXT4 if we use it on a personal computer?
    4. It looks so much like the LVM on Linux, what's the difference between them?

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      Hi Julian, Thanks for the questions
      1. No they can be any size, but of course your performance and storage is maximized if they are
      2. Dunno will look into this further I use BSD for ZFS currently and am exploring it on Linux
      3. omg yes, you can snapshot, backup, move entire volumes to new machines, it is more reliable (at least on BSD, like I said am exploring it on Linux)
      4. Copy-on-Write, a more efficient RAID than LVM, better reliability and better use of resources. Plus LVM architecture is based on RAIDs as they were designed 30 yrs ago, ZFS is totally modern

  • @diegonayalazo
    @diegonayalazo 2 ปีที่แล้ว

    Thanks DJ

  • @ChrisMcDonough
    @ChrisMcDonough 4 ปีที่แล้ว

    I found this incredibly useful. I pay zero attention to "new" things so I had utterly ignored ZFS, but having had experience with Linux software RAID, I could immediately see the benefits. Since first watching this, and doing some successful reliability tests, I've converted over all my home RAID arrays to ZFS. Fwiw, for Ubuntu the jonothonf PPA has a version of ZFS that has encryption support (0.8.4) for 18.04, which is awesome. On 20.04, 0.8.3 is in the default repos, and a zfs import and export seems to work fine between the two both ways.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      sounds good Chris, it wont be long before the ZFS dev team merges the BSD and Linux code base together, the problem for me right now is I started my ZFS pool on BSD so trying to import it into linux wouldnt work for me right now, but very soon it will :)

    • @ChrisMcDonough
      @ChrisMcDonough 4 ปีที่แล้ว

      @@CyberGizmo it really is amazing software

  • @kennethdeveaux4854
    @kennethdeveaux4854 3 ปีที่แล้ว

    A couple of issues, perhaps brought about by the differences between linux and BSD.
    1. You say you created your cache ( about 32:45 ) as a mirror, but it's not. In any case, from the zpool docs, "Cache devices cannot be mirrored or part of a raidz configuration".
    2. Referring to drives as /dev/sd? is definitely discouraged. If you reboot, you can never be sure the same allocations will be made. (Yes, I know you can play with udev, but still). Best practice is to use the id's in /dev/disk/by-id/ or the uuid's in /dev/disk/by-uuid or /dev/disk/by-partuuid. As this is an introductory lesson, it's good to get off on the right foot from the start.
    Just my 2c worth :-)

    • @CyberGizmo
      @CyberGizmo  3 ปีที่แล้ว

      Good catch on #1 I noticed that after I put the video up and meant to put a comment in to describe the problems. and #2 I know about that, and usually use disk-by-id I know they can fall out of order, but I will say this ZFS does not care what order the drives are in, have had them shift before and the pool will keep working

    • @kennethdeveaux4854
      @kennethdeveaux4854 3 ปีที่แล้ว

      @@CyberGizmo I'd be worried that if, for example, I took out a failed drive /dev/sdc, and put in a new replacement which the system labelled ... /dev/sdc. Not sure what would happen then. I tend to use the by-id from the beginning just to be sure. It's my parents' fault. They shouldn't have given me "Pedantic" as a middle name!

  • @lsatenstein
    @lsatenstein 3 ปีที่แล้ว

    HI DJ
    I am revisiting zfs/zol again. I have installed Ubuntu with zfs. Are following the software development of zol?
    From what I read and from youtube videos, zfs blocksize is 520 bytes. One of my hard drives is the standard type with 512bytes per block, while a newer one is 4096 bytes per block. I am uncertain what my m.2 device formats blocks.
    Now my question is about wasted blocks. With 520 bytes per block, would zol/zfs use two of the standard 512blocks to store 512 bytes of data. Is this correct?
    For the larger 4096 block, it is not an issue for me. I do not have any of those hardware drives.
    My second curiousity is about zol/zfs writing a large file. Zol would checksum the 512byes, and then write out 520. for each 512 bytes a 520byte block is need to land on a new hardware block, which implies that a zfs file, when copied to Linux, consumes twice the diskspace due to the appended checksum?
    For my own use, I have not accumulated more than 500megabytes of data. I am really just wondering if those 500megs will consume the one terrabye space.
    PS1. Thank you for all your effort at presenting informative videos. I appreciate your analytical approach to the new technologies.
    PS 2 I am not enamoured with using btrfs. I/O seems quite a bit slower than ext4, xfs and zfs. I have to benchmarks to do the speed comparisons.

  • @JD-im4wu
    @JD-im4wu 3 ปีที่แล้ว

    what are your thoughts of Linux vs FreeBSD userland ZFS as you know is native to FreeBSD. I've never made the transition to FreeBSD personally mainly due to using Nvidia as my GPU and I heard of headaches with FreeBSD and hardware so I never tested their stuff out. WOuld you recommend FreeBSD as a workstation over Linux to a low level developer? I use Debian as my base as of now and have to use a VM for testing new software out that is unavailable in the Stable version. I tried Fedora for more updated packages but they crashed me multiple times on updates due to proprietary vid cards and also I found many prior versions glitchy at best. I thought FreeBSD might be a great choice but never had the drive and spared the time to make the switch over or even try it out in a VM due to such a busy schedule lately dealing with outside of computers...

  • @bertnijhof5413
    @bertnijhof5413 4 ปีที่แล้ว +1

    Good explanation, but:
    - You are using an ancient version of ZFS 0.7.5. The current version is for Ubuntu 19.10 is 0.8.1 and for ZOL it is 0.8.2. For Ubuntu 19.04 it is 0.7.12.
    - 20 years of ZFS, you can't be that old yet. ZFS has been released by Sun in 2005, that is 14 years ago.

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว

      LOL true I meant to say since 2005 they had Sun in to help with the install, and I am using 18.04 LTS version of Ubuntu I dont like using the short term releases for my servers, thanks for the comment

    • @bertnijhof5413
      @bertnijhof5413 4 ปีที่แล้ว

      @@CyberGizmo This week Tuesday or Wednesday Ubuntu releases a daily build, that can boot from ZFS, with all kind of fancy recovery features in the Grub Menus. That would be interesting.

    • @bertnijhof5413
      @bertnijhof5413 4 ปีที่แล้ว

      @@CyberGizmo I had the same approach for my PCs, but I moved all work to VMs. Those VMs still run the LTS versions, like e.g. Xubuntu 18.04 for the Office/Email stuff and Ubuntu 16.04 for Banking and PayPal. For the Host OS I'm more flexible, I like a minimal install, but with the latest AMD drivers and the latest ZFS versions, because all VMs profit from those improvements.

  • @sagan666
    @sagan666 4 ปีที่แล้ว +1

    zpool import -D will look for destroyed zpools. Just in case you do make that mistake.

  • @Snyder0317
    @Snyder0317 4 ปีที่แล้ว

    I'd love to see a video about backing up zfs snapsots / zfs replication, if you have the time. :)

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      That one is in progress for this week (I hope) if the machines cooperate and allows me to do a snapshot, a clone, and want to cover DAC vs ACL on linux...will plan a third on sharing your ZFS out to the rest of the network using NFS and CIFS(Samba)

    • @Snyder0317
      @Snyder0317 4 ปีที่แล้ว

      @@CyberGizmo Looking forward to them!

  • @johngianopoulos6668
    @johngianopoulos6668 ปีที่แล้ว

    Very good video but moving background is distracting. Thanks.

  • @TylerDeBoy
    @TylerDeBoy 4 ปีที่แล้ว

    Great video. Completely going over everything I needed! Thanks! How would you go about backing up the entire pool to another drive?

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว +1

      Great question a subject of my next video on ZFS - stay tuned.

  • @Lesterandsons
    @Lesterandsons 4 ปีที่แล้ว

    Excellent

  • @arnoldmatulin2398
    @arnoldmatulin2398 ปีที่แล้ว

    what is the meaning of refer in zfs list ? what they used for?

    • @CyberGizmo
      @CyberGizmo  ปีที่แล้ว +1

      Hi Arnold, refer is short for reference,. Refer is the amount of data used in the dataset, for mountable datasets it should be the same as used, for datasets that can not be mounted like the toplevel for example, used will contain the total amount of storage left and refer will contain the amount of overhead in the pool named dataset. Since I cant write files there (see can mount property). The other times Used and Refer may differ is when zfs has not fully committed a write to the dataset or I have a snapshot and creates, updated and delete are adding data to the snapshot I am sure there is more to it than that, but that's what i know of.

  • @Souls4Roca
    @Souls4Roca 4 ปีที่แล้ว

    the animated background is at an odd frame rate number compared to the video and it's really affecting the ability to watch the video, try slowing it down and if you are encoding to 60fps have it at 30fps or at 50fps 24, for 30fps video 14.5 should look a bit smoother

    • @CyberGizmo
      @CyberGizmo  4 ปีที่แล้ว

      Thanks for the suggestion have already corrected it in the videos since, that's an old video now

  • @MarkConstable
    @MarkConstable 2 ปีที่แล้ว

    A couple of years later and I'd love to watch this video but the zooming background is making me sick.

  • @JD-im4wu
    @JD-im4wu 3 ปีที่แล้ว

    ...as far as Ubuntu I have a love and hate relationship with them. Albeit, mostly hate.

  • @inf0stud
    @inf0stud 4 ปีที่แล้ว

    For snapshots I use YYYYMMDD as this sorts better than MMDDYY

  • @dienadel30
    @dienadel30 4 ปีที่แล้ว

    pvdisplay faster ways lvms with no formatting

  • @dienadel30
    @dienadel30 4 ปีที่แล้ว

    Drop drives

  • @MrArmas555
    @MrArmas555 4 ปีที่แล้ว

    ++

  • @dienadel30
    @dienadel30 4 ปีที่แล้ว

    software

  • @dienadel30
    @dienadel30 4 ปีที่แล้ว

    What a joke high lvm layer z layer partition lolz