You are not logged in.
Pages: 1
Hi everyone, noob here.
This morning i merged /etc/sudoers and /etc/sudoers.pacnew with 'sudo pacdiif'.
I believed the merge preserve my user. Unfortunately not.
So now i can't 'visudo'.
i can't 'sudo'
i can't log as root('su') because i disabled the root account...
how can i fix my mistake ?
thanks
Last edited by jc@arch (2022-03-13 11:16:38)
Offline
Try booting to rescue.target.
https://wiki.archlinux.org/title/System … _boot_into
Either that or boot with the install media and edit the file from there.
You should always manually inspect every .pacnew merge. If there was no difference in the file to be replaced then a .pacnew wouldn't have been created in the first place.
Offline
If you have polkit installed and your user is configured as an administrator (i.e. in the wheel group by default), you may be able to use pkexec to run visudo as root.
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
it worked. lesson learned !
pkexec pacman -S vi
pkexec visudo
thanks.
Offline
Pages: 1