Laggy, frozen, slow Mojave: 100% consistent methods to reproduce, discussion of possible cause, and proposed user workarounds

This is a followup to my post from 6 Oct 2018 here:


Frequent system hangs and freezes in macOS Mojave 10.14: Notes, reproducible errors, and possible workarounds


The full description of symptoms is there, including attempted fixes and workarounds. Briefly, if you're reading this, it's because your Mojave install keeps freezing all the time, and you've come here to find out why, and what you can do about it.


Here's what I've discovered, and some ways you might work around it. Tl;dr: Leave your system plugged in and powered on to your user desktop for a weekend.


Seriously.


Reproducing the error


In bugfixing, consistency is important. Reliably reproducing an error is a major step in finding the cause, and addressing it. I've been able to reliably and consistently bog, then freeze, my Mac by two separate user-initiated methods:


1. Attempt to copy a corrupted file. The copy op lags, then halts, while the Mac slows, then freezes. Eventually, Finder throws a (-36) error, and normal system operation resumes, after a delay.


2. Attempt to compress a corrupted file, using the "Compress" command from the popup menu (right/ctrl-click the file). Compression begins, but at some point in the process, it lags and halts, while the Mac slows, then freezes. In this case, for me, I get no error message; simply an empty and nondismissable window where once there was a progress bar:


User uploaded file


Oops.


Activity Monitor never indicates there is a runaway process. The only evidence the user has of any problem is the increasing lack of system responsiveness, culminating by a freeze in all UI elements, which eventually clears after the copy/zip operation aborts.


Likely cause of the laggy/slow/frozen Mojave error


I believe Mojave, when it begins copying a file, does what you'd expect it to do: It reads data, then writes it. However, some files may be fragmented, some substantially so; chasing down those fragments takes a while.


I think while it's copying, Mojave may be attempting to defrag the source file at the same time. In some cases, this could result in system lagginess.


In some cases, the file may actually be damaged. So Mojave begins looking for the missing pieces, and may be looking all over the source volume to find them. Eventually, it's scanned everywhere it can look, is unable to locate the missing pieces, and returns a (-36) error.


During the time it's conducting its search of the hard drive for the file data, the file I/O process is seizing processor and disk-read/write resources, effectively freezing the rest of the system until it surrenders control of the hardware.


If this is a low-level file I/O issue, it would manifest on both SSD and rotational (hard) disk drives. It would take longer to clear or resolve on HDD's, but it would definitely happen on everything, regardless of the underlying disk drive hardware.


And particularly if you have a lot of files, the freeze is likely to go on longer, and take more time to unfreeze, because that file I/O process is searching everywhere there's data for those missing pieces.


And because this is very probably a macOS Mojave error, it doesn't matter if your machine is only a few months old, or if you've had it for years. All it takes is some fragmented or corrupted files, and particularly on older legacy installs, you bet you have a few of both on your drive.


If my surmise is correct, this will happen even on SSD based machines that are upgrading from High Sierra (they had APFS before Mojave; APFS only came to fusion and rotational drives with 14.0), because it's a fault in Mojave's file I/O, not one found in High Sierra.


What does this have to do with me? I'm not copying files. I'm just trying to use my Mac!


You wouldn't think reading a web page or replying to an email would be enough to kill your entire computer for minutes at a time, and you're right; it's not.


But in the background, Spotlight is indexing and rebuilding its database, which is a normal function after a new system install.


Also in the background, macOS is defragmenting files.


And particularly after a new install, there's a lot of file moving and cleanup going on.


These processes are all attempting to read and write data from files, and are very probably using exactly the same subprocess as copying files, or compressing them.


Which would mean macOS is doing the same thing, trying to defrag or repair files on the fly, in the background, while you're reading a website or replying to an email. And suddenly, bam, your system is frozen for no good reason you can see.


Great. So what can I do about it?


Not a heck of a lot. There are two things you can do that might help.


1. Turn off Spotlight indexing for your entire disk. This will substantially reduce the amount of file read/write happening in the background. To do that:


a. Select the Spotlight pane in System Preferences.

b. Click the "Privacy" tab.

c. Add your hard drive there, either by dragging/dropping it, or clicking the "+" button and selecting it from the file window. Add the entire drive. By default it's named "Macintosh HD", but it'll be something else, if you've subsequently renamed it.


Spotlight will warn you that "some" search functions won't work. Sigh, and click OK. That's true; a lot of search functions won't work, if Spotlight is not indexing your drive. Stay with me, though, because you don't necessarily have to keep it turned off until the 14.1 update.


2. After you've logged in to your desktop, disable all sleep functions (Energy Saver settings that shut off the disk after a while, or sleep the system, etc), leave your Mac logged in and powered up, and plug it in if it's a portable.


Then walk away from it for a day or two.


This isn't an ideal suggestion if it's your only computer, I know.


What this should do is let Mojave resolve its issues on its own. You won't notice lags or hangs if you're not paying attention to the computer at all.


After a day or two, try doing stuff on your Mac and see if it's behaving normally. If it is, turn Spotlight indexing back on, then walk away again for a couple of days.


When the #311 will this be fixed?


Very probably with 14.1. If you still have a backup of High Sierra, you might be able to roll back to that, but it's not likely to go much faster, really, than just walking away from the Mac for a couple days until those fragmented/corrupted files have been dealt with by the OS's background processes.


Well how do you know it works to "just walk away", huh?


I'm writing and posting this from exactly the same Mini I reported all these problems on, two days ago, as described in my original post, linked above.


There are still a few lags and bogs, but they've dropped off significantly since I left this Mini powered up overnight, while I've been copying files from my home folder to an external drive, and deleting the ones Finder throws a (-36) on.


You may be able to expedite this process yourself by doing what I've been doing: Copy each subfolder in your home folder to an external HD. Whenever Finder throws a (-36) error on a file, locate that file and delete it. But it's not a lot of fun.

macOS Mojave (10.14)

Posted on Oct 8, 2018 4:31 PM

Reply
Question marked as Top-ranking reply

Posted on Nov 9, 2018 1:32 PM

I did indeed register the bug, mr-fabulous, but alas, it wasn't a software error. There's a full rundown in the comments here:


Frequent system hangs and freezes in macOS Mojave 10.14: Notes, reproducible errors, and possible workarounds


…But the long and short of it is the rotational drive in the fusion drive was failing.


I'd urge you, and anyone else having ongoing problems with Mojave, to load Disk Utility and select your HD from the list. Then look at the "SMART Status" entry. You should see something like this (lower left in the main app window):


User uploaded file


If the SMART Status is anything other than "verified", you're heading for trouble.


Unfortunately, macOS is not designed to expose a drive's SMART status to users on an ongoing basis; you have to either check it yourself, or install third-party tools (such as SMARTreporter: https://www.corecode.io/smartreporter/ — the free/demo version is adequate to the basic task) to do it for you. The only other warning you get is bizarre read-write errors and system freezes as the HD's hardware begins to pack it in.


There is no way via Disk Utility, macOS command line tools, or any other disk-maintenance software, to bypass or work around sectors in a drive that is undergoing SMART-reported failure. The only option is replacement.


That's not to say there may not be any other problems with Mojave on any machine. However, the problems I experienced with it were 100% hardware related. After I uncoupled the 1TB rotational drive in the fusion drive and began working exclusively from the 128GB SSD, all my problems went away.


