Live data from Hacker News

Hyperspace

hypercritical.co

321–330 of 503 posts

Re: Hyperspace

#321
What jumped out to me:

> Finally, at WWDC 2017, Apple announced Apple File System (APFS) for macOS (after secretly test-converting everyone’s iPhones to APFS and then reverting them back to HFS+ as part of an earlier iOS 10.x update in one of the most audacious technological gambits in history).

How can you revert a FS change like that if it goes south? You'd certainly exercise the code well but also it seems like you wouldn't be able to back out of it if something was wrong.

Re: Hyperspace

#322

I have file A that's in two places and I run this. I modify A_0. Does this modify A_1 as well or just kind of reify the new state of A_0 while leaving A_1 untouched?

It's called copy-on-write because when you modify A_0, it'll make a copy of the file if you write to it but not A_1. https://en.wikipedia.org/wiki/Copy-on-write#In_computer_stor...

Thanks for the clarification. I expected it worked like that but couldn't find it spelled out after a brief perusal of the docs.

Re: Hyperspace

#323
post #252

Earlier quoted context omitted.

> I tried to scan System and Library but it refused to do so because of permission issues. macOS has a sealed volume which is why you're seeing permission errors. https://support.apple.com/guide/security/signed-system-volum...

For some reason "disk-inventory-x" will scan those folders. I used that amazing tool to prune left over Unreal Engine files and docker caches when they put them not in my home folder. The tool asks for a ton of permissions when you run it in order to do the scan though, which is a bit annoying.

It’s not obvious but the system folder is on a separate, secure volume; the Finder does some trickery to make the system volume and the data volume appear as one.

In general, you don’t want to mess with that.

Re: Hyperspace

#324

Earlier quoted context omitted.

No because it isn't getting rid of the duplicate, it's using a feature of APFS that allows for duplicates to exist separately but share the same internal data.

Is it not the same as a hard link (which I believe are supported on Mac too)?

It’s not the same because clones can have separate meta data; in addition, if a cloned file changes, it stores a diff of the changes from the original.

Re: Hyperspace

#325

Downloaded. Ran it. Tells me "900" files can be cleaned. No summary, no list. But I was at least asked to buy the app. Why would I buy the app if I have no idea if it'll help?

[deleted]

Re: Hyperspace

#326

What jumped out to me: > Finally, at WWDC 2017, Apple announced Apple File System (APFS) for macOS (after secretly test-converting everyone’s iPhones to APFS and then reverting them back to HFS+ as part of an earlier iOS 10.x update in one of the most audacious technological gambits in history). How can you revert a FS change like that if it goes south? You'd certainly exercise the code well but also it seems like yo…

IIRC migrating from HFS+ to APFS can be done without touching any of the data blocks and a parallel set of APFS metadata blocks and superblocks are written to disk. In the test migrations Apple did the entire migration including generating APFS superblocks but held short of committing the change that would permanently replace the HFS+ superblocks with APFS ones. To roll back they “just” needed to clean up all the generated APFS superblocks and metadata blocks.

Re: Hyperspace

#327

> Hyperspace can’t be installed on “Macintosh HD” because macOS version 15 or later is required. macOS 15 was released in September 2024, this feels far too soon to deprecate older versions.

Came here to post the same thing. Would love to try the application, but I guess not if the developer is deliberately excluding my device (which cannot run the bleeding edge OS).

In fairness, I don't think you can describe it as bleeding edge when we're 5 months into the annual 12 month upgrade cycle. It's recent, but not exactly an early adapter version at this point.

Re: Hyperspace

#328

Requires macOS 15.0 or later. – Oh god, this is so stupid and most irritating thing about macOS "Application development". It is really unfair to call it "software" it is more like "glued to recent version of OS ware", meanwhile I can still run .exe compiled in 2006, and with wine even on mac or linux.

However, you can't run an app targeted for Windows 11 on Windows XP. How unfair is that? Curse you, Microsoft.

Re: Hyperspace

#329
post #326

What jumped out to me: > Finally, at WWDC 2017, Apple announced Apple File System (APFS) for macOS (after secretly test-converting everyone’s iPhones to APFS and then reverting them back to HFS+ as part of an earlier iOS 10.x update in one of the most audacious technological gambits in history). How can you revert a FS change like that if it goes south? You'd certainly exercise the code well but also it seems like yo…

IIRC migrating from HFS+ to APFS can be done without touching any of the data blocks and a parallel set of APFS metadata blocks and superblocks are written to disk. In the test migrations Apple did the entire migration including generating APFS superblocks but held short of committing the change that would permanently replace the HFS+ superblocks with APFS ones. To roll back they “just” needed to clean up all the gen…

I think that’s what they did too. And it was a genius way of testing. They did it more than once too I think.

Run the real thing, throw away the results, report all problems back to the mothership so you have a high chance of catching them all even on their multi-hundred million device fleet.

Re: Hyperspace

#330
post #326

What jumped out to me: > Finally, at WWDC 2017, Apple announced Apple File System (APFS) for macOS (after secretly test-converting everyone’s iPhones to APFS and then reverting them back to HFS+ as part of an earlier iOS 10.x update in one of the most audacious technological gambits in history). How can you revert a FS change like that if it goes south? You'd certainly exercise the code well but also it seems like yo…

IIRC migrating from HFS+ to APFS can be done without touching any of the data blocks and a parallel set of APFS metadata blocks and superblocks are written to disk. In the test migrations Apple did the entire migration including generating APFS superblocks but held short of committing the change that would permanently replace the HFS+ superblocks with APFS ones. To roll back they “just” needed to clean up all the gen…

Yes, that's how it's described in this talk transcript:

https://asciiwwdc.com/2017/sessions/715

Let’s say for simplification we have three metadata regions that report all the entirety of what the file system might be tracking, things like file names, time stamps, where the blocks actually live on disk, and that we also have two regions labeled file data, and if you recall during the conversion process the goal is to only replace the metadata and not touch the file data.

We want that to stay exactly where it is as if nothing had happened to it.

So the first thing that we’re going to do is identify exactly where the metadata is, and as we’re walking through it we’ll start writing it into the free space of the HFS+ volume.

And what this gives us is crash protection and the ability to recover in the event that conversion doesn’t actually succeed.

Now the metadata is identified.

We’ll then start to write it out to disk, and at this point, if we were doing a dry-run conversion, we’d end here.

If we’re completing the process, we will write the new superblock on top of the old one, and now we have an APFS volume.

Post reply on HN