Results 1 to 7 of 7

Thread: sudoers error & ubuntu server recovery mode

Hybrid View

  1. #1
    Join Date
    Oct 2011
    Beans
    3

    Question sudoers error & ubuntu server recovery mode

    Greetings -- I (and all other admin group members) can no longer run sudo on Ubuntu Server 10.04 LTS as we receive the following group ID error:

    "/etc/sudoers is owned by gid 113, should be 0"

    How can we replace the file sudoers with one with correct permissions? A quick search suggests that recovery mode is the only way, though I'd need to convey appropriate instructions to my IT people as I don't have physical access to the (virtual) server and have no idea how it's done in Ubuntu Server.

    Many thanks,

    Jim

  2. #2
    Join Date
    Apr 2011
    Beans
    25

    Re: sudoers error & ubuntu server recovery mode

    Only possible with physical access, UNLESS you can find someone who is a member of group 113 and do it from their account (they should have SUDO access).

  3. #3
    Join Date
    May 2010
    Location
    Tewkesbury uk
    Beans
    7,660
    Distro
    Ubuntu Development Release

    Re: sudoers error & ubuntu server recovery mode

    Hi

    Quote Originally Posted by doctorproctor View Post
    Greetings -- I (and all other admin group members) can no longer run sudo on Ubuntu Server 10.04 LTS as we receive the following group ID error:

    "/etc/sudoers is owned by gid 113, should be 0"

    How can we replace the file sudoers with one with correct permissions? A quick search suggests that recovery mode is the only way, though I'd need to convey appropriate instructions to my IT people as I don't have physical access to the (virtual) server and have no idea how it's done in Ubuntu Server.

    Many thanks,

    Jim
    Did somebody chown the sudoers files ? Did they change the ownership of any other system files ?

    I would be concerned what other system files may have changed.

    You may need to boot into a LiveCD/USB to change it back after mounting it .

    Code:
    chown 0:0 <mount_point>/etc/sudoers
    Make sure the permissions are 440

    Code:
    chmod 440 <mount_point>/etc/sudoers
    As i said before though, have the permissions of any other system file changed ?
    You need to find out how this happened.

    Out of interest which group is 113 ?

    Code:
    grep 113 /etc/group
    Kind regards
    Last edited by matt_symes; October 8th, 2011 at 09:06 AM.
    Join us on irc at #ubuntuforums. For web chat see here

    If you believe everything you read, you better not read. ~ Japanese Proverb

    Do not read newspapers on an empty stomach ~ Russian Proverb ~ BrunoLotse

  4. #4
    Join Date
    Oct 2011
    Beans
    3

    Arrow Re: sudoers error & ubuntu server recovery mode

    Thanks for your replies so far. Group id 113, I believe, is admin: I and one other user are in 113, there are no other users, and neither of us can use sudo at present; apparently, /etc/sudoers requires owner and group to be root and root (0:0) in order for sudo to work (!).

    This mistake was made via an errant recursive chgrp applied to /etc/; not sure how critical this is for other files in /etc/ in addition to sudoers (presumably it stopped after sudoers file changed?). We see no other problems to the system, nothing in the error logs, etc. so far.

    I studied info on LiveCD booting, but this seems to apply to desktop vs. server Ubuntu: will this work for server? (I believe our IT people are running virtual servers.)

    Thanks again,

    Jim
    Last edited by doctorproctor; October 8th, 2011 at 10:45 AM.

  5. #5
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: sudoers error & ubuntu server recovery mode

    Depending on who you chgrp'd them to, it could cause problems down the road.

    Anyhow - boot into recovery mode (hold down shift at the grub screen and select recovery mode) and chown it back to root:

    Code:
    chown root:root /etc/sudoers
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  6. #6
    Join Date
    Oct 2011
    Beans
    3

    Re: sudoers error & ubuntu server recovery mode

    Thanks again. So, is there an Ubuntu utility to check/fix file permissions (including owner/group)? Alternatively, would these permissions be updated during upgrade to 11.04?

    Regards,

    Jim

  7. #7
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: sudoers error & ubuntu server recovery mode

    I don't know of any utility to fix the permissions. I'd say so a reinstall so you know the permissions are correct and be more careful in the future.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •