07-07-2021, 04:26 AM
Hi, not sure how that could have happened, but it should be easy to fix.
As the error message suggests, you have to set the setuid bit. This is what allows the `sudo` binary to elevate its privileges.
To do so, you need to become root first, and since `sudo` is broken you have to use `su`. After that run the following command:
The error message also says that `sudo` must be owned by uid 0 (root). Yours is owned by uid 0, but the group is set to gid 1000, so you might also want to change that to 0, although it's probably not necessary:
Hope that fixes it.
As the error message suggests, you have to set the setuid bit. This is what allows the `sudo` binary to elevate its privileges.
To do so, you need to become root first, and since `sudo` is broken you have to use `su`. After that run the following command:
Code:
chmod u+s /usr/bin/sudo
The error message also says that `sudo` must be owned by uid 0 (root). Yours is owned by uid 0, but the group is set to gid 1000, so you might also want to change that to 0, although it's probably not necessary:
Code:
chown root:root /usr/bin/sudo
Hope that fixes it.