175 points · by ivank · 8y ago · 319 comments
Sorry for harsh language, but this is not a bug. This is a complete brain damage of those who decide to implement such behaviour.
I have redirected Documents. And there are A LOT of programs that directly try to use C:\Users\user\Documents instead of redirected.
That's not "harsh", harsh is what happened to the unlucky users who lost data because no one on the development team bothered to call it out. It should be an implicitly understood rule that you NEVER remove a file you did not create, unless the user explicitly asked to, but I guess MS considers it acceptable to do anything to a user's system after they convinced everyone to take forced updates as being acceptable too.
This. Once you get in the mindset that you know better than the user, it's not a big jump to "I know these directories should be empty, any content is leftover garbage, let's remove them".
Absolutely this, with a followup of "and if you're 'helpfully' deleting an unused folder, check that it's unused first!"
Given that this was (stupid) desired behavior, making sure Documents didn't have stuff in it should have been a screamingly obvious step. It would still have been utterly unacceptable, it could still have created weird downstream bugs when users installed things that target the now-missing default Documents location, but at least it wouldn't have set a bunch of data on fire without any warning.
But then, I guess relying on common sense after the first terrible decision is made is never going to work. There's a reason "never break user space" is rule 1 for Linux updates...
Well, this is the kind of thing that happens when your whole team is interns and the "senior" is 28.
Reading the associated bugs on github I also learned that there were lots of complaints about the new console, not on features, but breaking compatibility that is. Guess no one thought to start a new project, rather than changing a 30 year-old one that hadn't been touched in 20.
TL;DR: At least one codger is needed on teams doing this kind of work to give perspective.
To be fair, that's what led to Powershell and Command Prompt co-existing. I guess Microsoft wanted to reduce the number of console backends.
Seems like common sense, but Microsoft has been doing this for a while. In Windows 7 (not sure about later releases) the OS runs a 'Desktop Cleanup' periodically that deletes shortcuts to network locations it can no longer connect to. God forbid your network drives don't map one day and Windows decides to nuke all your desktop shortcuts... this actually happened to a user I was doing support for and they were understandably livid
Windows is going into the Apple direction I guess.
That, and I'm just a bit shocked that "the folder should be empty, so delete it" didn't just naturally make people think "obviously I should check if that's true first". Even if it's not a total fix, the failure to add that is it's own layer of screwup.
[1] - http://schinagl.priv.at/nt/hardlinkshellext/hardlinkshellext...
I'd love to read what Linus Torvalds would say about it.
There are programs that have bugs before the first line of code is written. This is one such case.
You could literally remove my entire root directory and at worst you've minorly inconvenienced me: I now have to boot from a USB drive and run `zfs rollback` to the most recent snapshot. I'd be impervious to most ransomware as well: my home directory is filled w/ garbage now? Good thing it can't encrypt my read only snapshots, even with root access. Oh and I can serialize those snapshots across the network at the block level before I nuke the infected machine.
Of course humanity will always invent a bigger idiot, so it's possible a virus could gain root & exec some dangerous ZFS commands, or it's possible some MSFT employee could pass the `-r` flag and recursively delete a dataset & its snapshots in their post-update script. Plus let's not forget that no filesystem in the world will stop you from just zero-filling the drive. Still it's easy for me to imagine a world where I'm completely impervious from ransomware: by way of only being able to delete critical snapshots when a hardware key is present or when my TPM is unlocked.
On the whole it seems to me CoW filesystems are a major step forward in safe-guarding users from accidental deletions. At a minimum they have other benefits (serialized incremental send streams, block level compression & dedup, etc.) that make backups easier to manage. -- Yet I still can't boot from ReFS on Windows.
I cannot stress enough: NTFS is not a CoW filesystem, any attempt to add CoW features on top of it will be poorly performant and doomed to fail, because they actually have to copy the old data blocks when you overwrite something. ZFS, btrfs, et al. are not actually copying user-data, because they don't have a concept of "ovewriting a block," every block that is written is written to unallocated regions of the disk; blocks that are not referenced by a dataset or snapshot are then returned to the allocator for later use; at no point is the old data "copied", it's just "not returned to the allocator for reuse."
What btrfs or ZFS mean by "copying" is not the user's data blocks, it's copying filesystem metadata, portions of btrfs' extent tree, or ZFS' block pointer tree. There is a world of difference between volume shadow copy, and an actual CoW filesystem. -- Microsoft knows this, that's why they are working on ReFS. (Of course in typical MSFT fashion they've made a number of critical mistakes: user data checksums are optional, and volume management is not integrated so it can't even use those integrity streams to self-heal corruption. Also last I checked ReFS can't even be used as a bootable Windows volume. -- It's worth pointing out APFS also made the mistake of checksumming metadata but not user data; which in my opinion makes both of them unsuitable as next generation filesystems.)
Unless you just so happen to be writing over an entire block, then there still must be a copy happening. The old data, less the bytes you modified, must be written into the new block along with your changed bytes.
It's not perfect, but it works, the major downsides are:
- Granularity is at the volume level, so you get a lot more block churn in your snapshots. I mitigate this by trying to separate the "OS" volume and "Data" volume to the extent Windows will let me.
- If you're doing any heavy lifting on top of the ZVOL that expects sync writes (e.g: MS SQL) its performance will degrade slightly. Anecdotally I find this to be negligible on my all-flash pool. Besides they sell SQL Server for Linux now ;-).
- NTFS is unaware of the snapshots, so your snapshots will be of a dirty state if the guest is running. AFAIK there's nothing like `xfs_freeze/unfreeze` that can be done in the guest to make these snapshots atomic. That being said NTFS' chkdsk is quite mature, and I've never observed this to be an issue in practice.
As far as I know Ubuntu ships with ZFS kernel module.
Unfortunately, as you undoubtedly know, ZFS support on Linux will always be a problem due to licensing.
As far as I know native encryption is not yet stable in ZFS.
Sure, and the first thing every WIN virus does is deletes the shadow copies.
What's really cool about serialized snapshots is that once native encryption support lands in ZFSonLinux you'll be able to send encrypted volumes over the wire. The data blocks don't have to be decrypted to be serialized or checked for integrity, so you don't even need the decryption key to do incremental sends! You can send your backups to an untrusted remote pool that never has to have knowledge of the decryption key!
(You can also serialize snapshots to files, which is useful for say writing them to detachable media to sneakernet them. If you want to do incremental sends though the receiver does have to be an actual zpool.)
Some other helpful hints would be using something like `mbuffer`[2] on the sender & receiver. This is handy for spinning rust pools, so that your disks don't have to wait on the network before seeking to the next blocks to be sent.
Also ZFS lets you delegate permissions so you can manage filesystems as normal users, I'd recommend doing this so you don't have to login as root on the remote pool to receive the snapshots.[3] In my case I ran into this early on because I have `PermitRootLogin no` on all my boxes.
[1]: https://pthree.org/2012/04/17/install-zfs-on-debian-gnulinux... [2]: https://dan.langille.org/2014/05/03/zfs-send-on-freebsd-over... [3]: https://dan.langille.org/2015/02/16/zfs-send-zfs-receive-as-...
Besides, msft makes money by selling SaaS. There's no financial incentive to protecting consumer data since the EULA indemnifies the company for any damages caused by their products.
A whole bunch of applications do the bad thing Microsoft is talking about, and hardcode the path to 'My Documents'. I have a ghost 'My Documents' folder that has mostly app settings and maybe some save files.
The entire Users directory ends up being such an unimaginable cesspool on a Windows machine that has seen any significant service time, with this, that, and everything else poking and prodding and leaving its detritus inside. My desktop is essentially a single-user machine, as most Windows laptops and desktops are, but even on servers where user accounts are actually used, I spend an undue amount of time fiddlefrigging to take ownership and permissions on files because some script I need is saved to a different account's desktop. Bailing out of the whole thing and running your own filesystem shouldn't be easier, but it is.
I held off updating because I didn’t want Windows wiping out all my game saves for example.
https://mobile.twitter.com/WithinRafael/status/1048473218917...
[1] - https://www.linkedin.com/pulse/20140806183208-12100070-why-d...
[2] - https://www.computerworld.com/article/2878026/microsoft-to-b...
[3] - https://arstechnica.com/information-technology/2014/08/how-m...
But I might just be projecting.
And I'm certain that I've personally encountered instances where both Documents folders had the Documents special folder icon (though I'm not sure if I've seen this on Win10, specifically)
This is just a project management failure that somehow got through, but the fact that it did seems to show major QA issues.
If you could lock down the whole directory tree and then check, it would be moderately safer but you are still assuming the tree contains only what you expect. It’s far wiser to have a list from the start or a file search that you can audit before individually processing files on your list.
Anybody got a suggestion for an OS I can use that exists on hard media, doesn't use kernel or base OS code that's been distributed digitally and has optional completely non-destructive updates via hard media no more than once a year, so that I'm not feeling like I'm trying to hit a moving target with the stuff I want to use, and it either works or not until a year later?
I actually used it as a desktop OS in the early 00s, it was a very relaxing experience. It was years behind FreeBSD (which was years behind Linux, which was years behind Windows...) in terms of device drivers, but it was incredibly stable, minimal, beautifully documented and well-organized OS that was a joy to work with.
As an example of what "stable" means here: OpenBSD has a port collection, but it's an implementation detail that you're not supposed to use. Instead, when a release is created, all ports are built and tested to guarantee that they work. Then, they're not updated. Ever. You're supposed to upgrade to the next release yourself, and if you don't, all the packages available to you right now will be available and working the same way 20 years from now.
(Of course, there is a -current version you can use to get more liberal update policy.)
I don't remember all the details, but it sounds like it would fit your requirements very well.
These physical devices are "mounted" into a single logical filesystem hierarchy, starting at /, with user data in /home/<username>/ (vs. C:\Users\<username>\). Various disks (and partitions) can be mounted basically anywhere in the filesystem, under any name you choose. You can mount your floppy as /A, your CD as /D and your other disk as /G and the OS won't complain at all. Traditional location for that is /mnt (ie. /mnt/G), but it's just a convention you don't have to follow.
You can learn about all the other places in the filesystem, basically what goes where, in `man hier`[1] It's like reading about the internal organization of C:\Windows, though, and can be ignored for the most part: normally, you stick to your home directory for everything and can organize it any way you like. Some desktop environments will create (and display in a special way) a more traditional set of folders, Documents, Downloads, Music and so on, but they will all be inside your home directory. You can mount your other drive (or a part of it) as your Music folder if you want, too.
As a side note, I'm not sure I would call Windows naming convention logical. It's just what you're used to. A single filesystem for everything vs. a separate filesystem for every disk/media is really a minor difference, just like the different path separator (\ vs. /) is irritating for the first week and then you stop thinking about it.
A warning, though. OpenBSD is not a desktop-oriented or newbie friendly OS. It's meant for servers and power users. There's very little hand-holding - even the installer has no GUI at all, not even console-based, it's just a command line where you type responses to printed questions. The primary interface to everything is the command line. The OS is focused on security and stability, not convenience. That being said, the system is incredibly well-documented and discoverable, and the community is very nice and welcoming, so it's not hopeless; just be aware that you're going to struggle for quite a number of hours before you make it work exactly the way you want it. The upside is that when you finally make it, it will stay that way. Forever.
(Systemd mounted an EFI partition read/write, and nuking / also nuked critical firmware information)
Some cursory googling reveals some other issues, but everything I can find is either very old (ex. https://lkml.org/lkml/2012/10/23/690) or reference utilities that an average user won't have (ex. https://www.spinics.net/lists/linux-bcache/msg05290.html)
That said, given that Microsoft charges money for this, goes out of their way to render themselves not liable when their code breaks your shit, and doesn't test a use case that's not exactly uncommon, it's still unforgivable and not comparable to Linux.
There is also this[0] short blog post on FS reliability on Linux where they analyze the source code for cases where error codes are dropped (code like "if(err) { /* ignore */ }" counting as handled error here) and there was some significant amount of problems across all FS in the kernel.
Though, I don't think the other OS' out there are much better, FS are hard. Getting them right is harder. Getting them right while being compatible with existing implementations is very harder.
You opened command terminal. You entered user mode using sudo. You entered command manually instead of using a user-friendly file manager, e.g. Midnight Commander. You disabled user-friendly interactive mode for rm. Literally, you said "system, delete everything and don't ask any questions". Yeah, sometimes sheet happens. I did that too once on production server with about a hundred of web-servers because I hit enter in the middle of the command. But I never blame system for my errors. Now I write tested scripts to make changes, use RPM to deliver updates, and use file manager to manage files manually. Learn from your mistakes. It's price for performance. For example, I needed to erase my partition recently. Using Linux, I erased it in less that minute.
Use Linux or buy a Mac. Microsoft always is and always will be horrible to end-users. They maybe cool in the enterprise sphere, and when it comes to open-source, and when it comes to developer tools and languages (I use lots of MS stuff... but run then on a Linux system!), but they don't care about regular end users since most of them "can't cast a vote" in deciding the system they use and where money goes to.
Frankly, I can't understand why - having a dominant position on the market - they seem to do everything to drive people away from their platform. It's not like we're in the 90s and there is no other choice.
Nowadays with the exception of a travel netbook, I mostly run Windows or Android on my computers.
Because GNU/Linux never managed to get their act together what means to have a full stack experience for UI/UX focused developers, specially on laptops.
And I just won't pay the Apple prices for less hardware than I can get with a Thinkpad/Dell/Asus workstation laptop, usually about 500 euros cheaper.
I mean MacOS requires a relatively expansive machine to run it, and many business-critical software either doesn’t run on Macs, or has drastically reduced functionality.
Linux isn’t even worth bothering with if one isn’t technical.
So really, we are left with Windows.
If you're not technical, just go with Mint. Looks like Windows 7, behaves like Windows 7, doesn't break. You don't have to leave GUI environments once, neither in installation nor in usage. Doesn't break. Gives you the opportunity to optimize your workflow if you want to.
No version of Linux "behaves like Windows 7". At best, it's like Linux wearing a bedsheet-ghost costume labelled "Windows 7" and screaming BOO! at you every time you do anything from a DOS/Windows background.
Yes, there are solutions for these problems but you need to be technical for them.
I've had Ubuntu running on a few cheap desktop machines for some years now used for light duties in a few living spaces. So far we're at 100% failure rate on version upgrades: Both LTR release upgrades have bricked both the machines.
When they switched the window manager on one of the recent ones, the UI simply died and the simplest resolution was to just re-install the OS from scratch.
Steady state, with apps installed and running and only doing basic patching via the GUI, Ubuntu is 'operable' by avg. Joe. But app installs and beyond are fraught with problems.
On Microsoft side, as soon as they announced Windows 10 would be rolling release OS (i.e. a perpetual beta one) I knew I was done with it on bare metal.
Some examples - corporate users (nobody big seriously considers Linux for desktops for various reasons, Apple would be easily 3-5x that expensive for no good enough added value), gaming (again some good options, but subpar to windows on probably every aspect).
Everybody knows Windows, everybody can somehow get by with just clicking around. If I've put Linux on my fiancee's notebook (she is a doctor), I would have to do 24x7 support for it, forever. No, thank you.
Well that's straight up not true, in fact IBM has over 100,000 Macs in the field and they estimate it's saving them $535 per machine over four years.
https://www.computerworld.com/article/3131906/apple-mac/ibm-...
What does Apple have that's cheaper? To save 535$ they would have to pay us to take them.
Topic might be different for high-end notebooks, especially with some sweet corporate deals. That's NOT the bulk of computers used for office work around the world. Cherry-picking some specific relatively marginal scenario doesn't affect the big numbers.
At best, it is redundant with a recursive search feature that chooses “delete” as the operation. And if you want “do something else then delete”, you can no longer call a recursive-delete command anyway so why not just learn how to enumerate files first and give your system a fighting chance to audit first?
Disk cleanup code should always create lists of known target files, attempt to delete only that list of files, then do the platform equivalent of “rmdir” at the end to attempt to remove the directory. If that fails, congratulations: your ass was saved by not deleting something you didn’t know was there.
That was the first thing I thought of when I heard the news about the bug --- the infamous creepy message just got an even scarier meaning.
https://www.reddit.com/r/windows/comments/3x88yj/all_your_fi...
I really wonder what goes on at MS to have consensus to think such messages were ever a good idea. Even if the message is true, it scares the users because it's like ransomware. If it isn't, that's even worse because you're now lying to your users. In any case, they arouse suspicion and fear.
In the XP days, I believe updates would, after restarting, at most show a dialog with a more informative message ("Installing updates...") and a progress bar, and more importantly, your wallpaper and desktop would continue loading in the background --- the latter really helps with the unease, if not the annoyance. The full-screen, vague, and unnecessary messages just invoke feelings of horror.
Even so that gives a ton of hardware choice and flexibility, and will give you more options to protect and control the systems beyond the OS themselves which is very important if you want to run something older since security patches will stop. But if you're judicious about what you use for what tasks and how you handle I/O it offers another option, and can make hardware changes a lot easier as well by abstracting away the metal somewhat. Basically a lot of the advantages that make virtualization so popular in general for business can be just as applicable at home these days, most of us have cycles and memory to spare and can afford to burn a bit of it on making a more pleasant software experience or working around issues coming from a higher level. In this case for example you could be running your Windows VM on virtual disks on a NAS/DAS or even the same system but supporting better snapshotting, and if the data was deleted simply roll back the entire VM to pre-upgrade state.
Also I doubt OEMs are allowed to sell Windows 7 any more (though I don’t know for sure).
Disclosure: Microsoft employee
Yeah right, I'm sure that will be fruitful.
Elections have consequences, even if they singing are on issues most voters aren't considering.
Just yesterday I saw that my brother's Win10 desktop was magically empty after he'd rebooted due to windows update. After hunting around for solutions, (none of which worked), I noticed that all the missing desktop files were magically in the recycle bin.
Nice work M$.
From memory, the update was #1803, so not sure if this is relevant to the arctechnica article... but since it was yesterday, it's clearly not 100% accurate.
(PS: No, my brother didn't cause them to be put there)
By default the recycle bin has a limit of how much files it can store, and if you try to put more in there it will be deleted. It'll ask when you do the operation, but it if was done automatically as part of the update, who knows. A safety net with such big holes never made sense to me so that's why I always change the limit to 100% of the disk size. Your brother was lucky to recover his files.
...and this is why I never trust automatic updates. Hard to tell what caused something if the system is silently changing under you.
"Compounding this issue is that Microsoft's rollout of version 1809 was already unusual. For reasons unknown, Microsoft didn't release this update to the Release Preview ring, so the most realistic installation scenario—someone going from version 1803 to 1809—didn't receive much testing anyway. And all this is against the longer-term concern that Microsoft laid off many dedicated testers without really replacing the testing that those testers were doing."
And from this article:
"In response the company has promised to update the Feedback Hub tool so that the severity of bugs can be indicated. Many people reported this data loss bug, but none of the reports received many upvotes, with Microsoft accordingly disregarding those bugs. If the bugs had been marked as causing data loss—the highest severity possible—then they may have received the additional attention that they deserved. Microsoft hasn't, however, explained why this update didn't receive any kind of "release preview" distribution or testing. There are no guarantees that this would have caught the bug, but it would have meant that an extra round of people would have installed the update onto their systems, and who knows, one of their bug reports might have gotten lucky."
Windows 10 is literally death by a thousand paper cuts for me.
* explorer, and even in general file operations are dead slow for some reason. an expand of a zip from explorer with a couple of 10s of thousands of files can take an hour, while in WSL takes maybe a minute. explorer also takes its sweet time to load, including in open dialogs. This being on a near top-of-the-line 480s with 24GB Ram and 1TB SSD.
* windows don't remember their previous position on multi-screens.
* copying in terminal sometimes seems to work, sometimes not.
* terminal beeps at you on every tab with more than one option, always have to keep sound muted.
* bluetooth menu is glitchy and there's no standard quick way to connect to a previous device.
* no idea whether that's win10, spotify or thinkpad software, but hitting a media key produces a NON DISMISSIBLE big overlay for spotify that just hangs there for a good 10 seconds and blocks the stuff I want to click.
* solution for a full taskbar? just make it scroll with very small scroll buttons...
* some older Logitech mouse I connect has buggy assignment of forward/back keys - does a completely random operation instead. Windows doesn't seem to have a GUI-way to set this stuff up
* terminal has no tabs and crappy colors and I don't wanna go down the rabbit hole of trying to integrate WSL with a non-default terminal emulator. I've installed the spring update, won't touch october one for a while at least.
* there's no integration of WSL & windows GUI layer. Have to start an X-Server separately and have Linux GUI-tools instead. If I seriously need that I will simply switch to a Linux distro instead (which given the above I start to suspect I should have done from the beginning).
Windows has annoyances, but Linux is like building a car in a garage full of car parts. Yes, you can build a working car, but you better be a mechanic.
> * windows don't remember their previous position on multi-screens.
Not an OS concern. Most applications do remember, by the way.
> * terminal beeps at you on every tab with more than one option, always have to keep sound muted.
Windows terminal doesn’t have a bell. WSL does, as does macOS or anything Linux/UNIX really. You can disable it of course. Google "wsl disable bell".
Either way, nothing new or objectively bad.
> * no idea whether that's win10, spotify or thinkpad software, but hitting a media key produces a NON DISMISSIBLE big overlay for spotify that just hangs there for a good 10 seconds and blocks the stuff I want to click.
That’s mostly Spotify. It can be disabled in settings. Windows only shows the volume "slider", which is gone after 5 seconds
* some older Logitech mouse I connect has buggy assignment of forward/back keys - does a completely random operation instead. Windows doesn't seem to have a GUI-way to set this stuff up
Nothing is "random". Except perhaps when the device is broken. Mouse buttons 1-5 have been well-defined for 10+ years now.
> * terminal has no tabs and crappy colors and I don't wanna go down the rabbit hole of trying to integrate WSL with a non-default terminal emulator. I've installed the spring update, won't touch october one for a while at least.
Yes, it sucks. You can either enable SSH and SSH into WSL or just use wsltty (which offers bell options!).
> * there's no integration of WSL & windows GUI layer.
That’s a given. WSL is only for developers.
Is Spotify, go to settings, display options and deselect "Show desktop overlay when using media keys". For some time I had to do that after every Spotify update, but seems to stick now
I like Windows 10 and generally have been happy with it -- but that particular behavior has been driving me nuts for a while. They really need to fix it.
(Or you can't have them at all without an extension, yeah, that too...)
Windows has progressed by leaps and bounds since 2003. Linux, not so much. We have this fixation on building something, then deciding it's full of legacy code that doesn't allow us to build what we really want, so we throw it out and do it all over again.
The good news is that we've been on the "building" side of this pattern for a while. The bad news is that we've been on the "building" side of this pattern for a while so I expect there's not much time left until the next "revolution"...
Don't underestimate Microsoft's willingness to keep their system as a minimum that gets enhanced by third parties.
You open whatever terminal you want and run the WSL command, by the way. So just 'wsl' or 'bash' or 'ubuntu', etc.
There's not actually a rabbit hole. You don't need to change the default launcher.
Okay, the tabs thing we haven't been able to fix yet, but if you want to change the console colors real quick, you can use ColorTool:
https://github.com/Microsoft/console/tree/master/tools/Color...
Also, it you want a tab-like experience, you could always try tmux. It's a linux commandline tool that gives you tabs, panes, and all sorts of other goodies, and as of 1809 you can even use cmd.exe within it.
I assumed they pushed it to market before it was ready, allowing users to find the bugs to save on testing costs (helping justify why it was free). Only, now, years later, the start menu still lags, and things still open behind other things.
Combined with all the mysterious data it sends to various IP's, I think that when you press Start, those first 300 ms are spent as part of some sort of distributed computing effort.
You’ll find the slow file operations are entirely down to NTFS. Regardless of how you play around in fsutil it’s hopeless on lots of small files. This incidentally makes WSL unbearably slow. Hence why I still use VirtualBox and putty.
If you can get your hands on Windows Thin PC (Cut down Windows 7) you can eek out the support until November 2021.
Thinks work, OS doesn't get in my way anyhow, its fast and takes relatively little RAM (well not compared to XP but these days its OK).
Never tried Win10 because everything seemed worse, but I had hope they would polish things over the years. When I read comments here, it doesn't seem so. Sad story...
> The current OneDrive client will set up KFR and then move any files from their original location to the new OneDrive location. Older versions of the OneDrive client, however, would set up KFR but leave existing files in the old location. The October 2018 Update would then destroy those files.
Microsoft's own software which they bundled with Windows 10 and nagged Windows 10 users to set up and use triggered a data loss bug which caused Windows 10 to delete those users' documents - all because Microsoft didn't think it through, didn't test properly, and didn't take any notice of data loss reports from external beta testers.
WSL would be nice, but it's better all in all to just spin up a ubuntu vm in hyperv.
I can't believe I can say that.