Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not a Know DirStatus #1

Open
kash1982 opened this issue May 15, 2024 · 20 comments
Open

Not a Know DirStatus #1

kash1982 opened this issue May 15, 2024 · 20 comments

Comments

@kash1982
Copy link

  1. Bypass MDM from Recovery
  2. Reboot & Exit
    Please enter your choice: 1
    Bypass MDM from Recovery
    Create a Temporary User
    Enter Temporary Fullname (Default is 'Apple'):
    Enter Temporary Username (Default is 'Apple'):
    Enter Temporary Password (Default is '1234'):
    Creating Temporary User
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    mkdir: /Volumes/Data/Users: No such file or directory
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    ./bypass-mdm.sh: line 51: /Volumes/Macintosh HD/etc/hosts: No such file or directory
    ./bypass-mdm.sh: line 52: /Volumes/Macintosh HD/etc/hosts: No such file or directory
    ./bypass-mdm.sh: line 53: /Volumes/Macintosh HD/etc/hosts: No such file or directory
    Successfully blocked MDM & Profile Domains
    touch: /Volumes/Data/private/var/db/.AppleSetupDone: No such file or directory
    touch: /Volumes/Macintosh HD/var/db/ConfigurationProfiles/Settings/.cloudConfigProfileInstalled: No such file or directory
    touch: /Volumes/Macintosh HD/var/db/ConfigurationProfiles/Settings/.cloudConfigRecordNotFound: No such file or directory
    MDM enrollment has been bypassed!
    Exit terminal and reboot your Mac.
@assafdori
Copy link
Owner

@kash1982 You'll need to provide more context in order for me to help you out.

@kash1982
Copy link
Author

sure. what do you need? its on snoma currently.

@assafdori
Copy link
Owner

assafdori commented May 15, 2024

sure. what do you need? its on snoma currently.

I can assure you that the script works as long as you follow the guidelines. Which Mac model are you using? Did you re-format the Mac before starting? Elaborate on your exact workflow.

@kash1982
Copy link
Author

kash1982 commented May 15, 2024

A1989

wipe drive in disk utils

Reinstall mac os snoma

turn off mchine then follow your guidelines the readme

@cmsj
Copy link

cmsj commented May 15, 2024

@kash1982 did you get as far as the enrollment screen after installing sonoma?
I just ran this bypass today on a new M3 Air that shipped with macOS 14.5 and it worked fine.

@kash1982
Copy link
Author

no i just powered down after snoma install finished. i did try before hand when i was at the click to enrole button but got the same

@assafdori
Copy link
Owner

Do you arrive at a screen similar to this one? This is when you should be starting the guide.
image

@kash1982
Copy link
Author

just tried it on that screen. powered down and run the script. same errors. on reboot im back at select your country

@kash1982
Copy link
Author

will try Option-Shift-Command-R instead and report back

@kash1982
Copy link
Author

i get a curl error in the old recovery environment (high Sierra install)
curl: (4) A requested feature, protocolor option was not found or built-in in this libcurl due to a build-time decision.

@kash1982
Copy link
Author

kash1982 commented May 16, 2024

the only thing i can think of is has start up secuiity enabled so i cant boot from usb. there no way to disable it also becuase there no users on the macbook and it errors when trying to turn it off saying no admin users found.

@jhtang5
Copy link

jhtang5 commented May 28, 2024

I had the same "Not a Know DirStatus" error - my pre-owned macbook air 2020 i7 got "the remoate management screen" right after system upgrade to Sonoma a few days ago. Followed the guideline to reinstall the system, tried the script and then got the following. Not sure what went wrong.

-bash-3.2# curl https://raw.githubusercontent.com/assafdori/bypass-mdm/main/bypass-mdm.sh -o bypass-mdm.sh && chmod +x ./bypass-mdm.sh && ./bypass-mdm.sh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 4831 100 4831 0 0 7231 0 --:--:-- --:--:-- --:--:-- 7232
Bypass MDM By Assaf Dori (assafdori.com)

  1. Bypass MDM from Recovery
  2. Reboot & Exit
    Please enter your choice: 1
    Bypass MDM from Recovery
    Create a Temporary User
    Enter Temporary Fullname (Default is 'Apple'):
    Enter Temporary Username (Default is 'Apple'):
    Enter Temporary Password (Default is '1234'):
    Creating Temporary User
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    mkdir: /Volumes/Data/Users: No such file or directory
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Operation failed with error: Not a known DirStatus
    Successfully blocked MDM & Profile Domains
    touch: /Volumes/Data/private/var/db/.AppleSetupDone: No such file or directory
    MDM enrollment has been bypassed!
    Exit terminal and reboot your Mac.

@jhtang5
Copy link

jhtang5 commented May 31, 2024

@assafdori @kash1982 I found the issue and get it fixed. my Macbook is now MDM free. my Mac originally used Chinese language and so was set up with a slightly different directory naming, even after system reinstall if language kept using Chinese. What I did is to change the language back to English right after Command-R, then make all system reinstall and script execution in English. all the steps in Readme could be successfully completed. Job well done !!. Thanks !

@assafdori
Copy link
Owner

@jhtang5 Thanks for providing the solution, I'll update the README file accordingly.

@tiinpa
Copy link

tiinpa commented Jun 18, 2024

Experienced the same issue described above despite being in English. Eventually realized the install volume needed to be named “Macintosh HD”. Once I erased/renamed the volume and reinstalled I was able to successfully bypass.

@jhtang5
Copy link

jhtang5 commented Jun 18, 2024

@tiinpa Here is my experience: I had encountered this issue before, but I discovered that it was due to the system still being set on a non-English language during the reinstallation process.

@zarepp
Copy link

zarepp commented Jun 18, 2024

Experienced the same issue described above despite being in English. Eventually realized the install volume needed to be named “Macintosh HD”. Once I erased/renamed the volume and reinstalled I was able to successfully bypass.

this solution resolved my issue. thank you so much!

@yMorsi
Copy link

yMorsi commented Jul 3, 2024

I’m having the same issue regarding the “not a known DirStatus” error but after thoroughly reading everyone’s troubleshooting attempts I noticed that my language is set to English and my volume is named the correct “Macintosh HD” yet I am still receiving this error. If anyone could help me out on this issue I’ll be happy to provide more details and context

@yMorsi
Copy link

yMorsi commented Jul 3, 2024

Update - didn’t re-format the macOS like the instructions clearly said to do(I’m slow). After erasing the volume group then reinstalling the macOS through recovery mode I was able to execute the script successfully. After rebooting the Mac I was met with no Device enrollment message and the Mac operates with no issues.

Thank you so much @assafdori. You are very talented and I seriously appreciate you providing a fix to what is clearly a very meticulous issue.

@G1391177
Copy link

G1391177 commented Jul 12, 2024

can it support external SSD drive? I mean I still need MDM enrollment on my native system, but can I use external drive without MDM? So I can have two system, one for company policy usage, one for other things like game.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants