Slashdot Mirror


MIT's New File System Won't Lose Data During Crashes

jan_jes sends news that MIT researchers will soon present a file system they say is mathematically guaranteed not to lose data during a crash. While building it, they wrote and rewrote the file system over and over, finding that the majority of their development time was spent defining the system components and the relationships between them. "With all these logics and proofs, there are so many ways to write them down, and each one of them has subtle implications down the line that we didn’t really understand." The file system is slow compared to other modern examples, but the researchers say their formal verification can also work with faster designs. Associate professor Nickolai Zeldovich said, "Making sure that the file system can recover from a crash at any point is tricky because there are so many different places that you could crash. You literally have to consider every instruction or every disk operation and think, ‘Well, what if I crash now? What now? What now?’ And so empirically, people have found lots of bugs in file systems that have to do with crash recovery, and they keep finding them, even in very well tested file systems, because it’s just so hard to do.”

106 of 168 comments (clear)

  1. But is it useful? by Junta · · Score: 4, Interesting

    slow compared to other modern examples, but the researchers say their formal verification can also work with faster designs

    If we can accept 'slow', it's not that difficult to build an always consistent filesystem. While they can formally verify a faster design should one exist, there remains the question of whether it's possible to be formally proven to be resilient to data loss while taking some of the utterly required performance shortcuts for acceptable performance. I suspect the answer is that some essential performance 'shortcuts' will fail that verification.

    --
    XML is like violence. If it doesn't solve the problem, use more.
    1. Re:But is it useful? by FranTaylor · · Score: 1

      If we can accept 'slow', it's not that difficult to build an always consistent filesystem.

      citation required

    2. Re:But is it useful? by Anonymous Coward · · Score: 5, Funny

      A sufficiently slow writing filesystem is indistinguishable from a read-only filesystem. Read-only filesystems are consistent. Therefore, a slow enough writing filesystem is consistent.

      For more serious analysis of crash-resistant write sequences, look elsewhere in this discussion.

    3. Re:But is it useful? by FranTaylor · · Score: 1

      what does this phrase even mean? why does speed or slowness matter? you can play the video of a disk disaster at any speed you want

    4. Re:But is it useful? by Darinbob · · Score: 1

      Write a block to the storage device.
      Apply all necessary flush and synchronization commands, and a few unnecessary ones.
      Power off the storage device.
      Power the device back on.
      Read back the block to ensure it was actually written.
      Repeat as necessary until block is confirmed as having been written.
      Continue with block number two...

    5. Re:But is it useful? by arglebargle_xiv · · Score: 1

      If we can accept 'slow', it's not that difficult to build an always consistent filesystem.

      citation required

      Sheesh, do we have to do the Googling for you?

  2. Well it won't lose data... by frank_adrian314159 · · Score: 1

    ... until they find a logical flaw in their proofs or the bugs in mechanical verifier(s) that helped them prove the driver correct.

    --
    That is all.
    1. Re:Well it won't lose data... by Anonymous Coward · · Score: 1, Interesting

      Or – more likely – until they find a flaw in their assumptions, like a lower-level software stack that swears "yes, this data has been committed to storage" slightly before that's actually true.

    2. Re:Well it won't lose data... by gweihir · · Score: 1

      That is pretty unlikely, but the whole thing is a worthless stunt anyways. The problem is that they have to use some hardware model and that will have errors. Hence the assurances they claim are purely theoretical, and in practice their thing may well be less reliable than a well-tested file system with data-journal, like ext3.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
  3. Formally verified system fails by Anonymous Coward · · Score: 3, Funny

    MIT's new "crash-proof file system" crashed today amid accusations of bugs in the formal proof verification software used to formally verify it.

    MIT are now working on a formal verification of the formal verification system, in order to avoid similar formal-verification-related problems in the future.

    1. Re:Formally verified system fails by Anonymous Coward · · Score: 1

      It's formal verifications all the way down, until you meet the axiom of choice.

    2. Re:Formally verified system fails by arglebargle_xiv · · Score: 1

      MIT's new "crash-proof file system" crashed today amid accusations of bugs in the formal proof verification software used to formally verify it.

      So the whole thing was a bit of a Coq-up?

  4. Linux File Systems by Anonymous Coward · · Score: 5, Interesting

    I find some of the current file systems to be adequately reliable. Even their performance is acceptable. But, the Linux systems are lacking.

    Is there a reliable Linux file system such as EXT4 that has an easy to use copy on write(CoW) feature to allow instant recovery of any file changed at any time?

    rm ./test
    restore --last test ./

    dd if=/dev/random of=./test bs=1M count=10
    restore --datetime test ./

    Novell Netware FS did all this and more in 1995 FFS! Fifteen years later and Linux doesn't seem to be able to do this. NTFS doesn't seem to be able to do this either. Yet Novell is dead?

    1. Re:Linux File Systems by Anonymous Coward · · Score: 2, Informative

      Well, ex-Googler Kent Overstreet recently announced a COW filesystem on lkml:

      https://lkml.org/lkml/2015/8/21/22

      Not ready for production I would say, but looks interesting.

    2. Re:Linux File Systems by swb · · Score: 4, Interesting

      I still think Netware's filesystem permission model was better than anything out there now, at least for filesharing.

      The feature I miss the most is allowing traversal through a directory hierarchy a user has no explicit permissions for to get to a folder they do have permissions for. I find the workarounds for this in other filesystems to be extremely ugly.

      I think NDS was better in a lot of ways than AD, although it would have been nice if there had been something better than bindery mode for eliminating the need for users to know their fully qualified NDS name.

      I also kind of wish TCP/IP had used the network:mac numbering scheme that IPX used. The rest of IPX/SPX I don't need, but there'd be no talk of address exhaustion of IPv4 if that scheme had been adopted, little need for DHCP address assignment and the addressing scheme would scale to the larger broadcast domains enabled by modern switching (avoiding the need to renumber legacy segments completely when they exhausted a /24 space and expansion via mask reduction wasn't possible due to linear numbering on adjacent segments).

    3. Re:Linux File Systems by Christian+Smith · · Score: 3, Interesting

      I find some of the current file systems to be adequately reliable. Even their performance is acceptable. But, the Linux systems are lacking.

      Is there a reliable Linux file system such as EXT4 that has an easy to use copy on write(CoW) feature to allow instant recovery of any file changed at any time?

      NILFS2 provides continuous point in time snapshots, which can be selectively mounted and data recovered. Not quite as instant recovery as your use case examples, but it's only a few commands/wrapper scripts away.

    4. Re:Linux File Systems by nbvb · · Score: 3, Interesting

      Bah, forget NetWare, VINES and StreetTalk did everything you ask for and then some way before NDS was even a thought.

      VINES' ACL's were beautifully granular ...

    5. Re:Linux File Systems by allo · · Score: 1

      nilfs2 does.

    6. Re:Linux File Systems by swb · · Score: 2

      It's a kludge, though, in NTFS, in Netware it just worked.

      IPX/SPX as a layer 3 protocol isn't what I wanted, I wanted TCPv4 with a network prefix and the MAC as the node address. Clients could derive their address automatically from network traffic by picking up the network address from the wire and they already knew their MAC address.

      Although to be honest, IPX/SPX even as a secondary protocol wasn't that bad to support in a mixed environment. We had no issues with TCP, IPX *and* CrappleTalk on 512k frame relay links. We retired internetworking on IPX when the last Netware servers went away but were stuck with AppleTalk (circa 2003).

    7. Re:Linux File Systems by LDAPMAN · · Score: 2

      It still is: https://dl.netiq.com/Download?...

      I build multi-million user IAM systems on it for a living.

    8. Re:Linux File Systems by LordLimecat · · Score: 1

      How is it a kludge? You have the option in NTFS of having that everyone:traverse permission propogating through the directory heirarchy, but it isnt required. It sounds like Netware just assumes that traversal rights are implicit, where there may be scenarios where it is not desired.

    9. Re:Linux File Systems by Bengie · · Score: 2

      A true versioning file system would crumble under an IO workload with many small updates. The problem with btrfs is you can't snapshot two subvolumes in sync with eachother. Snapshots are per subvolume. In ZFS, snapshots are at the pool level, allowing volumes to be in perfect sync.

    10. Re:Linux File Systems by psmears · · Score: 1

      I wanted TCPv4 with a network prefix and the MAC as the node address. Clients could derive their address automatically from network traffic by picking up the network address from the wire and they already knew their MAC address.

      You mean more or less exactly what IPv6 does (in many cases)?

    11. Re:Linux File Systems by AvitarX · · Score: 1

      That's how I read it, wishing that v4 had done that already.

      --
      Wow, sent an e-mail as suggested when clicking on "use classic" banner, and got a fast response that addressed my msg
    12. Re:Linux File Systems by vovin · · Score: 1

      You are looking for NILFS2.
      Of course you use more disk because you nothing gets deleted...

    13. Re:Linux File Systems by Bengie · · Score: 1

      I think you mean "volume" instead of "filesystem". All snapshots are relative to the pool. You can create a snapshot of several volumes at once in perfect sync because the snapshot is actually at the pool level, but only attached to the relative volume that you're looking at. When you have mounted volumes inside of volumes, not only will the data of the current volume be part of the snapshot, but all of the data in the mounted volumes.

      BTRFS stores snapshots in the volume, ZFS stores them in the pool. If you snapshot a BRTFS sub-volume, you will only get that sub-volume and nothing else. You can make a script to loop through the mounted sub-volumes within a sub-volume, but there is no guarantee they will be all in sync. Even worse, if a sub-volume later gets unmounted and moved somewhere else, or the sub-volume is deleted in BTRFS, all data for that sub-volume is gone, including it's snapshots. In ZFS, if you have a snapshot of parent volume and there are mounted child volumes, and you snapshot at the parent level, everything is part of that snapshot, including the contents of the child volumes.

    14. Re:Linux File Systems by mattack2 · · Score: 1

      Novell Netware FS did all this and more in 1995 FFS! Fifteen years later ...

      I think your Novell system needs a new clock battery or something...

    15. Re:Linux File Systems by arglebargle_xiv · · Score: 1

      Bah, forget this newfangled crap, Multics was doing this half a century ago (which includes use of RAID tape drives, checkpointing, ACLs, and other recent innovations).

    16. Re:Linux File Systems by Bengie · · Score: 1

      I already said that. The snapshot is "attached" to the dataset, but the snapshot is scoped to the pool.

    17. Re: Linux File Systems by bill_mcgonigle · · Score: 1

      what is the command to snapshot two zvols atomically?

      --
      My God, it's Full of Source!
      OUTSIDE_IP=$(dig +short my.ip @outsideip.net)
    18. Re:Linux File Systems by ebvwfbw · · Score: 1

      Really AC? A simple un-delete trick and you're impressed? It can be done with EXT as well, however why would you even want to do that? This is why you deleted it in the first place. Don't delete stuff you want. You should have learned that back in 1995. You know, I have a little course you can take from me. $5,000 for one weeks worth of training. This is where I have you type in for about a day, and delete your file. You must then type it in again the second day, to delete it again. By the 5th day you should be over your unintentional deletion problem. We'll all go out to Ruby Tuesdays or something for dinner and laugh at you.

      This isn't why Novell died. It was a marketing tsunami from Microsoft to sell a network services they couldn't give away before. Repackage it, call it "New Technology" and people bought their BS. I remember we were replacing a single Novell server with up to 5 much newer, much more memory, disk, etc machines to do barely the same job as the old reliable Novell server. Here we are all these years later and M$ still isn't much better. Unix still takes rules. Even in Government agencies, sure they have a few MS boxes, about as many or more Linux machines. The lightweight stuff is on the M$ boxes, the real computing is still on the Linux machines. Always will be.

    19. Re: Linux File Systems by Bengie · · Score: 1

      If you use a ZFS mount to mount a volume under a volume, and you snapshot the parent volume, you get the child volume snapshotted atomically. All datasets in ZFS share the same uberblock, so they can all be in perfect sync.

  5. It's a matter of distance by aglider · · Score: 2

    Not a matter of proof. The distance between perfect design and buggy implementation. IMHO.

    --
    Sent as ripples into the electromagnetic field. No single photon has been harmed in the process.
  6. Journaled File System? by marciot · · Score: 1

    i thought Journaled file systems already possessed this feature.

    1. Re:Journaled File System? by FranTaylor · · Score: 1

      i thought Journaled file systems already possessed this feature.

      just like air bags and seat belts have eliminated all deaths on the road

    2. Re:Journaled File System? by Darinbob · · Score: 1

      You need to ensure that blocks are written to the media in the correct order. Or at least that everying before a synchronization point was completely written to the media. But even that is not always true because devices will lie and claim to have flushed data when they have not. So you also need to ensure that your underlying block based device is operating correctly, and that can be tricky when it's a third party device.

  7. Is it really THAT hard? by ledow · · Score: 4, Interesting

    Write zero to a flag.
    Write data to temporary area.
    Calculate checksum and keep with temporary area.
    When write is complete, signal application.
    Copy data from temporary area when convenient.
    Check checksum from temporary to permanent is the same.
    Mark flag when finished.

    If you crash before you write the zero, you don't have anything to write anyway.
    If you crash mid-write, you've not signalled the application that you've done anything anyway. And you can checksum to see if you crashed JUST BEFORE the end, or half-way through.
    If you crash mid-copy, your next restart should spot the temporary area being full with a zero-flag (meaning you haven't properly written it yet). Resume from the copy stage. Checksum will double-check this for you.
    If you crash post-copy, pre-flagging, you end up doing the copy twice, big deal.
    If you crash post-flagging, your filesystem is consistent.

    I'm sure that things like error-handling are much more complex (what if you have space for the initial copy but not the full copy? What if the device goes read-only mid-way through?) but in terms of consistency is it really all that hard?

    The problem is that somewhere, somehow, applications are waiting for you to confirm the write, and you can either delay (which slows everything down), or lie (which breaks consistency). Past that, it doesn't really matter. And if you get cut-off before you can confirm the write, data will be lost EVEN ON A PERFECT FILESYSTEM. You might be filesystem-consistent, but it won't reflect everything that was written.

    Journalling doesn't need to be mathematically-proven, just logically thought through. But fast journalling filesystems are damn hard, as these guys have found out.

    1. Re:Is it really THAT hard? by Guspaz · · Score: 4, Insightful

      > When write is complete, signal application.

      How do you know the write was complete? Most storage hardware lies about completing the write. The ZFS folks found this out the hard way: their filesystem was supposed to survive arbitrary power failures, and on a limited set of hardware that was true. In reality, most drives/controllers say they've committed the write to disk when it's still in their cache.

      Any filesystem that claims to survive crashes needs to take into account that any write confirmation could be a lie, and that any data it has written in the past may still be in a volatile cache.

    2. Re:Is it really THAT hard? by fnj · · Score: 2

      You can't expect software to paper over BUSTED HARDWARE. If a disk drive flat out lies about status, expose the goddam manufacturer and sue him out of existence. If you think anyone can paper over the scenario you just outlined, then what about this - what about a disk drive that NEVER WRITES ANYTHING but lies and says everything is going hunky dory? Pretty damn sure there's nothing you can do in that scenario.

      I've heard that story about the "drives that lie about about write-to-physical-media-complete" many times. As far as I am concerned it is apocryphal. Never once have I seen the manufacturers and model numbers specified. I think it probably came from a long long time ago (in technology time). Finally I sure as hell have no idea how "examples exist" turned into "most storage hardware" as the tale is spun and respun over the years.

    3. Re:Is it really THAT hard? by ShooterNeo · · Score: 1

      I think you're basically right. I read about an even simpler system. They wanted to prove if a robotic surgical arm, controlled by a multi-axis joystick, would always no matter what move only when the surgeon commanded it.

      So basically, you read the joystick position sensor for an axis. You multiply by a coefficient, usually less than 1. You send that number to the arm controller. Arm controller tries to move to that position.

      Smooth, linear, no discontinuities...you technically only need to check about 3 states (the edges and the middle) for a linear system without discontinuities. If it works, you're done. (for each axis so if it's 3 axis that's 27 states to check)

      Somehow their system had bugs in it that they found with formal verification. Not sure how...

    4. Re:Is it really THAT hard? by operagost · · Score: 1

      The disk buffer is indeed a write cache, and modern disk driver software uses the ATA FLUSH CACHE or SAS/SCSI FUA commands to enforce physical writes.

      --

      Gamingmuseum.com: Give your 3D accelerator a rest.
    5. Re:Is it really THAT hard? by Guspaz · · Score: 1

      Then the MIT paper ignores reality, and is therefore useless.

      You can prove your system is technically correct all you want, but if it doesn't work in the real world (where most hardware lies about write commits), then it's going to work in theory and fail in practice.

    6. Re:Is it really THAT hard? by ledow · · Score: 1

      What on earth makes you think that any algorithm, proof or technique can account for hardware failure of any kind? That's what RAID, etc. are for and are still far from a guarantee.

      Plus, kind of the point of a checksum is to ensure the integrity (to a certain probability) of data. If either the checksum or data change, they will no longer match up - short of a billions-to-one random chance that you can't do anything about anyway. Incorporate the flag into the data that you checksum and that's covered.

      You cannot mathematically prove that any single bit will ever be written to disk whatsoever. All you can do is prove that you won't lose bits that you've confirmed as written **unless there is hardware failure**. That's it. Hell, we can't even prove that we're talking to a real device rather than an emulated one that just discards random bits.

  8. Not exactly new or news... by bradgoodman · · Score: 2

    No specifics. This has been done a million times with journaling filesystem (and block layers) - no idea why this is better or different. But what about disk failure? But what about data loss? But what about (undetected) data corruption (at the disk)? What about unexpected power hits that could drop a disk or tear a write? Not even going to get into snapshotting, disaster recovery, etc. There's a lot more to this than "surviving a crash".

    1. Re:Not exactly new or news... by FranTaylor · · Score: 1

      But what about disk failure?

      this is like expecting your seat belt to keep you safe during the apocalypse

    2. Re:Not exactly new or news... by FranTaylor · · Score: 1

      I'm wondering if their proof requires the disk to actually write the data in the same order as the filesystem sends write commands to the disk. This is not necessarily true for disks that support command queuing, and certainly not true for SSDs.

      RTFA:

      "You literally have to consider every instruction or every disk operation"

    3. Re:Not exactly new or news... by bradgoodman · · Score: 1

      No. It's not. You think [your favorite bank] puts all their financial data on a plain 'old off-the-shelf [Insert brand here] and assumes that it'll all be good? They use multi-million dollar systems which do mirroring, integrity checking, verification, etc. "High-end" storage and filesystems systems do things like verification and checking at multiple levels (end-to-end, drive, block, filesystem, array, etc) so a $100 disk drive doesn't corrupt data and take down a $100 billion dollar bank. As for the apocalypse scenario - yep - they need to account for that too. That's what "Disaster Recovery", snapshotting and [long distance] asynchronous replication are all about. Reality speaking - an errant nuke or natural disaster can't take down a $100b bank - it can't even loose track of a single [large] transaction.

    4. Re:Not exactly new or news... by Bengie · · Score: 1

      You need to read in-between the lines.

      "MIT's New File System Won't Lose Data During Crashes" can be read as "MIT's New File System Won't be at fault for lost data once committed during any interruption of writes"

      ZFS does the same thing, minus the proofs. If you do a sync write and ZFS says it completed, then that data is not going to be lost due to any fault of ZFS. But what if someone threw all of your harddrives into lava? Again, not the fault of ZFS. Same idea.

      Rule of thumb, if your FS needs FSCK, it can probably lose data given the right kind of interruption.

    5. Re:Not exactly new or news... by bradgoodman · · Score: 1

      That's not the point. Having a machine verifiable proof of a correct filesystem which would protect itself in a "crash", is still subject to problems beneath it, or problems other than "crashes". There are other filesystems that can do this (without the "machine verifiable proof" - and they are vulnerable in real-world scenarios- not because they "lack the proof" - but because there are a zillion other weak links in the chain).

  9. Re:Yeah rigth by wonkey_monkey · · Score: 1

    I don't believe this one bit.

    That's why we have checksums.

    --
    systemd is Roko's Basilisk.
  10. Tough environments by unencode200x · · Score: 1

    I've seen RAID groups fail sort of violently (granted in some tough environments) where one disk crashed and so did the others next two it. Three out of five disks in a RAID 5 gone. Only option was backup. How would any filesystem survive that?

    --

    Chance favors the prepared mind.
    Perfect is the enemy of good.
    1. Re:Tough environments by FranTaylor · · Score: 1

      the stars will implode and the universe will come to an end, how would any filesystem survive that?

    2. Re:Tough environments by unencode200x · · Score: 1

      Exactly! Seriously, I've seen this. Being in IT for almost 20 years you see edge cases, dumb things, and just plain bad luck.

      --

      Chance favors the prepared mind.
      Perfect is the enemy of good.
    3. Re:Tough environments by TheDarkMaster · · Score: 1

      I've seen RAID groups fail sort of violently (granted in some tough environments)

      Missile hit? :-D

      --
      Religion: The greatest weapon of mass destruction of all time
    4. Re:Tough environments by Guspaz · · Score: 1

      You joke, but I've seen IOPS drop in a RAID array because somebody was talking loudly next to the server. It was kind of fun to shout at the server and watch the disk activity drop. For testing purposes, of course.

    5. Re:Tough environments by fuzzyfuzzyfungus · · Score: 1

      It sounds like a quip; but it's the truth: more redundancy. Nothing is going to allow a system(whether it is all handled by the filesystem or the work is divided between a RAID controller and a filesystem) to recover a chunk of data that the universe violently removes except another copy of that data or something from which it can be deterministically inferred(even if you accept the 'random number generator and a lot of patience' mode of data recovery, you still need to know when you've recovered the correct data).

      If you have a full proof of the behavior of the system, you can at least know what sorts of failures, and where, will cause loss, and of what; but any real-world implementation is going to ultimately rest on a judgement about acceptable risk vs. acceptable cost of redundant hardware. Had the system in your post been running 5 disks in RAID1, it would have been totally fine with the loss of up to 4 disks; but not terribly efficient. Elegant math can make detecting errors more likely, allow for redundancy that is more efficient than naive copying, provide insight into what steps in the process are points of failure, how severe they are, and so on; but unless you have an ideal computer to run it on, it will be a matter of some degree of chance, though ideally a well understood degree knowingly chosen.

    6. Re:Tough environments by mlts · · Score: 3, Interesting

      I personally encountered a drive array driver cause an entire array to get overwritten by garbage. I was quite glad that I had tape backups of the computers and the shared array, so a recovery was fairly easy (especially with IBM sysback.)

      Filesystems are one piece of a puzzle, but an important one. If that array decided to just write some garbage in a few sectors, almost no filesystem would notice that, allowing propagating of corrupted data to backups. The only two that might notice it would be a background ZFS task doing a scrub and noticing a 64 bit checksum is off, or ReFS doing something similar. Without RAID-Z2, the damage can't be repaired... but it can be found and relevant people notified.

    7. Re:Tough environments by Bengie · · Score: 1

      Their term of "Crash" is different than yours. You assume "crash" means the Universe self-destructed. They just assume the writes were interrupted, like power failure or your kernel locked up, not your harddrives dying.

    8. Re:Tough environments by unencode200x · · Score: 1

      Nothing quite that interesting. One was in a school. Their server room was near the gym. The other was in a factory. The server room was in the middle of the shop.

      --

      Chance favors the prepared mind.
      Perfect is the enemy of good.
    9. Re:Tough environments by 0dugo0 · · Score: 1

      Ever had to deal with power losses and noticed how often power goes down a second time before really coming back up? Ever noticed how bad (journalling) filesystems deal with power failures during repair?

    10. Re:Tough environments by Zak3056 · · Score: 1

      I've seen RAID groups fail sort of violently (granted in some tough environments) where one disk crashed and so did the others next two it. Three out of five disks in a RAID 5 gone. Only option was backup. How would any filesystem survive that?

      It is not the responsibility of the file system to maintain data integrity in the face of catastrophic failure of the underlying storage hardware.

      --
      What part of "shall not be infringed" is so hard to understand?
    11. Re:Tough environments by Guspaz · · Score: 1

      Pretty much that. Ours were RAID arrays on Linux, and we induced it without being quite as close as he was, but pretty much the same deal. This was more than ten years ago, so maybe modern disks would handle it better, but it looks like a few years later that guy in your video was still seeing the same behaviour.

    12. Re:Tough environments by david_thornley · · Score: 1

      My wife once worked on a system that was in the next room from the skate sharpener. She'd never seen flames coming out of a hard disk before.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
    13. Re:Tough environments by unencode200x · · Score: 1

      Wow, that would be scary.

      I remember one time about 10 years ago we got a handful of new HP servers in and were going through the burn-in process. Quite literally, apparently, as one of them had a RAID controller who's capacitors exploded quite violently setting off fire alarms and making us run for fire extinguishers when when we fired it up. (pun intended..).

      --

      Chance favors the prepared mind.
      Perfect is the enemy of good.
    14. Re:Tough environments by unencode200x · · Score: 1

      Agreed. The article does talk about catastrophic hardware failures too. Just thought it seemed a bit misleading and scant on details is all.

      --

      Chance favors the prepared mind.
      Perfect is the enemy of good.
  11. Two General's Problem by Anonymous Coward · · Score: 1

    I think any file system could be imagined as a simple case of a database system. You "commit" a file change and you must be sure that the change is written to disk before proceeding.

    So, any database system has a well know logical limitation named "Two General's Problem"

        https://en.wikipedia.org/wiki/Two_Generals%27_Problem

    The implication of this is that in a database system you cannot guarantee a fully automated recovery; always there is a remaining possibility that some changes should be rolled back or commited by hand.
    So what the database manager does is to minimize this lost work; what do you want to redo by hand: 1 week, 1 day, 1 minute, 1 second of work?

    1. Re:Two General's Problem by Guspaz · · Score: 1

      You can never be sure that a write is committed to disk, because most hardware lies about that.

    2. Re:Two General's Problem by fnj · · Score: 1

      You can never be sure that a write is committed to disk, because most hardware lies about that.

      I suppose you can find authoritative references for that claim, complete with manufacturer names and drive model numbers?

  12. Code not available, will it ever be? by badger.foo · · Score: 2

    It's now August, the conference where they'll be presenting their work is in October, and the article is a tad short on specifics. They've done a formally verified formal verification of a filesystem. if it works, that's excellent news of course, but I'd wait until we have seen the thing work and with actual code to examine before making any comments or bets on how useful this is going to be. And this being an open source-oriented site, we should be asking whether the code will indeed be available under any kind of usable open source license.

    --
    -- That grumpy BSD guy - http://bsdly.blogspot.com/
  13. MIT researchers live in ivory towers by alexhs · · Score: 4, Insightful

    Beware of bugs in the above code; I have only proved it correct, not tried it. -- Donald Knuth

    If the hard drive firmware is not proven, this FS won't be any better than ZFS and others.
    Writing safe file systems is the easy part (even trivial using synchronous writes, when you consider their design is "slow").
    The impossible part is dealing with firmwares that are known to lie (including pretending than a write is synchronous): how could you not lose data if the drive didn't ever write the data to the platters in the first place ?

    --
    I have discovered a truly marvelous proof of killer sig, which this margin is too narrow to contain.
    1. Re:MIT researchers live in ivory towers by KingMotley · · Score: 1

      Not impossible. Tell it to write to disk, wait for it to say it has. Then cut power to the drive, wait 30 seconds, reestablish power, then ask for the data back. If it isn't the same, repeat until it is. It'll be slow, and likely kill your drives, but you can be reasonably sure the drive did indeed write the data.

  14. Real-time by tepples · · Score: 1

    what does this phrase even mean? why does speed or slowness matter?

    Speed means the ability to finish reading and writing all data associated with a job before the job's soft real-time deadline has expired.

    1. Re:Real-time by tepples · · Score: 1

      If reading or writing files in a particular file system is slow enough that it makes applications painful to use, the file system won't pass into widespread use.

    2. Re:Real-time by Darinbob · · Score: 1

      And yet the FAT16 file system was popular for a very long time.

  15. ZFS? Hello?!? by Anonymous Coward · · Score: 1

    I guess that in the MIT village, the villagers have not yet discovered that something like that exists and is being used in production for the past ten years, and is known as "ZFS".

    Good job guys... Glad to know why you are counted among the elite computer science institutions... *FACEPALM*

  16. chmod 751 some_directory by tepples · · Score: 4, Informative

    The feature I miss the most is allowing traversal through a directory hierarchy a user has no explicit permissions for to get to a folder they do have permissions for. I find the workarounds for this in other filesystems to be extremely ugly.

    In POSIX, that's represented in a directory's mode bits with octal digit 1 (4: list files, 2: create or delete files, 1: traverse). What do you find ugly about mode 751 (owner create or delete, owner and group list, world traverse)?

    I also kind of wish TCP/IP had used the network:mac numbering scheme that IPX used.

    It does now. An IPv6 address is divided into a 48- or 56-bit network, a 16- or 8-bit subnet, and a 64-bit machine identifier commonly derived from the MAC.

    1. Re:chmod 751 some_directory by Actually,+I+do+RTFA · · Score: 1

      Well, for example, I can think of a situation for: create, NOT delete, NOT modifiy, NOT read. If there is a shared area where people are putting resumes, or other submissions. You don't want htem to affect or compete with one already there. Nor read the others.

      I can see a log file you can append-only to.

      There's a lot of interesting cases if the permissions are cut fine enough.

      --
      Your ad here. Ask me how!
  17. Now get rid of "save file" at user level. by Impy+the+Impiuos+Imp · · Score: 1

    Stupidly written programs will still have problems, even if there is no corruption at the filesystem level -- a partially written save state, written in two parts with file closure (or to two separate files, more likely), will be corrupt from the program's point of view, if the computer resets between the two writes.

    This also suggests a need for a transaction-like system at the OS level -- you open and write a ton of data, and then the crash occurs when almost done. The OS must have been writing to a temp file rather than the "real" one. Unless that is too high level in this context -- the article has no technical details at all.

    --
    (-1: Post disagrees with my already-settled worldview) is not a valid mod option.
  18. This is standard for mission-critical S/W by sirwired · · Score: 1

    The idea of evaluating each step of the program for "what happens if this fails" is standard software engineering technique for mission-critical software. (That't not to say it's always actually done, just that it is the standard.) This method is hardly revolutionary (or even evolutionary.)

    1. Re:This is standard for mission-critical S/W by FranTaylor · · Score: 1

      slashdot has truly degenerated into a cesspool when you consider that this drivel is one of the more insightful posts

    2. Re:This is standard for mission-critical S/W by sirwired · · Score: 1

      The standard doesn't have a name; it's not some useless crap in an ISO catalog, it's just a way truly mission-critical software is built.

      I know that NASA has used it for the flight-control computers for the manned space-flight program, and IBM uses it for some of the more vital parts of their mainframe operating systems.

      I didn't say it was applicable to everything, just that as a software-engineering technique, it's not at all new.

  19. Re:Proving Coq itself by TheRaven64 · · Score: 4, Interesting

    If you actually want an answer, I suggest that you go and read the Coq papers. You might learn something.

    --
    I am TheRaven on Soylent News
  20. Re:Yeah rigth by wonkey_monkey · · Score: 1

    checksums will only detect a single bit error

    Nope.

    --
    systemd is Roko's Basilisk.
  21. What's their point? by allo · · Score: 1

    Any journalling FS should provide a consistent state, checksumming FS like BTRFS or ZFS even provable.
    So they won't lose data, which is written and in a consistent state, and unwritten data cannot be saved by definition.

  22. Yeah, right. by dargaud · · Score: 4, Interesting
    In the words of Knuth the Great: "Beware of bugs in the above code; I have only proved it correct, not tried it."

    It reminds me of a story from the late 80s (?) at a tech conference. The makers of a real-time OS with real-time snapshots would periodically pull the plug on their systems, plug it back in and it would resume exactly what it was doing, to the delight and amazement of all the techies in the assistance. In the much larger and much more expensive booth in front of them was a richer vendor. The techies started coaxing them to do the same. After much hand wringing, they did, and after a very long rebuild time the system came back as a mess. Conclusion: the 1st vendor went out of business, the 2nd one is still very big.

    --
    Non-Linux Penguins ?
    1. Re:Yeah, right. by LWATCDR · · Score: 1

      That is often true.
      x86 vs the 68k, MS-DOS vs Amiga, MS-DOS vs GEMTOS. and so on.
      marketing often beats better tech.

      --
      See my blog http://ilovecookes.blogspot.com/ for light hearted technical information.
  23. If it was easy wouldn't it already be done? by sjbe · · Score: 2

    Why am I hearing Jeremy Clarkson asking "how hard can it be?" just before utterly screwing something up?

    Perhaps there is just a tad more difficulty to it than you are considering?

    1. Re:If it was easy wouldn't it already be done? by operagost · · Score: 1

      Mental image of Clarkson rolling that Reliant Robin... OHHH THERE GOES MY DATA!

      --

      Gamingmuseum.com: Give your 3D accelerator a rest.
    2. Re:If it was easy wouldn't it already be done? by Darinbob · · Score: 1

      I can never tell if Clarkson is a smart person pretending to be stupid, or a stupid person pretending to be smart. Because a stupid person could never pretend to be that stupid.

  24. Formal proofs of software are useless by jgotts · · Score: 1

    Hi, MIT guys, formal proofs of filesystems are useless because you cannot incorporate physical systems into formal proofs. Real filesystems exist on real hardware.

    I guarantee that your file system will fail if I start ripping cables out. A suitably strong EMP will take it out. In fact, I bet I could nuke your filesystem if I used my ham radio transceiver too close to the device. Other things that would destroy your filesystem include floods, earthquakes, and a lightning strike.

    I began writing this by stating that formal proofs of software are useless, but I don't really believe that to be true. I strongly believe that we should strive for software correctness. Any techniques that can we use to make software better are worth pursuing.

    But it has to be remembered that software cannot be isolated. When we do develop a true AI, it will escape and destroy us, probably within milliseconds of an unexpected hardware event. No matter how rigorously the beast is programmed!

  25. Re: Yeah rigth by BronsCon · · Score: 1

    Some checkums can only be guaranteed to catch a single bit error but, in practice, it is relatively rare that multiple-bit errors "line up" just right to create a correct checksum. There are better checksums available, as well, which will catch multiple-bit errors, as well as identify which segment of the data contains the error. Someone more familiar with the topic will have to name these, as I haven't studied them in years.

    --
    APK quotes people (including myself) without context and should not be trusted. Just thought you should know.
  26. Re:Yeah rigth by WaffleMonster · · Score: 1

    That's why we have checksums.

    There is no guarantee checksums will detect failure there is only a probability.

  27. Re:Define "crash". by Nerrd · · Score: 1

    rtfa - this is clearly a discussion about software and/or power failure, not hardware.

  28. Re:Yeah rigth by wonkey_monkey · · Score: 1

    There is no guarantee that a Slashdot reader will detect a joke; there is only a probability.

    Did anyone get it?

    --
    systemd is Roko's Basilisk.
  29. Key Logic's KeyKOS by Sits · · Score: 2

    I've just spent the past few minutes trying to (re)find this story. Is it the KeyKOS recovery speed story from 1990?

    1. Re:Key Logic's KeyKOS by dargaud · · Score: 1

      Yes, that's the story, thank you.

      --
      Non-Linux Penguins ?
  30. Re:Define "crash". by ChumpusRex2003 · · Score: 3, Insightful

    However, considering how many firmware bugs there are in modern SSDs and HDs which cause out-of-order writes, shorn writes, and various other random corruptions and bad behaviour during a power failure or system reset, what would be more interesting is how the file system could cope with one of those.

  31. Re:Define "crash". by gweihir · · Score: 2

    As the Linux FS developers found some time ago, many modern disks also blatantly lie about having flushed data to disk. With software, you can then only do heuristic things to reduce the impact, not more. This "magic" MIT FS cannot do any better, and hence is entirely superfluous.

    --
    Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
  32. Re:Define "crash". by Darinbob · · Score: 1

    That's a snag I've found in the past. So much hardware is consumer grade so that the datasheets are rubbish. You think that your write has succeeded but it's still got data stuck in the cache, and the "flush, dammit" command is actually a no-op. So a never-fails file system I used in the past was getting corrupted, and the developers of it were baffled because they never saw a failure like that before.

    So let's say your super reliable file system is mathematically proven, but the axioms are false, what then? Consider a flash drive. Inside it has all of its own logic; when to copy from RAM into the actual flash chips, when to copy and erase sectors behind the scenes invisibly to the user, and so forth. There's a lot of state machine activity going on that the mathematically proven file system knows nothing about. If the synchronize-cache command doesn't quite do what expected then things can break. Write operations can happen out of order also (the real reason for synchronize-cache, which is why you should specify the entire device and not just the most recent block). What if power is killed in the middle of an internal copy-erase-compact cycle, which leaves you at the mercy of whoever designed your device?

  33. Re:Define "crash". by Darinbob · · Score: 3, Insightful

    Many consumer devices generally conform to an unwritten standard, not a written one. That unwritten standard is "do whatever is needed to make it work on Windows". This means that mandatory commands might not be fully tested, or sometimes not even implemented. And because these are consumer devices, the manufacturers generally aren't concerned about rare end-user problems, since whoever bought the flash thumb drive on sale isn't going to complain, and the margins are way too small to waste time on reliability. All that matters is getting it to work for most people most of the time.

  34. Re:Define "crash". by gweihir · · Score: 1

    I completely agree.

    --
    Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
  35. Re:Define "crash". by arglebargle_xiv · · Score: 1

    Beware of bugs in the above code; I have only proved it correct, not tried it.

    -- Donald Knuth.

    This new filesystem sounds like another case of this...

  36. Re:Proving Coq itself by arglebargle_xiv · · Score: 1

    How do you prove Coq is correct

    You use the formal proof assistant Pusi to prove it correct. So what you do is feed Coq into Pusi, and then nine months later the proof drops out.

  37. Re:Define "crash". by doccus · · Score: 1

    Same as if power is killed in any initial write. I can't accept any drive can be psychic and know what's not yet written I suppose heuristics could fill in some missing data but it surely can't complete all the data that never even hit the cache. I'm no programmer or expert so perhaps I'm missing something here...

  38. He is smart but plays dumb by sjbe · · Score: 1

    I can never tell if Clarkson is a smart person pretending to be stupid, or a stupid person pretending to be smart.

    I've heard from numerous movie directors that people who play dumb characters actually have to be quite smart. Clarkson isn't stupid (generally) and remember that Top Gear is/was a scripted show and people watch it primarily because it is funny. I think I remember Conan OBrian saying that a lot of comedy is throwing out your dignity and hoping you'll get it back.

  39. Hardware Reliability by herbierobinson · · Score: 1

    As others have pointed out, the formal verification does make the software provably reliable, but does nothing to protect against hardware issues. Just as a datapoint, the Stratus VOS operating system has been checksumming at the block driver level since the OS was written in 1980. It has detected failures on every generation of hardware it has been used with since. Some of the failures we have seen: Undetected transient media errors (the error correction/checking isn't perfect); Flaky I/O busses; bugs in RAID firmware.

    These real world failures will swamp the potential failures caused by the software not being verified.

    --
    An engineer who ran for Congress. http://herbrobinson.us