I’m writing a program that wraps around dd to try and warn you if you are doing anything stupid. I have thus been giving the man page a good read. While doing this, I noticed that dd supported all the way up to Quettabytes, a unit orders of magnitude larger than all the data on the entire internet.

This has caused me to wonder what the largest storage operation you guys have done. I’ve taken a couple images of hard drives that were a single terabyte large, but I was wondering if the sysadmins among you have had to do something with e.g a giant RAID 10 array.

  • Nibodhika@lemmy.world
    link
    fedilink
    arrow-up
    3
    ·
    3 months ago

    Why would dd have a limit on the amount of data it can copy, afaik dd doesn’t check not does anything fancy, if it can copy one bit it can copy infinite.

    Even if it did any sort of validation, if it can do anything larger than RAM it needs to be able to do it in chunks.

    • FooBarrington@lemmy.world
      link
      fedilink
      arrow-up
      3
      ·
      3 months ago

      No, it can’t copy infinite bits, because it has to store the current address somewhere. If they implement unbounded integers for this, they are still limited by your RAM, as that number can’t infinitely grow without infinite memory.

    • nik9000@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      3 months ago

      Not looking at the man page, but I expect you can limit it if you want and the parser for the parameter knows about these names. If it were me it’d be one parser for byte size values and it’d work for chunk size and limit and sync interval and whatever else dd does.

      Also probably limited by the size of the number tracking. I think dd reports the number of bytes copied at the end even in unlimited mode.

    • data1701d (He/Him)@startrek.websiteOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      2 months ago

      It’s less about dd’s limits and more laughs the fact that it supports units that might take decades or more for us to read a unit that size.

    • Random Dent@lemmy.ml
      link
      fedilink
      English
      arrow-up
      1
      arrow-down
      1
      ·
      3 months ago

      Well they do nickname it disk destroyer, so if it was unlimited and someone messed it up, it could delete the entire simulation that we live in. So its for our own good really.