26.1 C
Cuttack
Sunday, September 19, 2021
HomeLinuxSolution: sudo /usr/bin/sudo must be owned by uid 0 and have the...

Solution: sudo /usr/bin/sudo must be owned by uid 0 and have the setuid bit set

sudo /usr/bin/sudo must be owned by uid 0 and have the setuid bit set

Got stuck by this error in Ubuntu 14.4 which is really painful as without sudo you cannot move forward … it will not allow you to do anything.

Solution:- Get in to Ubuntu Recovery Console
Start your computer and press and hold SHIFT key while booting. It will take you to the grub loader page as shown in image – 1.

Grub loader Page
Image – 1 Grub loader Page

Select and enter Advanced options for Ubuntu and from there select the kernel named as recovery mode as shown in image – 2.

image2
Image – 2

select root – drop to root shell prompt as shown in image – 3

Image - 3
Image – 3

Now the file system is read only to Remount to Read Write run below command
# mount -o remount,rw /
# mount –all

then need to change the ownership for sudo
# chown root:root /usr/bin/sudo

give permisson for sudo
# chmod 4755 /usr/bin/sudo

it’s done … let’s see by restarting the machine
# shutdown -r now

Hopefully now you have solved the issue and sudo is working fine …

You may also like: Install and configure Jasper Report Server on Ubuntu Server

Durga Charan Ojhahttps://lifeonnetwork.com/
I am a proud Indian, proud father, a blogger, Being in a profession as System administrator, my passion is troubleshooting computer issues, I do like sharing solutions through blogging making videos of solving issues.
RELATED ARTICLES

2 COMMENTS

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular