Jump to content

About This File

!!! ATTENTION: this does NOT AT ALL work in Mojave and above !!!

and I don't have the knowledge to fix this - sorry, but form my side, end of the road

____________________________________________________________________________

This is my mod of dimosgmx's Yosemite (10.10) Disk Utility app with the El Capitan (10.11) diskmanagementd:

 

https://www.insanelymac.com/forum/files/file/621-disk-utility-v13-for-macos-sierrazip

 

Please read his statements over there FIRST !!

 

This built (607) is dimosgmx's built 606 ever-so-slightly edited* by me (BugsB) for usage in High Sierra beyond 10.13.3. It thus works in 10.12 - 10.13.6 (not yet tested in Mojave because I don't have it installed). Therefore I bumped CFBundleVersion to 607 and BuildVersion to 19 to differentiate it from dimosgmx's 606/ 18 which was only compatible up to 10.13.3.

 

You can use it side-by-side with the default Disk Utility.

 

NOT WORKING (at least not in High Sierra): functions which would invoke a Finder style window, like clicks onto "New Image", "Convert", "Resize Image", "Image", "File/ New/.." etc.

 

In case of issues with the default (original/ stock/ vanilla) Disk Utility: run killall diskmanagementd, also supplied in this package.

 

If you have the SIMBL plug-in AFLOAT installed and have not included AppleScript Utility in mySIMBL's blacklist**, you MUST blacklist Disk Utility 13 (607) (see screenshot "AFLOAT users mySIMBL application blacklist")!

 

Virustotal result: 0 / 57

 

Enjoy & Greetings
BugsB
2019-01-05

---
* Disk Utility 13 (607).app/Contents/MacOS/loader.sh:
Added two instances of:
sudo killall diskmanagementd

 

** in mySIMBL: System Info/ SIMBL application blacklist (because Afloat is NOT fully compatible with Apple Scripts (parts of Disk Utility 13 (60x))

 

 

 

 

 

Edited by BuXb


What's New in Version (built 607)   See changelog

Released

No changelog available for this version.

  • Like 4
  • Thanks 2

User Feedback

Recommended Comments

BuXb

Posted (edited)

@MaLd0n a image.png.4e10139a4259e34203ce697b2a0888d8.png from YOU weighs 1k fold - obrigado amigo :)

 

Do you (or @dimosgmx etc.?) happen to have any idea which files(s) from Sierra might be needed to revive the file window functions? If we manage to figure that one/ these out, we'll again have a full-fledged DU for High Sierra (and hopefully beyond).

 

Also: can you test my built on Mojave?

Edited by BugsB
  • Like 1
Tetonne

Posted

thanks a lot BugsB 

happy new Year :-)

  • Like 1
dimosgmx

Posted (edited)

Mojave 10.14, doesn't open after osascript execution. I have virtual machine with a version for mojave that i fixed most of the frameworks but it' still not there yet. I did a bit of research and it appears the only way to do it is to mess with DYLD library injection. I had somewhat of a progress and then i got busy with work. I could share that file see if it takes us anywhere. But I am setting up a new machine today with high sierra I will test it further.

 

As a note, if you try to execute it via terminal:

 

dyld: Symbol not found: _OBJC_CLASS_$_NSStatusBarWindow

  Referenced from: /Users/...../Desktop/Disk Utility 13.app/Contents/MacOS/DiskUtility

  Expected in: /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit

 in /Users/...../Desktop/Disk Utility 13.app/Contents/MacOS/DiskUtility

 

I followed that chain before and I hit a wall. Thats where the DYLD injection comes in.

 

Disk Utility Mojave attempt (not functional) - The loader is renamed and the original binary is used while testing.

https://drive.google.com/file/d/1G5Z2j9OzTr5Dx6Iom2LEruKdz2oweY3u/view?usp=sharing

 

All the frameworks are from El Capitan, it seems to be the safest way.

Edited by dimosgmx
  • Like 1
BuXb

Posted

@Tetonne you are welcome.

@dimosgmx that's good news. I also got your message but reply here for best exposure and open collaboration.

 

I have also been debugging via Terminal:

File: Debug Disk Utility 13 (607).command (attached)

#!/bin/bash
clear
echo "Put this script next to Disk Utility 13 (607).app"
echo "" 
cd "$(dirname "$0")"
sudo ./"Disk Utility 13 (607).app/Contents/MacOS/loader.sh"

with the following results (10.13.6):

On start:

Failed to connect (cancelRecreate) outlet from (DUWindowController) to (NSButton): missing setter or instance variable

Failed to connect (repairSheetInfo) outlet from (DUWindowController) to (NSTextField): missing setter or instance variable

10.4-style NSNumberFormatter method called on a 10.0-style formatter, which doesn't work. Break on _NSNumberFormatter_Log_New_Methods_On_Old_Formatters to debug. This message will only be logged once.

Click onto:

1. New Image; File/ New Blank Disk Image (same error):

*** Assertion failure in void *FinderKitLibrary()(), /BuildRoot/Library/Caches/com.apple.xbs/Sources/AppKit/AppKit-1561.60.100/Nav.subproj/NSSavePanel.m:810

2. Convert; Verify; File/ New Disk Image from Folder; Open Disk Image (same error):

*** Assertion failure in void *FinderKitLibrary()(), /BuildRoot/Library/Caches/com.apple.xbs/Sources/AppKit/AppKit-1561.60.100/Nav.subproj/NSNavFinderViewFileBrowser.m:48

I see from your Disk Utility for Mojave (not there yet).app (which does not even start in my 10.13.6, not even after I signed it) you already added the AppKit.framework

 

It might be necessary to kill any running default OS process of the same name DU 13 needs to access.

 

It might also be helpful to run DU13 via terminal debug in Sierra 10.12.6 (I don't have it installed) to see how the messages should look like. But maybe that would be an extra step.

 

Does anyone know if this got broken from 10.12.6 to 10.13.0, or if it was still running in the initial High Sierra and got broken with a 10.13.x update (as did the diskmanagementd command requiring a killall after the 10.13.4 update)? It would be much easier to debug within a High Sierra update line, just looking at the files of the culprit update.

 

Good luck! Let me know if I can test anything. I might be a bit unresponsive the next three days, but then things should lighten up a bit.

Debug Disk Utility 13 (607).command

  • Like 1
BuXb

Posted

getting closer, partial success:

 

1708789941_ScreenShot2019-01-07at12_13_44.jpg.7a63de823d0d9b9a8e4feab4e2732b12.jpg

 

What I did was, copy the DiskManagement.framework from your Disk Utility for Mojave (not there yet).app into Disk Utility 13 (607).app, overwriting the old one (after backing it up). Obviously the volumes in the side bar on the left are now missing.

 

I did some testing back and forth of the folders and files inside DiskManagement.framework: the DiskManagement binary is the "do-jobby" here and thus the ONLY culprit file to fix, at least for High Sierrra.

 

I see both binaries have the exact same byte count, so I compared them with Hex Fiend: there is 66 differences (most just one or a few bytes), which is too much for byte restore debugging.

 

You apparently have more experience with and a better handle on byte patching, so I'm sure you'll succeed. Getting this to work in High Sierra seems like a good basis for Mojave :)

 

GOOD JOB !!!!!

  • Like 1
Grafovich

Posted

@BuXb, @dimosgmx Guys, just three words - YOU ARE AWESOME! Thank you for your work! :thumbsup_anim:

I love the old Disk Utility so much (new one is awkward), ported ver. has been with me since 10.11, and now it is again with me on HSierra. :rolleyes:

  • Like 1
^GoJo^

Posted

After i tried this in Mojave, the original disk utility is broken, couldn't find a way to fix, please tell me how to?

BuXb

Posted

@^GoJo^ : sorry, I'm totally out of this project. All I can do is copy/paste the loader script inside DU:

Spoiler

#!/bin/bash
cd -- "$(dirname "$0")"
pwd

# This moves the original framework, if this is the first time running, then links to it. If it does, it links to Sierra's version
if [  ! -f /usr/libexec/diskmanagementd-sierra ]; then
    mv /usr/libexec/diskmanagementd /usr/libexec/diskmanagementd-sierra
    ln -s /usr/libexec/diskmanagementd-sierra /usr/libexec/diskmanagementd
