Resolve sudo not working in ubuntu 22.04

kartik goyal
Jan 13, 2024

--

Cause of the bug is command — “sudo chmod -R 755 /” — now sudo, and other command not working
RND — set bit (its a new terminology) with permissions in the file required for sudo file and using advance option in linux we have the root previlage.
Solution — In advance option -> latest kernel recovery mode -> root shell -> chmod u+s /usr/bin/sudo /usr/bin/pkexec
Steps of solution
Click on the start of the pc.
Click esc -> (A black screen appears, with some message)
Click q -> GRUB Menu
Choose Advance Options
Choose Letest kernel (Recovery mode)
Choose Root shell
Enter command — chmod u+s /usr/bin/sudo /usr/bin/pkexec

--

--