Hacker News new | ask | show | jobs
by hn8305823 868 days ago
I've only ever lost data on Linux ext* filesystems, never on FreeBSD UFS or ZFS.

20 years ago it was unfortunately not unusual to experience the Linux "nuclear fsck" where it scrolls by so fast and for so long you know it's toast.

2 comments

I've 100% had issues with UFS, it's a simple filesystem and subsceptible to corruption. ZFS meanwhile is a different beast altogether which is designed to ensure data integrity at all costs.
UFS without soft updates is easily susceptible to corruption.

The "soft updates" option must be chosen when the disk is formatted for good reliability.

As I have said, 20 years ago "soft updates" in UFS worked better than journaling in the other contemporaneous file systems.

Nowadays it is likely that this is no longer true. I am still using FreeBSD in servers, but unlike 20 years ago I can afford UPSes so I no longer see often crashes due to power outages, even if I had one incident some time ago with a battery that had not been replaced yet after the UPS had warned that this is necessary, and when a power outage happened, the UPS worked for less than a minute and the power was cut before system shutdown. Even in this case there was no file system corruption on UFS.

Even with this good recent experience, today I would no longer trust UFS like 20 years ago, because it is said the current FreeBSD maintainers no longer understand the convoluted code that implements "soft updates" in UFS, and in any case most of their file system maintenance and development work is directed at ZFS now.

A journal(-like) mechanism was added to soft-upates by McKusick in the 2010 timeframe:

* https://www.youtube.com/watch?v=_NuhRkiInvA (BSDCan)

* https://www.mckusick.com/softdep/suj.pdf

Which also allows snapshots:

* https://freebsdfoundation.org/project/snapshots-on-filesyste...

See also "Journaling versus Soft Updates: Asynchronous Meta-data Protection in File Systems":

* https://www.seltzer.com/assets/publications/Journaling-versu...

OpenBSD recently decided to turn OFF soft update, by default.

https://undeadly.org/cgi?action=article;sid=20230706044554

Although, according to the link, not because there's anything wrong with it, but because other changes they want to make to the filesystem code would risk breaking soft updates.
FTA:

Log message: Make softdep mounts a no-op

Softdep is a significant impediment to progressing in the vfs layer so we plan to get it out of the way. It is too clever for us to continue maintaining as it is.

UFS on FreeBSD is still maintained bz Kirk McKusick, the inventor of soft updates. It's the other BSDs that have trouble as they can't rely on Kirk's expertise.
ZFS had its own data corruption bug some months ago. TBH, this was a big minus. You really don't expect such things from a filesystem which is in production for years and whos aim is data integrity. Now, to its defence, it is only used by FreeBSD and some nishe linux distributions, so it does not get much testing.
Well maybe you missed the news about the bug in EXT4 ... https://news.ycombinator.com/item?id=38585189
Hell no. I worked in an ISP in late 90s. NTFS was absolutely rock reliable, then (much worse)ext2, then (slightly worse) UFS, and then FAT.
20 years ago is 2004, not the 90s. I don't know, but it's certainly possible that one of them was in the lead in 1995, a different one in 2005, and a different one in 2015. This is especially plausible because Linux was only created in the mid 90s, so those first few years seem likely to have been disproportionately rough.
NTFS might have been rock reliable in Windows NT and perhaps also in Windows 2000.

When Windows XP has been launched, NTFS was certainly much less reliable. Even without being affected by any crashes or other anomalies, the free space on the NTFS partitions of early Windows XP computers would shrink steadily, without any apparent cause, requiring a reformatting/reinstallation after some time.

Early Windows XP was very buggy. While a computer with Windows XP did not require one or more reboots per day like one with Windows 98, failing to reboot it for more than a few days guaranteed a crash.

Only after installing several massive service packs in the following years, Windows XP has become reasonably stable.

I live in a developing country. We have constant power blackouts, like every day. Anything not journalling cannot survive that yteatment. Even crappiest XP was better than UFS which absolutely sucked in that respect.
For me, in the 90s ext2 was much, much reliable than ntfs. After a power failure ext2 will just run fsck and fix the filesystem while ntfs will sometimes give up.
I don't know if it was a file system related thing but you could bet on the Windows registry being borked beyond repair after just a handful of unexpected power cycles.
No. We had a NT4 server, handful FreeBSDs and one Linux. After several blackouts FreeBSD would lose file or two. NT4 workstation had no problems either, neither with registry nor FS.
> ISP in late 90s. NTFS was absolutely rock reliable, then

Well, i stayed away from NTFS in the Win2000 era because crashes would make your system unusable.

In 90s it was NT4. Excellent OS.
Windows 2000 was stable as a rock, NTFS included. Never had an issue with it.

Windows XP was more stable than 98SE, but it did crash more, because it was a general purpose OS used by people playing games. Still can't recall any major NTFS issues with it.

Windows 2000 with XP drivers (edit the INI file to allow it to install) was the way to go ;)