else
    rm /usr/libexec/diskmanagementd  # After Diskutility closes for any reason, we unlink the framework
    ln -s /usr/libexec/diskmanagementd-sierra /usr/libexec/diskmanagementd # Link back to original
    
fi
cp diskmanagementd /usr/libexec/diskmanagementd-elcap # Copy El Capitan's to the same place
rm /usr/libexec/diskmanagementd # Removes the link
ln -s /usr/libexec/diskmanagementd-elcap /usr/libexec/diskmanagementd # Links to El Capitan's version

sudo killall diskmanagementd

./DiskUtility # Runs Diskutility
rm /usr/libexec/diskmanagementd  # After Diskutility closes for any reason, we unlink the framework
ln -s /usr/libexec/diskmanagementd-sierra /usr/libexec/diskmanagementd # Link back to original

sudo killall diskmanagementd

 

 

robiox

Posted

Hi,

 

I tried to use your disk utility under Mojave 10.14.6 but I've encountered a serious issue: I can't install new apps through installers (when they try to find the drive to install files, they don't find nothing and the only thing to do is abort installation) and if run original disk utility, I view the window of the app with a loading icon and the text "loading drives" and stay in this state forever.

I've tried to run diskutil from terminal but it say: error could not run DiskManagement process.

 

I tried to reboot several times, reset nvram, pram, SMC, run in safe mode, check disk/partition on recovery mode (all it's perfect on the drive), but without solution.

On recovery disk utility and diskutil from terminal are available but not in my session! I'm the only administration of the MacBook Pro and there is only my account.

 

Have you an idea to solve the issue without formatting the system or reinstall the mojave/Catalina/big Sur on the machine?

 

Regards

 

Robiox

BuXb

Posted

Hi Robiox. The two standard options are:

 

1) restore from a time machine backup

2. boot from your bootable backup drive that you created via a tool like Carbon Copy Cloner, Super Duper or alike and restore back

robiox

Posted

2 hours ago, BuXb said:

Hi Robiox. The two standard options are:

 

1) restore from a time machine backup

2. boot from your bootable backup drive that you created via a tool like Carbon Copy Cloner, Super Duper or alike and restore back

Hi BuXb,

Thank you for replying and trying to help me!

 

I'm sorry but I don't have done any backup (time machine, Carbon Copy)!

 

If I would have one of them, I wouldn't spend so many time to solve the issue!

BuXb

Posted

Yeah, learning curve. I've been there myself. But it's worth it to shift one's processes one gear up from such a point onward.

 

I can send you something tomorrow in the course of the day (am already too tired now). For now, relax and breathe deeply - our lungs need the extra treatment in these times :)

 

robiox

Posted

1 hour ago, BuXb said:

Yeah, learning curve. I've been there myself. But it's worth it to shift one's processes one gear up from such a point onward.

 

I can send you something tomorrow in the course of the day (am already too tired now). For now, relax and breathe deeply - our lungs need the extra treatment in these times :)

 

Yes!

You're right!

I will do several breathe! Like the first track of Dark Side Of The Moon! ;P

 

In the meantime, I've discovered an interesting thing!

Under the folder /usr/libexec I've found two files modified the same day I ran the disk utility modded app!

The files are: diskmanagementd and diskmanagementd-sierra.

Is it possible that the reason of my issue are the modified files not corresponding with the original ones needed to the system to do the right process?

 

If yes, how can I restore the original Mojave' files???

robiox

Posted

2 hours ago, BuXb said:

Yeah, learning curve. I've been there myself. But it's worth it to shift one's processes one gear up from such a point onward.

 

I can send you something tomorrow in the course of the day (am already too tired now). For now, relax and breathe deeply - our lungs need the extra treatment in these times :)

 

Oh Yes!

You're right!

I will do several breathe! Like the first track of Dark Side Of The Moon! :)

 

In the meantime, I've found the solution!

 

I copied the two files diskmanagementd and diskmanagementstartup from the recovery partition under the Recovery Mode!

 

Thanks to Google and the too many guides of terminal commands!

 

Now disk utility and all the others functionalities come back!

  • Thanks 1
BuXb

Posted

these were the files I was gonna send you - great you figured it out!

 

(breathing: I rather had Darth Vader in mind...

 

.. just kidding ;) )

×
×
  • Create New...