Contribute
Register

[SUCCESS] Gigabyte Designare Z390 (Thunderbolt 3) + i7-9700K + AMD RX 580

This is what I get on my side:
sudo: /usr/bin/sudo must be owned by uid 0 and have the setuid bit set
Ouch, this could indicate a simple problem with file ownerships and permissions, or a larger problem. Let's determine the severity of the problem. Copy and paste each of these lines one-by-one in Terminal:
Code:
ls -l /usr/bin/sudo > ~/Documents/filecheck.txt
ls -l /usr/bin | head -n 20  >> ~/Documents/filecheck.txt
ls -l /private/etc/sudoers  >> ~/Documents/filecheck.txt
ls -l /private/etc | head -n 20  >> ~/Documents/filecheck.txt
This will create a file called filecheck.txt in your Documents folder. Please upload that file.
 
Should I replace the missing files?
Yes, a complete drivers/UEFI folder should contain all of the files in the second screenshot.
 
Ouch, this could indicate a simple problem with file ownerships and permissions, or a larger problem. Let's determine the severity of the problem. Copy and paste each of these lines one-by-one in Terminal:
Code:
ls -l /usr/bin/sudo > ~/Documents/filecheck.txt
ls -l /usr/bin | head -n 20  >> ~/Documents/filecheck.txt
ls -l /private/etc/sudoers  >> ~/Documents/filecheck.txt
ls -l /private/etc | head -n 20  >> ~/Documents/filecheck.txt
This will create a file called filecheck.txt in your Documents folder. Please upload that file.
Here is the result, I hope it will help to solve my problem
 

Attachments

  • filecheck.txt
    2.6 KB · Views: 76
Here is the result, I hope it will help to solve my problem
The files in your /usr/bin folder (including sudo) have ACLs (access control lists) attached to them. On my MacBook Air running Catalina, those files do not have ACLs.

Let's repeat the above as follows to look at the ACLs:
Code:
ls -leO@ /usr/bin/sudo > ~/Documents/filecheckACL.txt
ls -leO@ /usr/bin | head -n 20  >> ~/Documents/filecheckACL.txt
ls -leO@ /private/etc/sudoers  >> ~/Documents/filecheckACL.txt
ls -leO@ /private/etc | head -n 20  >> ~/Documents/filecheckACL.txt
This will create a file called filecheckACL.txt in the same Documents folder. Please upload that file.

Are you running Mojave?

If anyone else is running Mojave right now, can you please run the same 4 commands in Terminal and post your reply.
 
This is what I get on my side:
sudo: /usr/bin/sudo must be owned by uid 0 and have the setuid bit set

Ok, you need to see if root is the owner of sudo as the message is asking. First check your passwd file to see that root is indeed uid 0.

cat /etc/passwd | grep root

then

ls -l@ /usr/bin/sudo

These are the results you should be expecting.

Code:
-> % cat /etc/passwd | grep root
root:*:0:0:System Administrator:/var/root:/bin/sh

and

Code:
-> % ls -l@ /usr/bin/sudo
-r-s--x--x  1 root  wheel  370720 Jul 29 13:59 /usr/bin/sudo

If you don't see root and wheel, then you may have an issue.
 
The files in your /usr/bin folder (including sudo) have ACLs (access control lists) attached to them. On my MacBook Air running Catalina, those files do not have ACLs.

Let's repeat the above as follows to look at the ACLs:
Code:
ls -leO@ /usr/bin/sudo > ~/Documents/filecheckACL.txt
ls -leO@ /usr/bin | head -n 20  >> ~/Documents/filecheckACL.txt
ls -leO@ /private/etc/sudoers  >> ~/Documents/filecheckACL.txt
ls -leO@ /private/etc | head -n 20  >> ~/Documents/filecheckACL.txt
This will create a file called filecheckACL.txt in the same Documents folder. Please upload that file.

Are you running Mojave?

If anyone else is running Mojave right now, can you please run the same 4 commands in Terminal and post your reply.

Sorry, my bad for not seeing the subsequent replies by @CaseySJ.

You can also try this to see what is not owned by root.

Code:
ls -leO@ /usr/bin | grep -v ' root '

Which should result in a pretty small list like this.

Code:
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed    133392 Jul 29 13:59 cu
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed     93664 Jul 29 13:59 uucp
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed     48288 Jul 29 13:59 uuname
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed    106224 Jul 29 13:59 uustat
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed     97760 Jul 29 13:59 uux
 
Sorry, my bad for not seeing the subsequent replies by @CaseySJ.

You can also try this to see what is not owned by root.

Code:
ls -leO@ /usr/bin | grep -v ' root '

Which should result in a pretty small list like this.

Code:
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed    133392 Jul 29 13:59 cu
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed     93664 Jul 29 13:59 uucp
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed     48288 Jul 29 13:59 uuname
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed    106224 Jul 29 13:59 uustat
-r-xr-xr-x   1 _uucp  wheel  restricted,compressed     97760 Jul 29 13:59 uux

And here's this one just to double-check your secure binaries. The command says "show everything where you don't find the word ' root '

Code:
-> % ls -l@ /usr/sbin | grep -v ' root '
total 40168
-r-xr-xr-x  1 _uucp  wheel        232768 Jul 29 13:59 uucico
-r-xr-xr-x  1 _uucp  wheel        111216 Jul 29 13:59 uuxqt
 
Here is the result, I hope it will help to solve my problem

It looks like he has extended attributes which were set on sudo. I don't have any on my hackintosh running 10.14.6.

Of course, running sudo xattr /usr/bin/sudo won't help when you can't run sudo. :(

That uid 503 is also a deleted account that was on PkgInfo and Uninstall.app
 
Back
Top