Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to use sudo on OSX, getting sudo: unknown uid 501: who are you? [closed]

When I type sudo <command> in terminal I get sudo: unknown uid 501: who are you? and when I type su I get su: who are you?

I think I must have changed super user permissions somehow on my personal machine. I'm not able to use sudo commands now, and I've not been able to find any helpful solutions. Do I have to do something with my /etc/passwd file? Can I even modify that?

like image 975
kashkar Avatar asked Dec 06 '16 22:12

kashkar


1 Answers

FWIW - I simply had to install (via restart) the automatic updates that were downloaded and it was fixed. Logging out and back in didn't work.

It appears that simply restarting iterm2 may be sufficient, too, so that's probably a better place to start.

like image 55
s g Avatar answered Oct 18 '22 11:10

s g