Support

Get help using our products.

After installing iDefrag 5, my machine takes a long time to shut down

First, please make sure you are using iDefrag 5.1.3 (for machines running OS X 10.11 or earlier), or iDefrag 5.1.7 or later (for machines running macOS Sierra or later). In particular, version 5.1.5 and 5.1.6 have a problem with the code signature on one of our kernel extensions, which upsets macOS Sierra. Note that 5.1.7 will not necessarily cure the problem completely — it may still take a long time to shut down on the first occasion — but this will only happen once.

On the first restart after installing iDefrag, some machines take a long time to shut down and will sit with a black screen for many minutes (we’ve seen them take as long as an hour here).

It appears that what’s going on is that the automatic kernel cache rebuild is taking a very long time for some reason. If this happens, some users (us included) get fed up and force the machine to shut down, but that can result in either a damaged kernel cache or in the cache not including the new KEXTs that are required for iDefrag’s reboot-and-defragment to work. Very occasionally, machines with broken kernel caches won’t even boot.

If you are in this situation do not panic. Simply

  1. Boot into Recovery Mode by restarting and holding Command-R.
  2. From the Utility menu at the top of the screen, choose Terminal.
  3. Enter the command

    kextcache -i "/Volumes/Macintosh HD"
    

    If you have renamed your hard disk, you may need to adjust the above command accordingly.

  4. Wait for it to complete. It should take about 10-20 seconds.

  5. Restart the computer.

We have reported this behaviour to Apple (rdar://29732811), as it’s clearly a bug in the macOS that it should take so long if a rebuild is happening during shutdown when rebuilding normally takes seconds.


Posted by alastair at 2016-Dec-19 13:12:05 UTC. Last updated 2017-Jan-15 18:01:55 UTC.