I have created <username> to log in alternatively in LAMP appliance. However, as I try logging in as root typing sudo su - I receive this error message:

<username> is not in the sudoers file. This incident will be reported.

Solution?

 

Thank you.

 

 

Forum: 

 

# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#

Defaults        env_reset

# Host alias specification

# User alias specification

# Cmnd alias specification

# User privilege specification
root    ALL=(ALL) ALL
  <username> ALL=(ALL) ALL

 

 

Hi look, the above is the visudo file I have added <username> ALL =(ALL) ALL

 

still sudo su doesn't work for my new user, any explanation?

 

Thank you.


I meant <username> = leow

I understand that part, friend. It didn't work.


Thanks, Guest. It's working, I just apt-get update it and re-do. It's working now.

 

Thanks a bunch.

 

:)


1. Log in as Root.

2. type visudo

3. add this

root    ALL=(ALL) ALL
manjot    ALL=(ALL) ALL

4. Save

* Learn how to edit visudo. You need to type 'i' before you're able to edit. After that, 'Esc' and :wq to save and quit.

* Refer to the upper posts, I'm also taught. Unfortunately I don't know his name. He's 'Guest'

 


Clement's picture

Hey leow, you made me think I should create an account :-) so my name is not "Guest" :-)

manjot - did you manage to sort out your problem? make sure you input what leow wrote under

# User privilege specification
root    ALL=(ALL) ALL

before you save & quit. the whole procedure is described above in the post. Naturally you'll need to have control of an administrative account such as root.

Add new comment