Mac Mini m4 failed to enter restore mode
Environment
- Host OS: Windows 11
- CPU: AMD Ryzen 5700x
- Shell: MSYS2 MinGW64
idevicerestore
idevicerestore 1.0.0-255-ga0cec3b (libirecovery 1.3.0, libtatsu 1.0.5-2-gfc57e26)
Library versions
libusbmuxd-2.0 2.1.1-2-g93eb168
libimobiledevice 1.3.0-304-g54f6437
libirecovery 1.3.0
libtatsu 1.0.5-2-gfc57e26
libplist 2.7.0-3-g91ba426
What I tried
- Different USB cables (USB-C ↔ USB-C and USB-C ↔ USB-A)
- Different IPSW versions for my Mac
Observed behavior
- Restore process starts correctly (iBSS, iBEC, ramdisk, SEP, kernelcache all sent successfully).
- At the stage “Waiting for device to enter restore mode…”, device reboots, LED changes from red → white, Apple logo appears with empty progress bar.
- Process then fails with: Device failed to enter restore mode. Device reconnected in Recovery mode, most likely image personalization failed.
- Device stays stuck at Apple logo with empty bar.
09:22:29.565 <Info> idevicerestore 1.0.0-255-ga0cec3b (libirecovery 1.3.0, libtatsu 1.0.5-2-gfc57e26)
09:22:29.585 <Info> Found device in Port DFU mode
09:22:29.601 <Info> ECID: 1289542151176081965
09:22:29.601 <Info> Identified device as j773gap, Mac16,10
09:22:29.602 <Info> Device Product Version: N/A
09:22:29.602 <Info> Device Product Build: N/A
09:22:30.075 <Info> The following firmwares are currently being signed for Mac16,10:
09:22:30.076 <Info> [1] 26.0 (build 25A354)
09:22:30.076 <Info> [2] 15.6.1 (build 24G90)
09:22:30.077 <Info> [3] 15.6 (build 24G84)
09:22:30.078 <Info> [4] 15.5 (build 24F74)
09:22:30.078 <Info> [5] 15.4.1 (build 24E263)
09:22:30.079 <Info> [6] 15.4 (build 24E248)
09:22:30.079 <Info> [7] 15.3.2 (build 24D81)
09:22:30.080 <Info> [8] 15.3.1 (build 24D70)
09:22:30.081 <Info> [9] 15.3 (build 24D60)
09:22:30.081 <Info> [10] 15.2 (build 24C101)
09:22:30.082 <Info> [11] 15.2 (build 24C2101)
09:22:30.082 <Info> [12] 15.1.1 (build 24B2091)
09:22:30.083 <Info> [13] 15.1 (build 24B2083)
09:22:56.447 <Notice> Selected firmware 15.2 (build 24C101)
09:22:56.448 <Info> Verifying 'UniversalMac_15.2_24C101_Restore.ipsw'...
09:24:03.371 <Info> Checksum matches.
09:24:03.377 <Info> Extracting BuildManifest from IPSW
09:24:04.501 <Info> Received USBPortController1,Ticket
09:24:04.502 <Info> Creating Ace3Binary
09:24:04.505 <Info> Sending data (39865 bytes)...
09:24:09.421 <Info> Port DFU restore successful. Continuing.
09:24:09.422 <Info> IPSW Product Version: 15.2
09:24:09.422 <Info> IPSW Product Build: 24C101 Major: 24
09:24:09.425 <Info> Device supports Image4: true
09:24:09.426 <Info> Variant: Customer Erase Install (IPSW)
09:24:09.426 <Info> This restore will erase all device data.
09:24:09.427 <Info> Performing macOS restore
09:25:03.021 <Info> Checking IPSW for required components...
09:25:03.302 <Info> All required components found in IPSW
09:25:03.308 <Info> Getting ApNonce in DFU mode... 38 aa 6e 59 20 a2 3f 16 dd e4 4c 94 d8 fa 75 55 1e 59 b7 ed 04 aa 69 f1 94 c8 6d 82 67 47 1e 45
09:25:03.311 <Info> Trying to fetch new SHSH blob
09:25:03.311 <Info> Getting SepNonce in dfu mode... 01 3c a4 c2 1c 21 88 82 c9 9c a8 c4 08 bc 1d 8c 94 9a 67 63
09:25:04.358 <Info> Received SHSH blobs
09:25:04.359 <Info> Getting SepNonce in dfu mode... 01 3c a4 c2 1c 21 88 82 c9 9c a8 c4 08 bc 1d 8c 94 9a 67 63
09:25:04.914 <Info> Received SHSH blobs
09:25:04.915 <Info> Getting SepNonce in dfu mode... 01 3c a4 c2 1c 21 88 82 c9 9c a8 c4 08 bc 1d 8c 94 9a 67 63
09:25:05.515 <Info> Received SHSH blobs
09:25:05.517 <Info> Extracting iBSS.j773g.RELEASE.im4p (Firmware/dfu/iBSS.j773g.RELEASE.im4p)...
09:25:05.526 <Info> Personalizing IMG4 component iBSS...
09:25:05.527 <Info> Sending iBSS (1240962 bytes)...
09:25:07.112 <Info> Nonce: 38 aa 6e 59 20 a2 3f 16 dd e4 4c 94 d8 fa 75 55 1e 59 b7 ed 04 aa 69 f1 94 c8 6d 82 67 47 1e 45
09:25:07.114 <Info> Personalizing IMG4 component Ap,LocalPolicy...
09:25:07.115 <Info> Sending Ap,LocalPolicy (3045 bytes)...
09:25:07.118 <Info> INFO: executing command: lpolrestore
09:25:07.121 <Info> iBoot boot-stage=1
09:25:07.121 <Info> Extracting t8132ciofw.im4p (Firmware/t8132ciofw.im4p)...
09:25:07.128 <Info> Personalizing IMG4 component Ap,RestoreCIO...
09:25:07.129 <Info> Sending Ap,RestoreCIO (186814 bytes)...
09:25:07.134 <Info> INFO: executing command: firmware
09:25:07.137 <Info> Extracting t8132tmufw.im4p (Firmware/t8132tmufw.im4p)...
09:25:07.143 <Info> Personalizing IMG4 component Ap,RestoreTMU...
09:25:07.144 <Info> Sending Ap,RestoreTMU (24987 bytes)...
09:25:07.147 <Info> INFO: executing command: firmware
09:25:07.148 <Info> Extracting rans.t8132_ASP3.release.im4p (Firmware/rans.t8132_ASP3.release.im4p)...
09:25:07.155 <Info> Personalizing IMG4 component RestoreANS...
09:25:07.156 <Info> Sending RestoreANS (1257980 bytes)...
09:25:07.189 <Info> INFO: executing command: firmware
09:25:08.088 <Info> Extracting t8132dcp_restore.im4p (Firmware/dcp/t8132dcp_restore.im4p)...
09:25:08.098 <Info> Personalizing IMG4 component RestoreDCP...
09:25:08.100 <Info> Sending RestoreDCP (3918106 bytes)...
09:25:08.199 <Info> INFO: executing command: firmware
09:25:08.272 <Info> INFO: executing command: setenv auto-boot false
09:25:08.273 <Info> INFO: executing command: saveenv
09:25:08.275 <Info> INFO: executing command: setenvnp boot-args rd=md0 nand-enable-reformat=1 -progress -restore
09:25:08.277 <Info> Extracting applelogo@1x~mac-USBc.im4p (Firmware/all_flash/applelogo@1x~mac-USBc.im4p)...
09:25:08.285 <Info> Personalizing IMG4 component RestoreLogo...
09:25:08.286 <Info> Sending RestoreLogo (12992 bytes)...
09:25:08.287 <Info> INFO: executing command: setpicture 4
09:25:08.288 <Info> INFO: executing command: bgcolor 0 0 0
09:25:08.290 <Info> Extracting iBEC.j773g.RELEASE.im4p (Firmware/dfu/iBEC.j773g.RELEASE.im4p)...
09:25:08.299 <Info> Personalizing IMG4 component iBEC...
09:25:08.300 <Info> Sending iBEC (1064670 bytes)...
09:25:10.168 <Info> INFO: device serial number is VP71212FL7
09:25:10.170 <Info> Recovery Mode Environment:
09:25:10.172 <Info> iBoot build-version=iBoot-11881.61.3
09:25:10.173 <Info> iBoot build-style=RELEASE
09:25:10.175 <Info> iBoot boot-stage=2
09:25:10.176 <Info> radio-error=2
09:25:10.177 <Info> radio-error-string=2
09:25:10.179 <Info> Sending RestoreLogo...
09:25:10.179 <Info> Extracting applelogo@1x~mac-USBc.im4p (Firmware/all_flash/applelogo@1x~mac-USBc.im4p)...
09:25:10.186 <Info> Personalizing IMG4 component RestoreLogo...
09:25:10.187 <Info> Sending RestoreLogo (12992 bytes)...
09:25:10.190 <Info> Extracting h16_ane_fw_leto_j7x.im4p (Firmware/ane/h16_ane_fw_leto_j7x.im4p)...
09:25:10.200 <Info> Personalizing IMG4 component ANE...
09:25:10.201 <Info> Sending ANE (1534086 bytes)...
09:25:10.246 <Info> Extracting aopfw-j773gaop.RELEASE.im4p (Firmware/AOP/aopfw-j773gaop.RELEASE.im4p)...
09:25:10.257 <Info> Personalizing IMG4 component AOP...
09:25:10.258 <Info> Sending AOP (1878150 bytes)...
09:25:10.333 <Info> Extracting AppleAVE2FW_H16G.im4p (Firmware/ave/AppleAVE2FW_H16G.im4p)...
09:25:10.344 <Info> Personalizing IMG4 component AVE...
09:25:10.345 <Info> Sending AVE (1683598 bytes)...
09:25:10.393 <Info> Extracting t8132pmcfw.im4p (Firmware/pmc/t8132pmcfw.im4p)...
09:25:10.399 <Info> Personalizing IMG4 component Ap,ApplePMCFirmware...
09:25:10.400 <Info> Sending Ap,ApplePMCFirmware (34535 bytes)...
09:25:10.409 <Info> Extracting t8132dcp.im4p (Firmware/dcp/t8132dcp.im4p)...
09:25:10.419 <Info> Personalizing IMG4 component Ap,DCP2...
09:25:10.421 <Info> Sending Ap,DCP2 (3918096 bytes)...
09:25:10.621 <Info> Extracting sptm.t8132.release.im4p (Firmware/sptm.t8132.release.im4p)...
09:25:10.627 <Info> Personalizing IMG4 component Ap,RestoreSecurePageTableMonitor...
09:25:10.629 <Info> Sending Ap,RestoreSecurePageTableMonitor (169755 bytes)...
09:25:10.636 <Info> Extracting txm.macosx.release.im4p (Firmware/txm.macosx.release.im4p)...
09:25:10.643 <Info> Personalizing IMG4 component Ap,RestoreTrustedExecutionMonitor...
09:25:10.644 <Info> Sending Ap,RestoreTrustedExecutionMonitor (167608 bytes)...
09:25:10.651 <Info> Extracting armfw_g16g.im4p (Firmware/agx/armfw_g16g.im4p)...
09:25:10.665 <Info> Personalizing IMG4 component GFX...
09:25:10.667 <Info> Sending GFX (2879526 bytes)...
09:25:10.748 <Info> Extracting t8132pmp.im4p (Firmware/pmp/t8132pmp.im4p)...
09:25:10.757 <Info> Personalizing IMG4 component PMP...
09:25:10.759 <Info> Sending PMP (661638 bytes)...
09:25:10.784 <Info> Extracting 044-81195-001.dmg.trustcache (Firmware/044-81195-001.dmg.trustcache)...
09:25:10.791 <Info> Personalizing IMG4 component RestoreTrustCache...
09:25:10.792 <Info> Sending RestoreTrustCache (21373 bytes)...
09:25:10.795 <Info> Extracting SmartIOFirmware_ASCv7.im4p (Firmware/SmartIOFirmware_ASCv7.im4p)...
09:25:10.804 <Info> Personalizing IMG4 component SIO...
09:25:10.805 <Info> Sending SIO (1163914 bytes)...
09:25:10.839 <Info> Extracting iBootData.j773g.RELEASE.im4p (Firmware/all_flash/iBootData.j773g.RELEASE.im4p)...
09:25:10.846 <Info> Personalizing IMG4 component iBootData...
09:25:10.847 <Info> Sending iBootData (10471 bytes)...
09:25:10.850 <Info> ramdisk-size=0x20000000
09:25:10.850 <Info> Extracting 044-81195-001.dmg (044-81195-001.dmg)...
09:25:11.161 <Info> Personalizing IMG4 component RestoreRamDisk...
09:25:11.191 <Info> Sending RestoreRamDisk (182462601 bytes)...
09:25:18.106 <Info> Extracting DeviceTree.j773gap.im4p (Firmware/all_flash/DeviceTree.j773gap.im4p)...
09:25:18.112 <Info> Personalizing IMG4 component RestoreDeviceTree...
09:25:18.113 <Info> Sending RestoreDeviceTree (55822 bytes)...
09:25:18.118 <Info> Extracting sep-firmware.j773g.RELEASE.im4p (Firmware/all_flash/sep-firmware.j773g.RELEASE.im4p)...
09:25:18.129 <Info> Personalizing IMG4 component RestoreSEP...
09:25:18.131 <Info> Sending RestoreSEP (5879033 bytes)...
09:25:18.277 <Info> Extracting kernelcache.release.mac16g (kernelcache.release.mac16g)...
09:25:18.320 <Info> Personalizing IMG4 component RestoreKernelCache...
09:25:18.326 <Info> Sending RestoreKernelCache (29319881 bytes)...
09:25:19.808 <Info> Waiting for device to enter restore mode...
09:27:48.527 <Error> Device failed to enter restore mode.
09:27:48.528 <Error> Device reconnected in Recovery mode, most likely image personalization failed.
Do you have Apple Mobile Device support installed? Otherwise there is no usbmuxd, and it cannot see the device in restore mode.
I installed iTunes and now Apple Mobile Device Service is running, but the problem is still the same.
After Waiting for device to enter restore mode... the Mac disconnects and reconnects, but in Windows Device Manager it only shows up as an unrecognized "Mac" device with a yellow exclamation mark. At this point the restore process stops and does not continue.
Ok that makes sense now, I guess that the Windows driver does not support Mac devices.
@Rowb My issue is also same. I will try with latest commit this weekend but I tried every possible thing in the universe and error was the same as yours never got solved
#746
@Abubakar-Waheed I eventually managed to restore my Mac mini using an old MacBook Pro 2012 with macOS Sequoia installed.
@Rowb Wish I was that lucky. I have m1 air which I tried using to do it but it failed and its ALWAYS That kernalcache error on linux and on mac it also gives some kind of error but same thing where it restarts.
@Rowb Did you used idevicerestore most recent version that got commited?
@Abubakar-Waheed Yes, I used the latest version. With the M1 MacBook Air, it should be much easier — you can use the standard Apple utility or Apple Configurator 2.
@Rowb I have tried like 15-20 times using apple configurator and it never works. Can you tell me which IPSW verison, software versions for idevice restore libusb etc you used so I can try the same?
My logs are here #746 I shared the issue like 2 months ago. Mac is currently sitting in cabinet presumly dead.
@Abubakar-Waheed The environment I was working in is described in the issue. I was trying to restore using the macOS 15.2 IPSW (you can see that in the logs). Using a MacBook, I managed to get it working with version 15.4, if I remember correctly.
The main problem on Windows was that the driver couldn’t detect the DFU reconnection, as mentioned above. I’m not sure whether that’s a driver issue or if my version of Windows 11 (not the latest one) simply doesn’t support the Mac mini.
Have you tried with the latest version? I think they’ve fixed something related to that.
@Rowb Thanks for the replies. Yes I have checked that and your success motivated me to try again so thats what I did this last 1 hour and still failed. I most of the IPSW files for checking and I checked one file from each version i.e 13,14,15 and none of them worked.
Exact same error persistent all around.
I have gathered logs here so maybe that can help in finding a solution for this.
They are here: https://docs.google.com/document/d/1tFYP-1knnUhdUQcm2uiJBZ8ycc-PhWk5PeZHjWesrog/edit?usp=sharing
cc @nikias
I have same issue in raspberry pi 5, using mac mini m4. version: idevicerestore 1.0.0-267-ga499b62 (libirecovery 1.3.1, libtatsu 1.0.5-3-g60a39f3)
It works with macos26(Install macOS Tahoe 26.1_25B78.ipsw) but not macos15(Install macOS Sequoia 15.6.1_24G90.ipsw).
macos15 same error: Device failed to enter restore mode
Update: Use idevicerestore in docker version, and it works now!
@StormYudi Can you guide me on how you used the the docker version to solve it. Please lay out step by step so I can test it. I have been stuck with the issue for the past 3 months and laptop is sitting idle there waiting for some miracle.
@StormYudi Can you guide me on how you used the the docker version to solve it. Please lay out step by step so I can test it. I have been stuck with the issue for the past 3 months and laptop is sitting idle there waiting for some miracle.
It is mentioned in the README: https://github.com/libimobiledevice/idevicerestore/blob/master/README.md#docker
@StormYudi Can you guide me on how you used the the docker version to solve it. Please lay out step by step so I can test it. I have been stuck with the issue for the past 3 months and laptop is sitting idle there waiting for some miracle.
It is mentioned in the README: https://github.com/libimobiledevice/idevicerestore/blob/master/README.md#docker
@nikias @StormYudi I tried with docker 100% followed the instructions, built using build.sh and after that ran it with the most latest ipsw file and it always says "Failed to found device". While locally it does detect device on "lsusb". It doesn't detect the device at all in the docker mode. Tried consulting claude on that and it tried various commands but it failed.
I also tried again to do it locally and compiled everything 100% from scratch and it has the most latest version and it still fails at kernalcache.
So tired of trying I have put at least 80+ hours in total into this issue and it never solves. One thing I know is that it has to do with usbmuxd but I run it correctly with all privileges and latest version but it still doesn't work.
@StormYudi Can you guide me on how you used the the docker version to solve it. Please lay out step by step so I can test it. I have been stuck with the issue for the past 3 months and laptop is sitting idle there waiting for some miracle.
It is mentioned in the README: https://github.com/libimobiledevice/idevicerestore/blob/master/README.md#docker
@nikias @StormYudi I tried with docker 100% followed the instructions, built using build.sh and after that ran it with the most latest ipsw file and it always says "Failed to found device". While locally it does detect device on "lsusb". It doesn't detect the device at all in the docker mode. Tried consulting claude on that and it tried various commands but it failed.
I also tried again to do it locally and compiled everything 100% from scratch and it has the most latest version and it still fails at kernalcache.
So tired of trying I have put at least 80+ hours in total into this issue and it never solves. One thing I know is that it has to do with usbmuxd but I run it correctly with all privileges and latest version but it still doesn't work.
Have you tried compiling using a Debian/Ubuntu virtual machine? (Perhaps the best option is Ubuntu with Docker). I see you're using Fedora; I tried it before, but encountered problems and gave up immediately. However, I don't have many operating systems to choose from on my Raspberry Pi ;)
Can you check the restore_TIMESTAMP.log? How long is it from
Waiting for device to enter restore mode...
to
Device failed to enter restore mode
and then
Device reconnected in DFU mode
?
Can you check the restore_TIMESTAMP.log? How long is it from
Waiting for device to enter restore mode...toDevice failed to enter restore modeand thenDevice reconnected in DFU mode?
@nikias Here's the latest log for that https://docs.google.com/document/d/1nXsc5HiC7zEl3GaCoSRWufHzdaILxAHhJP5R3nZl6nc/edit?usp=sharing
It's about 3 seconds from waiting for device to enter restore mode... to Device failed to enter restore mode and Device reconnected in DFU mode is immediately after it.
I'm using brand new ubuntu natively installed on pc, compiled idevicerestore and everything latest from source, actually made a script for that. I will share that as well.
One thing that I must add here is that whenever it fails and and gives error and stops I go back and check with sudo dmesg -w to see what is the current state of macbook and it prints there that its in dfu mode when in reality its not as when kernalcache/waiting for restore fails the laptop goes blank and then apple logo comes and it fails and that time it doesn't go back into restore mode or dfu mode I think its recovery mode. So I turn off the laptop, turn it on and that is when I see that its in recovery mode. After that I put it in dfu mode and then try my luck again with the idevicerestore process.