More info on what I did here (this is a reply I made on the other post): Re: Frequent system hangs and freezes in macOS Mojave 10.14: Notes, reproducible errors, and possible workarounds. I ended up having to use a thumb drive with High Sierra on it (instructions here: How to create a bootable installer for macOS - Apple Support) to break down the fusion drive into two separate volumes, but you should be able to do something similar with the command-line tools in Mojave, as well. I had to get into terminal and use the diskutil deleteContainer command to nuke the fusion drive and split it back into its component elements (diskutil man page here: https://www.dssw.co.uk/reference/diskutil.html).


Ideally it's not as grave for you as it turned out to be for me. In multiple decades of owning and operating Mac hardware, I have never seen an internal HD failure. But they can happen. I think mine was precipitated by a long-distance move across some extremely harsh road surfaces. The Mini was shut down, of course, but it got a good jostling in the back of the truck, along with everything else we owned.

Similar questions

22 replies

Nov 5, 2018 7:33 AM in response to Jazz Man

I had similar experience with my iMac [late 2012]. After updating from High Sierra, the system would freeze [unresponsive to trackpad, show beach ball constantly on Desktop and various apps]. Activity Monitor showed no issues with memory load, CPU, disk I/O, etc. Spotlight disabled on entire hard disk. I tried the potential fixes suggested here [let it sit for a day powered up] to no avail.


So I backed up and reinstalled Mojave from scratch after re-initializing the hard drive [1 TB Fusion drive]. Initially it seemed a bit better, but after a day or two it is back to the same behavior, rendering the system almost unusable. So [a] the freezing is not restricted to a particular hardware model and [b] it is not related to the upgrade process per se but is inherent in Mojave OS AFAIK.

Nov 9, 2018 9:08 PM in response to WarrenO

Thanks so much for taking the time to detail the issue and your workaround. For me the Disk Utility SMART info seems to indicate that the Fusion volume is OK, although I have not split the container back into component elements:


User uploaded file


So it is still possible that the rotational drive is failing, I will use SMARTreporter to investiate further. Odd that this all happened to coincide with Mojave upgrade, but perhaps that is the universe trying to knock on the door to let one know that all is not well...

Nov 11, 2018 8:32 PM in response to WarrenO

The saga continues.

I performed yet another backup of /Users data, reinstalled Mojave from scratch, but this time:

- Used 10.14.1 USB install media

- Ran diskutil resetFusion before installing

and things seemed to be much better, i.e. no general freeze/hang/lag.

The only exception seemed to be that starting Terminal took about 20 seconds, once it was up it was quite responsive, other than creating new shell windows.

So I did a full Time Machine backup to capture the goodness.

Then doing some minor file operation I got an error 'insufficient space on device'.

So my 1.2 TB Fusion drive was reporting [a] 350GB in use and [b] zero bytes free.

Rebooted into recover mode [Cmd-R], ran Disk Utility First Aid, and it made the volume report some delightful free space.

So for now I am a happy, if rather wary, camper. My iMac is back to mostly being the responsive system I remember from High Sierra, but having a file system inconsistency shortly after restoring all of my user data and apps makes me, well uncomfortable. In any case, it has not seemed related to rotational drive SMART errors, but rather to something in the Fusion drive initialization / split / refuse process, so maybe my SSD is getting flaky, not sure how to troubleshoot that, but it has made the last week and a half much less productive than usual...

Nov 28, 2018 8:29 PM in response to Jazz Man

That’s almost certainly a problem with the Mac mini itself, or (unlikely, but possible) with the cable, or with the monitor. Swapping the monitor and the cable for some testing, then have a chat with Apple Support.


But given the earlier reports of laggy performance and other errors, this reeks of a hardware problem with the Mac mini itself, and not the monitor or cable. Which is a repair call to your preferred provider.


Have complete and current external backups, if those can still be created...

Nov 29, 2018 5:36 AM in response to MrHoffman

I don't believe it's a hardware issue, because the problems only developed with the upgrade to Mojave. I guess I could downgrade back to Sierra and see what happens, but based upon the ripple effects of doing that (converting back from apfs to HFS+) and since the mac mini is mostly usable with 10.14.1 with Energy Saver setting turned off, I probably just live with it until Apple fixes or replaces Mojave (or stops supporting the 2014 mac mini). Although I won't be holding my breath waiting for Mojave fixes.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Laggy, frozen, slow Mojave: 100% consistent methods to reproduce, discussion of possible cause, and proposed user workarounds

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.