[SOLVED] adduser fail?

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
JeSuisFlaneur
Posts: 44
Joined: 2019-08-28 16:00

[SOLVED] adduser fail?

#1 Post by JeSuisFlaneur »

Clean install. Tried to use su - to add sudo. Terminal returns sudo already added.

Code: Select all

mark@Lexington:~$ sudo deja-dup
[sudo] password for mark: 
mark is not in the sudoers file.  This incident will be reported.

mark@Lexington:~$ id
uid=1000(mark) gid=1000(mark) groups=1000(mark),24(cdrom),25(floppy),29(audio),30(dip),44(video),46(plugdev),109(netdev),112(bluetooth),116(lpadmin),117(scanner)

mark@Lexington:~$ sudo deja-dup
[sudo] password for mark: 
mark is not in the sudoers file.  This incident will be reported.
I tried using an response at https://stackoverflow.com/questions/478 ... e-reported. visudo and add my user credentials per that page, but it failed.

I cannot run deja-dup to restore my backup'd files to /home partition. Anybody know what I did wrong? Help, please.
Last edited by JeSuisFlaneur on 2020-06-17 16:18, edited 1 time in total.

andre@home
Posts: 398
Joined: 2011-10-02 08:00

Re: adduser fail?

#2 Post by andre@home »

Sometimes you have to logout and then login again when you just did some changes for the user you were logged in.
Workaround: do it as root...
https://www.linuxuprising.com/2019/09/f ... -file.html

JeSuisFlaneur
Posts: 44
Joined: 2019-08-28 16:00

Re: adduser fail?

#3 Post by JeSuisFlaneur »

I did log out and log in.

Terminal output AFTER the log-out/in

Code: Select all

mark@Lexington:~$ groups
mark cdrom floppy audio dip video plugdev netdev bluetooth lpadmin scanner
mark@Lexington:~$ sudo apt update
[sudo] password for mark: 
mark is not in the sudoers file.  This incident will be reported.
mark@Lexington:~$ su -
Password: 
root@Lexington:~# apt install sudo
Reading package lists... Done
Building dependency tree       
Reading state information... Done
sudo is already the newest version (1.8.27-1+deb10u2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@Lexington:~# exit
logout
mark@Lexington:~$ id
uid=1000(mark) gid=1000(mark) groups=1000(mark),24(cdrom),25(floppy),29(audio),30(dip),44(video),46(plugdev),109(netdev),112(bluetooth),116(lpadmin),117(scanner)
mark@Lexington:~$ whoami
mark
mark@Lexington:~$ sudo apt update
[sudo] password for mark: 
mark is not in the sudoers file.  This incident will be reported.

cuckooflew
Posts: 681
Joined: 2018-05-10 19:34
Location: Some where out west

Re: adduser fail?

#4 Post by cuckooflew »

Show us your actual sudoers file, so we can see what you actually did, use code boxes please, the instructions in that link are rather mixed up, so it is impossible to guess what you actually did.
But ,

Code: Select all

user_name ALL=(ALL)  ALL 

*****important: "user_name", is your user name: eg: if I used it, mine would be:

Code: Select all

cuckooflew ALL=(ALL)  ALL 
Is correct, that is what you should add, DO NOT use nano, or any random text editor, like they said.
You must use 'visudo' , and you must be root to do this.
Can you log in as root ? I hope you did set a root password when you intsalled, if not then we need to explain that as well, use

Code: Select all

$su -
$ password: (enter the root password you set when installing) 

Note: For others as well, this is one reason you should all ways be sure to set a root password when installing.
by JeSuisFlaneur »I cannot run deja-dup to restore my backup'd files
Actually if you can log in as root, using

Code: Select all

 su - 
you should be able to run it as root, personally I think "sudo" and sudoers is a bunch of crap, I do not use that myself, but any way the others "follow the crowd" do, and that is another topic, sorry.
So any way, after you login as root, type :

Code: Select all

#  visudo /etc/sudoers 
Then edit it as needed, save and exit. I think you may need to logout and login again, first but don't remember.
There is better tutorials and documentation on this at the Debian.org website, and the Debian wiki, use some search foo to find it... I will do that for you, in a little while,...first I need to take some medicine, and then I will be back. Or maybe some one else will post the links, I never can remember them, so allways have to do some search foo my self.
Please Read What we expect you have already Done
Search Engines know a lot, and
"If God had wanted computers to work all the time, He wouldn't have invented RESET buttons"
and
Just say NO to help vampires!

Bulkley
Posts: 6146
Joined: 2006-02-11 18:35

Re: adduser fail?

#5 Post by Bulkley »

cuckooflew wrote: . . . personally I think "sudo" and sudoers is a bunch of crap . . .
+1.

JeSuisFlaneur
Posts: 44
Joined: 2019-08-28 16:00

Re: adduser fail?

#6 Post by JeSuisFlaneur »

I requires more than log out and log in.

I rebooted. Now it works.

Thank you for taking your time to stay with me. Thank you, Linux Community.

User avatar
RU55EL
Posts: 539
Joined: 2014-04-07 03:42
Location: /home/russel

Re: adduser fail?

#7 Post by RU55EL »

Please add [SOLVED] to the subject of your first post.

Post Reply