Announcement

Collapse
No announcement yet.

unable to sudo anything. user not in souders file

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [SOLVED] unable to sudo anything. user not in souders file

    so I found some instructions
    1. reboot PC
    2. press escape to get recovery menu
    3. advance options
    4. recovery menu
    5. root drop to root shell prompt
    6. hit <ENTER> for maintenance
    7. mount -o rw,remount /
    8 adduser user sudo This added fine
    9. adduser user admin This error. 'admin group does not exist'

    I will attempt to create an admin group and then add myself to it.

    My user (me) had all the normal groups, then I tried some changes to smb.conf... oh and /etc/hosts ... and suddenly my user is blank. I have 2 groups, myself and adm

    EDIT just as a double check I check myself user on this Main pc, and admin was disappeared and has 'adm' as a group. Is this a new change somewhere in updating??
    Last edited by Snowhog; Sep 29, 2022, 06:55 AM.

    #2
    Do I actually need to be in an 'admin' group?
    Does the 'admin' group exist anymore? Sorry, should it still exist?

    Comment


      #3
      'some instructions' ...... from where, and probably just as important, when? Many pages may be outdated, or for the wrong type of system, or just plain full of incorrect crap.
      'admin' hasn't been used in quite a long time, I believe.

      Start from the beginning:

      What are your exact symptoms? Specific error messages, for example
      What specifically were you doing when you saw the symptoms?
      What sort of changes or edits or config changes have you done since the last time you did something that needed sudo?

      As much info as possible is helpful, as there is always the chance that the errors you see may be a symptom of something else.



      We can quickly see what groups you are in, so show us:

      Code:
      groups
      it should show : your username, adm cdrom sudo dip plugdev lpadmin , and probably sambashare. these are the defaults. sudo is the important one, as you already know. Any changes to these do require a full reboot, even from the recovery shell, iirc, so if sudo isn't showing, and you haven't rebooted, go ahead and try doing so.
      ​,

      Comment


        #4
        Originally posted by claydoh View Post
        'some instructions' ...... from where, and probably just as important, when? Many pages may be outdated, or for the wrong type of system, or just plain full of incorrect crap.
        'admin' hasn't been used in quite a long time, I believe.
        Thanks for this. I haven't looked at groups for yonks and I know admin was listed

        Originally posted by claydoh View Post
        Start from the beginning:

        What are your exact symptoms? Specific error messages, for example
        What specifically were you doing when you saw the symptoms?
        What sort of changes or edits or config changes have you done since the last time you did something that needed sudo?

        As much info as possible is helpful, as there is always the chance that the errors you see may be a symptom of something else.



        We can quickly see what groups you are in, so show us:

        Code:
        groups
        it should show : your username, adm cdrom sudo dip plugdev lpadmin , and probably sambashare. these are the defaults. sudo is the important one, as you already know. Any changes to these do require a full reboot, even from the recovery shell, iirc, so if sudo isn't showing, and you haven't rebooted, go ahead and try doing so.
        ​,
        OK. I was changing the contents of /etc/hosts to include all my computers. When I went to save it, I normally get a "Authentication" prompt for myuser (admin & only user) account. Well I kept getting error, that the password was not accepted and not in a list of sudoers.
        I Giggled the sudoers and found what I mentioned above.
        I followed those instructions, and it all worked. Myuser account is back to include groups of sudo, & adm and all the others you mentioned. The only problem is how did myuser account lose all it's admin privileges in the first place. All I had been doing was attempting to get samba working properly. I never entered any commands that would affect users or groups. The only one I did was add myuser to sambashare group. That's it.

        ALL FIXED.

        Comment


          #5
          I am completely lost.

          So the problem was on a remote system then?

          What fixed things?

          Comment


            #6
            problems where on a second computer. I have two.
            The problems were fixed the issue by the instructions in the first post https://www.kubuntuforums.net/forum/...ile#post665325
            does this help?

            Comment

            Working...
            X