• Help! I Can't Use "sudo" Command Anymore!


    I was using my Manjaro partition earlier and was trying to edit some files on a flash drive. Since I had changed the ownership of the /run/media/ directory to my current user I had to change it back to Root to access my files. What I forgot about however was that I had my Antergos GNOME partition mounted and I accidentally changed the ownership of my entire Antergos partition to Root and when I started up my Antergos again it had an error and took a long time to boot. When it finally did boot I could not log into my account anymore. I got back on my Manjaro KDE partition and changed the ownership of the /home/caden/ directory to my account on Manjaro (which was the same username and password) which seemed to fix my problem. I could now log in again but oddly all of my icons had changed from Numix UTouch to the GNOME default icons. I wanted to install a package from an official repository so I went to the terminal and typed in the ```
    sudo
    command but I recieved this message:

    [[email protected] ~]$ sudo pacman -S (package)
    sudo: /usr/bin/sudo must be owned by uid 0 and have the setuid bit set
    [[email protected] ~]$
    

    I now can’t use the sudo command and I can’t even use it in tty. Can anyone help? ;)

    ;)

  • this looks like a great permission mess to me…
    Need to change back all permissions not only home directory…

    [updates once a week] = [90% less problems]
    [Li{u}n//u//{i}x] since 1988 - overcoming failure means success
    http://kamprad.net/howto-installing-antergos/
    https://forum.antergos.com/topic/1883/how-to-include-system-logs-when-asking-for-help

  • @joekamprad Okay. I was going to but I have a really bad problem now: i can’t use the sudo command in sudo chown root -v /[directory]/ because I can’t use the “sudo” command. I also for some reason can’t do su - to change to root to do
    chown root -v /[directory]/ command. I’m at a loss with what to do at this point. Is there any way that I can at least get the “sudo” command back?

    ;)

  • @joekamprad If he rollback the entire sytem to a X day will the system “recover” all the old file permissions?

    Antergos (default OS) - WIN10 (abandoned)
    I3wm - Mate desktop
    AMD - A4 7300 Radeon graphics
    16 GB ram
    HD 1 TB
    Linux newbie since 06/2016

  • @fernandomaroto this would need some backups…

    @CadenMitchell >> Posix permissions are straight! there’s a multitude of places in the filesystem where wrong permissions would break the OS, or even worse…

    Backup your personal data, make the two packagelists as i show here:
    ----backup a packages list with all packages from your actual system, but be carefull with AUR packages, you will need to do two lists one for repository packages and one for AUR packages, otherwise it will be a mess…

    pacman -Qqen > packages-repository.txt
    pacman -Qqem > packages-AUR.txt
    

    Reinstall Antergos and rollback your installed programms:

    sudo pacman -S $(cat packages-repository.txt)
    yaourt -S $(cat packages-AUR.txt)
    

    [updates once a week] = [90% less problems]
    [Li{u}n//u//{i}x] since 1988 - overcoming failure means success
    http://kamprad.net/howto-installing-antergos/
    https://forum.antergos.com/topic/1883/how-to-include-system-logs-when-asking-for-help

  • @joekamprad Thank you. I wish it didn’t have to be this way. :( If that’s what must be done, then it must be done. :sob:

    ;)

  • @CadenMitchell you are on Antergos new install is done in just 34 minutes ;)

    [updates once a week] = [90% less problems]
    [Li{u}n//u//{i}x] since 1988 - overcoming failure means success
    http://kamprad.net/howto-installing-antergos/
    https://forum.antergos.com/topic/1883/how-to-include-system-logs-when-asking-for-help

  • @joekamprad It’s hard to me to understand what was broken, but in case he managed to restore (that’s easy using the live CD anyway) the /home partition permissions but not the /root; then he could reinstall the system without formating /home…
    Maybe he already reinstalled the system now… Just hope he fixes everything…

    Antergos (default OS) - WIN10 (abandoned)
    I3wm - Mate desktop
    AMD - A4 7300 Radeon graphics
    16 GB ram
    HD 1 TB
    Linux newbie since 06/2016

  • @fernandomaroto No. I haven’t reinstalled yet. I was hoping that I might be able to reinstall certain components through the live USB like the main system directories and wherever there are areas that require root privileges. Maybe I could keep my home and application directories that have all of my application data but reinstall everything else.

    ;)

  • @CadenMitchell Yes i guess you can keep /home, since the files there doens’t need high priviliedges… So just resintalling the /root seems fine to me. (but i’m newbie, let’s wait for someone with more knowledge)

    Antergos (default OS) - WIN10 (abandoned)
    I3wm - Mate desktop
    AMD - A4 7300 Radeon graphics
    16 GB ram
    HD 1 TB
    Linux newbie since 06/2016

  • Yes! I have been using Linux for almost a year, but know nothing about it! ;)

    ;)

  • you can keep home with personal app configs e.t.c. but there is too some stuff that causes conflicts like the keys for user will change after new installation

    [updates once a week] = [90% less problems]
    [Li{u}n//u//{i}x] since 1988 - overcoming failure means success
    http://kamprad.net/howto-installing-antergos/
    https://forum.antergos.com/topic/1883/how-to-include-system-logs-when-asking-for-help

  • @joekamprad Right now I don’t mind too much about my applications. I have backed all of my files on my other partition. I was told that I should try out another distro. For the time being I might continue it as it’s using a modified GNOME DE. It’s good for right now but I don’t see myself using it for much longer. While Zorin is great, it’s also based on Ubuntu which has confusing commands. It also has some issues with my multiple batteries, and for some reason has a very hard time installing updates. The only reason why I’m using it right now is because it looks nice and nothing more. I really wish I could make Antergos look the same. Anyways, I’ll probably be switching back to Antergos very soon as Zorin is much to hard to use sometimes. I even got the Ultimate edition which is paid for. You’d think it would work better if you had to pay for it. ;n;

    ;)

  • Hi,

    Sorry I’m late to this thread, but I will add my two cents in case somebody else has a similar problem.

    You should have booted with the Antergos ISO and chroot to your system (https://wiki.archlinux.org/index.php/change_root) then, you would had been able to change all your file permissions.

    Cheers!

sudo10 gnome202 error167 manjaro8 Posts 15Views 519
Log in to reply