<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Filesystem on Melabit</title>
    <link>https://melabit.com/en/tags/filesystem/</link>
    <description>Recent content in Filesystem on Melabit</description>
    <generator>Hugo</generator>
    <language>en</language>
    <lastBuildDate>Mon, 08 Jun 2026 06:00:00 +0000</lastBuildDate>
    <atom:link href="https://melabit.com/en/tags/filesystem/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>From HFS&#43; to APFS</title>
      <link>https://melabit.com/en/2026/06/08/from-hfsplus-to-apfs/</link>
      <pubDate>Mon, 08 Jun 2026 06:00:00 +0000</pubDate>
      <guid>https://melabit.com/en/2026/06/08/from-hfsplus-to-apfs/</guid>
      <description>&lt;p&gt;For years I have had two external drives always connected to my home Mac Mini M1.&lt;sup id=&#34;fnref:1&#34;&gt;&lt;a href=&#34;#fn:1&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;1&lt;/a&gt;&lt;/sup&gt; The first is a 2 TB external SSD containing all my work and personal documents, the code for the scripts and applications I develop, documentation, and so on.&lt;/p&gt;&#xA;&lt;p&gt;A second mechanical drive keeps all my photos and music, as well as a large software library, mainly for macOS and Linux, which I started archiving more than twenty years ago, when you couldn&amp;rsquo;t find everything online, and which I still keep updating today.&lt;/p&gt;&#xA;&lt;p&gt;This setup is necessary because the internal 1 TB drive is too small for my needs. But it also proves very useful every time I move to a new Mac: once macOS is configured and the essential applications are installed, I just need to connect the two external drives to be ready to work.&lt;/p&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://melabit.com/img/2026-06-08-da-hfsplus-a-apfs/william-warby-ykyUSsbDviA-unsplash.jpg&#34; alt=&#34;&#34;&gt;&#xA;&amp;ndash; &lt;em&gt;Source: &lt;a href=&#34;https://unsplash.com/@wwarby&#34;&gt;William Warby&lt;/a&gt; on &lt;a href=&#34;https://unsplash.com&#34;&gt;Unsplash&lt;/a&gt;&lt;/em&gt;.&lt;/p&gt;&#xA;&lt;p&gt;In terms of speed I don&amp;rsquo;t notice any significant difference between the internal drive and the external SSD. This is partly because the tasks I usually carry out, mainly writing and developing software, are not affected by the read or write speed of the drive. Even the media files on the mechanical drive aren&amp;rsquo;t an issue; when using Photos and Music I can surely afford to lose a few extra seconds.&lt;/p&gt;&#xA;&lt;p&gt;Until macOS Monterey, displaying the contents of external drives was always almost instantaneous, even when dealing with folders containing thousands and thousands of files.&lt;/p&gt;&#xA;&lt;p&gt;With Sonoma, suddenly everything changed. Every time I opened a folder containing a large number of files or subfolders, I had to &lt;a href=&#34;https://melabit.com/en/2024/05/31/apple-we-have-a-problem-a-look-at-macos-sonoma-bugs-update/&#34;&gt;wait several tens of seconds&lt;/a&gt; before being able to see the contents. Sequoia &lt;a href=&#34;https://www.melabit.com/en/2025/02/04/apple-we-fixed-some-issues-from-sonoma-to-sequoia/&#34;&gt;improved this behaviour sligthly&lt;/a&gt;, but only temporarily, as its latest releases have made opening folders on external drives as slow as before.&lt;/p&gt;&#xA;&lt;p&gt;This slowness is not due to a hardware problem; the same drive connected to a Mac running Monterey displays files almost instantly. The problem lies in the software, or more precisely in how macOS manages the two main filesystems of the Mac world, HFS+ and APFS.&lt;/p&gt;&#xA;&lt;h4 id=&#34;apfs&#34;&gt;APFS&lt;/h4&gt;&#xA;&lt;p&gt;In 2017, after nearly twenty years of &lt;a href=&#34;https://eclecticlight.co/2025/04/12/a-brief-history-of-mac-native-file-systems/&#34;&gt;HFS+&lt;/a&gt;, Apple introduced a new filesystem optimised for solid-state storage devices, unimaginatively named &lt;a href=&#34;https://eclecticlight.co/2017/01/27/apple-file-system-what-it-means-what-it-brings/&#34;&gt;Apple File System&lt;/a&gt; (APFS).&lt;/p&gt;&#xA;&lt;p&gt;Up until Monterey the two filesystems coexisted peacefully: &lt;a href=&#34;https://eclecticlight.co/2022/05/16/should-you-continue-using-hfs/&#34;&gt;APFS had become mandatory&lt;/a&gt; for the system drive (that is, the one from which the Mac boots and which contains the operating system and applications), but nothing prevented you from continuing to use HFS+ for external drives, which in this way remained readable on older Macs and, with some effort, on &lt;a href=&#34;https://www.phoronix.com/news/Apple-HFS-2025-Linux-Maintain&#34;&gt;Linux&lt;/a&gt; and &lt;a href=&#34;https://www.paragon-software.com/home/hfs-windows/&#34;&gt;Windows&lt;/a&gt; as well.&lt;/p&gt;&#xA;&lt;p&gt;Starting with Sonoma (perhaps even from Ventura, which I always avoided using), access to the contents of folders on HFS+ drives became extremely slow. I don&amp;rsquo;t think Apple did this intentionally, perhaps to force users to switch to APFS. It is more likely that it was a simple bug that has never been fixed because Apple is no longer interested in supporting HFS+. In fact, the slowdown only affects the &lt;em&gt;display&lt;/em&gt; of files in Finder, while opening or saving them is not affected.&lt;sup id=&#34;fnref:2&#34;&gt;&lt;a href=&#34;#fn:2&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;2&lt;/a&gt;&lt;/sup&gt;&lt;/p&gt;&#xA;&lt;p&gt;Due to laziness, I tolerated these slowdowns for two years. In the meantime, I replaced the 2 TB mechanical external drive with an NVMe SSD,&lt;sup id=&#34;fnref:3&#34;&gt;&lt;a href=&#34;#fn:3&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;3&lt;/a&gt;&lt;/sup&gt; but the speed at which folders opened improved much less than I would have expected.&lt;/p&gt;&#xA;&lt;p&gt;So, a few days ago, I decided to take the plunge and convert both my external drives to APFS.&lt;/p&gt;&#xA;&lt;h4 id=&#34;from-hfs-to-apfs&#34;&gt;From HFS+ to APFS&lt;/h4&gt;&#xA;&lt;p&gt;With &lt;code&gt;Disk Utility&lt;/code&gt;, switching from HFS+ to APFS is very straightforward: just right-click on the drive you want to modify and select &lt;code&gt;Convert to APFS...&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;img src=&#34;https://melabit.com/img/2026-06-08-da-hfsplus-a-apfs/convert-to-apfs.png&#34; alt=&#34;&#34;&gt;&lt;p&gt;Before starting, it is useful to select the &lt;code&gt;Show All Devices&lt;/code&gt; item from the &lt;code&gt;View&lt;/code&gt; menu (or by clicking the &lt;a href=&#34;https://melabit.com/img/2026-06-08-da-hfsplus-a-apfs/show-all-devices-toolbar.png&#34;&gt;&lt;code&gt;View&lt;/code&gt; icon&lt;/a&gt; in the Disk Utility toolbar), so you can see how the structure of the drive changes as you switch from HFS+ to APFS.&lt;/p&gt;&#xA;&lt;img src=&#34;https://melabit.com/img/2026-06-08-da-hfsplus-a-apfs/show-all-devices.png&#34; alt=&#34;&#34;&gt;&lt;p&gt;In theory, the conversion process should not damage the files on the drive. However, it is better not to take risks and make a backup first. I write this from experience, as you will read shortly.&lt;/p&gt;&#xA;&lt;p&gt;I had no problems with the first drive, the 2 TB SSD, perhaps because it was relatively empty with only 500 GB of the total 2 TB used. Converting from HFS+ to APFS took only a handful of seconds, after which the drive finally became fast and responsive, as expected of an SSD.&lt;/p&gt;&#xA;&lt;h4 id=&#34;you-can-read-but-not-write&#34;&gt;You can read but not write&lt;/h4&gt;&#xA;&lt;p&gt;The conversion of the mechanical drive was an entirely different matter. This drive, unlike the previous one, has only 500 GB free out of 2,000 total. But 500 GB is still a quarter of the total capacity and so, after the positive experience I had just had, I decided to start without making a backup, as the files it contained could always be restored from Time Machine.&lt;/p&gt;&#xA;&lt;p&gt;When it went to convert the drive to APFS, Disk Utility started grinding away for quite a while; maybe it was only a minute or two, but a minute can feel like an eternity when you&amp;rsquo;re doing something like this. After that, Disk Utility stopped and warned me that the conversion process had failed.&lt;/p&gt;&#xA;&lt;p&gt;Luckily, despite the error, the drive continued to work as usual. For that, I would like to thank the Apple developers, who did an excellent job of ensuring that the file system conversion &amp;ndash; an extremely delicate process that modifies the underlying structure of the drive &amp;ndash; could fail without damaging the files stored on it.&lt;/p&gt;&#xA;&lt;p&gt;Needless to say, I tried again with the same result.&lt;/p&gt;&#xA;&lt;p&gt;ABefore trying again, I decided it would be wiser to make a backup of everything onto another external hard drive first. This took the whole night, but it was better not to take too many risks.&lt;/p&gt;&#xA;&lt;p&gt;It must have been a premonition, because on the third attempt Disk Utility gave up and reported an error &lt;code&gt;-69860&lt;/code&gt;, &amp;ldquo;The underlying task reported failure on exit&amp;rdquo;, which was so vague as to be meaningless. However the consequence was clear: that the drive had become &lt;code&gt;read-only&lt;/code&gt;. I could read all the files without any issue, but I could no longer write a single bit.&lt;/p&gt;&#xA;&lt;p&gt;Since I had a fresh backup on hand, I didn’t panic too much. Using Disk Utility, I erased the entire drive, this time choosing APFS as the filesystem. To do this, simply select the drive and then click the &lt;code&gt;Erase&lt;/code&gt; button in the Disk Utility toolbar.&lt;/p&gt;&#xA;&lt;h4 id=&#34;restoring-the-files&#34;&gt;Restoring the files&lt;/h4&gt;&#xA;&lt;p&gt;The next step was to restore the files from the backup. First, I tried using the Finder to manually drag each folder from the backup drive to the newly reformatted APFS drive.&lt;/p&gt;&#xA;&lt;p&gt;There were no problems with folders containing relatively few files, but when it came to a much larger one, the Finder eventually gave up, claiming that the drive already contained a file with the same name. The file obviously wasn&amp;rsquo;t there because I was rebuilding the drive from scratch, but I didn&amp;rsquo;t want to waste any more time investigating, only to end up with the same error an hour later.&lt;/p&gt;&#xA;&lt;p&gt;So, I opened the good old Terminal, moved with &lt;code&gt;cd&lt;/code&gt; into the root folder of the drive to be restored (which I&amp;rsquo;ll call &lt;code&gt;Media HD&lt;/code&gt; here),&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;% cd &amp;#34;/Volumes/Media HD&amp;#34;&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;and copied the folders one by one from the backup drive (&lt;code&gt;Backup HD&lt;/code&gt;) to the destination drive. Before doing all this I reformatted again &lt;code&gt;Media HD&lt;/code&gt; to start from a &lt;em&gt;clean&lt;/em&gt; state.&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;% cp -p -R &amp;#34;/Volumes/Backup HD/&amp;lt;directory A&amp;gt;&amp;#34; .&#xA;% cp -p -R &amp;#34;/Volumes/Backup HD/&amp;lt;directory B&amp;gt;&amp;#34; .&#xA;...&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Here, &lt;code&gt;&amp;lt;directory A&amp;gt;&lt;/code&gt;, &lt;code&gt;&amp;lt;directory B&amp;gt;&lt;/code&gt; (without the trailing &lt;code&gt;/&lt;/code&gt;) and so on refer to the names of the folders (or &lt;em&gt;directories&lt;/em&gt;) to be copied. The &lt;code&gt;-p&lt;/code&gt; option specifies that the copy should not modify the file attributes,&lt;sup id=&#34;fnref:4&#34;&gt;&lt;a href=&#34;#fn:4&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;4&lt;/a&gt;&lt;/sup&gt; while &lt;code&gt;-R&lt;/code&gt; means that all files and folders being restored should be copied recursively. Please note that the &lt;code&gt;.&lt;/code&gt; at the end of each command is mandatory, as it specifies that the files must be copied into the current folder of the destination drive.&lt;/p&gt;&#xA;&lt;p&gt;The great thing about using Terminal is that once you have started the copy process, you can set it aside and let it work while you do other things. Just make sure you don&amp;rsquo;t close Terminal or touch the backup or destination drives.&lt;/p&gt;&#xA;&lt;p&gt;The downside is that you have no idea what is happening or how many files have been already copied. Using the &lt;code&gt;-v&lt;/code&gt; option is out of the question, because it would cause &lt;code&gt;cp&lt;/code&gt; to print the name and path of every copied file, slowing down the whole operation.&lt;/p&gt;&#xA;&lt;p&gt;It is much better to open a second Terminal tab and navigate to the root folder of the drive being restored (if it doesn&amp;rsquo;t already appear automatically) with&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;% cd &amp;#34;/Volumes/Media HD&amp;#34;&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;and then run the command&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;% du -h -d 1 &amp;#34;/Volumes/Media\ HD/&amp;lt;directory A&amp;gt;&amp;#34;&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;which returns the list of folders contained in &lt;code&gt;&amp;lt;directory A&amp;gt;&lt;/code&gt;, together with their respective sizes. The total size occupied by &lt;code&gt;&amp;lt;directory A&amp;gt;&lt;/code&gt; is shown at the end. By comparing this with the size of the folder on the backup drive it is easy to get an idea of how much is left to copy.&lt;/p&gt;&#xA;&lt;p&gt;One word of warning: when &lt;code&gt;cp&lt;/code&gt; is busy copying a large file, &lt;code&gt;du&lt;/code&gt; can be very slow to respond. Be patient and don&amp;rsquo;t worry, these are Unix tools, reliable stuff that crashes pnly when you hit them with a hammer!&lt;/p&gt;&#xA;&lt;h4 id=&#34;even-the-terminal-can-act-up&#34;&gt;Even the Terminal can act up&lt;/h4&gt;&#xA;&lt;p&gt;Although the Terminal is usually more reliable than the graphical interface, there are rare cases where it can cause problems.&lt;/p&gt;&#xA;&lt;p&gt;It happened to me with a folder of about ten gigabytes, containing an enormous number of very small files arranged in deeply nested folders, which has always been difficult to transfer from one drive to another. Usually, the best thing to do is to compress the folder from the Terminal,&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;% tar -czf large_folder_with_many_files.tar.gz &amp;#34;Volumes/Media HD/Large folder with many files&amp;#34;&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;transfer it to the other drive and then expand again it with&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;% tar -xzf large_folder_with_many_files.tar.gz&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I&amp;rsquo;ve done it many times before and it has always worked. This time, however, it didn&amp;rsquo;t. When I tried to decompress the file, a &amp;ldquo;Special header too large error&amp;rdquo; appeared, which could be related to some weird modification to the folder or its files that occurred while I was trying to convert the drive to APFS.&lt;/p&gt;&#xA;&lt;p&gt;The problem here was that I could have all the backups in the world, but if I couldn&amp;rsquo;t decompress the file, I would have ended up restoring the folder from Time Machine, which would have taken an inordinate number of hours.&lt;/p&gt;&#xA;&lt;p&gt;Luckily, on my Mac I always have a few utilities that I might rarely use, but that turn out to be essential when I need them. That’s the case with &lt;a href=&#34;https://apps.apple.com/it/app/the-unarchiver/id425424353&#34;&gt;The Unarchiver&lt;/a&gt; by MacPaw, which is available on the App Store. Don’t ask me how or why, but The Unarchiver managed to unpack the &lt;code&gt;tar.gz&lt;/code&gt; file without a hitch, and it did so very quickly, too, perhaps even faster than the usual &lt;code&gt;tar&lt;/code&gt; command in the Terminal.&lt;/p&gt;&#xA;&lt;h4 id=&#34;conclusions&#34;&gt;Conclusions&lt;/h4&gt;&#xA;&lt;p&gt;In the end, everything worked out fine, and I managed to convert my two external drives from HFS+ to APFS without losing a single bit of data and in less time than I would have expected.&lt;/p&gt;&#xA;&lt;p&gt;Access to the drives is now lightning-fast again, just as it was in Monterey and earlier versions of macOS. I still don&amp;rsquo;t understand what happened &lt;em&gt;inside macOS&lt;/em&gt; to make drives formatted with HFS+ so inefficient. I don&amp;rsquo;t think Apple did it on purpose to push users towards the new filesystem. It is far more likely to be a bug that Apple is no longer interested in fixing.&lt;/p&gt;&#xA;&lt;p&gt;While my personal experience of converting from HFS+ to APFS is statistically insignificant, I believe it is reasonable to conclude that the conversion process should not cause any problems provided the disk is relatively empty (i.e. up to 50% full). I haven&amp;rsquo;t been gazing into a crystal ball; the reason is simply that, under these conditions, macOS should have ample space to create the data structures of the new file system without touching the existing ones.&lt;/p&gt;&#xA;&lt;p&gt;Above that threshold the conversion might work or, as happened to me, it might throw errors. In that case it is better to play it safe and make a preventive backup rather than risk losing your documents or getting stuck in arcane repair processes that you never know how (or when) will end.&lt;/p&gt;&#xA;&lt;p&gt;Many users love to live on the edge and consider backups to be a waste of time. However, backups are never a waste of time, they are insurance for your data. And, unlike regular insurance policies, they are free or almost so.&lt;/p&gt;&#xA;&lt;p&gt;In any case, never panic if something unexpected happens. It’s better to take a break, think it over, and look up information online, because reacting (badly) on instinct can do more damage than has already been done.&lt;/p&gt;&#xA;&lt;div class=&#34;footnotes&#34; role=&#34;doc-endnotes&#34;&gt;&#xA;&lt;hr&gt;&#xA;&lt;ol&gt;&#xA;&lt;li id=&#34;fn:1&#34;&gt;&#xA;&lt;p&gt;There is also a third drive dedicated exclusively to Time Machine. But that drive is indispensable and doesn&amp;rsquo;t count.&amp;#160;&lt;a href=&#34;#fnref:1&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li id=&#34;fn:2&#34;&gt;&#xA;&lt;p&gt;If you want to force someone to do something, it is better to do it properly, isn&amp;rsquo;t it?&amp;#160;&lt;a href=&#34;#fnref:2&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li id=&#34;fn:3&#34;&gt;&#xA;&lt;p&gt;I was lucky to choose the right moment. Today, the same drive would cost more than twice as much, and it might not even be easy to find.&amp;#160;&lt;a href=&#34;#fnref:3&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li id=&#34;fn:4&#34;&gt;&#xA;&lt;p&gt;File attributes are the metadata associated with a file that define its behaviour and access modes. These include the file&amp;rsquo;s creation and modification dates, read and write permissions, file ownership, and so on.&amp;#160;&lt;a href=&#34;#fnref:4&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;/div&gt;&#xA;</description>
    </item>
  </channel>
</rss>
