RandomCoderOrg/ubuntu-on-android

/etc ownership changes to current user

404invalid-user opened this issue · 3 comments

i am following https://udroid-rc.gitbook.io/udroid-wiki/using-udroid/non-root-users with jammy:xfce4 when i login with su <username> and do sudo blabla i get:

sudo: /etc/sudo.conf is owned by uid 1000, should be 0
sudo: The "no new privileges" flag is set, which prevents sudo from running as root.
sudo: If sudo is running in a container, you may need to adjust the container configuration to disable the flag.

and if i am logged in as user and do ls -al /etc all files are owned by my user but if i log in as root again they are owned by root

i have tried doing chown root:root /etc/sudo.conf but that does not work its still owned by my user

downgrade sudo

apt remove sudo
wget http://ports.ubuntu.com/pool/main/s/sudo/sudo_1.8.31-1ubuntu1_arm64.deb
dpkg -i sudo_1.8.31-1ubuntu1_arm64.deb

change arm64 to armhf if you're on 32-bit

I'll have a go at that now