You are not logged in.

#1 2021-01-23 12:21:35

860lacov
Member
Registered: 2020-05-02
Posts: 497

[SOLVED] What did I mess with users management?

Arch - KDE

I have one user - jm
groups - vboxusers wheel jm

First. I don't understand why when I type users command the output is:
jm jm jm
(not a big problem but I would like to know why 3 times jm and not only one jm)

I wanted to add another user - mag_ja

I did

usaradd -mG vboxusers wheel mag_ja

home for a new user was created.
After logout from jm there were 2 accounts: jm and mag_ja  but I couldn't log in into mag_ja
In sddm there was an information that password for mag_ja is wrong.

I thought that It is necessary to add this password so under jm account I did

sudo passwd mag_ja 

I set password to 1 but... after logout I couldn't log in into jm nor mag_ja account

Timeshift helped. After restore there wasn't mag_ja account and my account password is working.


At the end what I wanted to achieve.
In jm home folder I have virtualbox machine. I would like to share it with another account.
I wanted to change its owner from jm jm to jm vboxusers
Create mag_ja account and assign it to group wheel and vboxusers
Configure virtualbox to have acces to machine on jm account

Last edited by 860lacov (2021-01-23 13:57:06)

Offline

#2 2021-01-23 12:32:46

loqs
Member
Registered: 2014-03-06
Posts: 19,025

Re: [SOLVED] What did I mess with users management?

860lacov wrote:

First. I don't understand why when I type users command the output is:
jm jm jm
(not a big problem but I would like to know why 3 times jm and not only one jm)

The user jm was logged in three times,  see man 1 users.

860lacov wrote:

I wanted to add another user - mag_ja

I did

usaradd -mG vboxusers wheel mag_ja

Did you miss the comma between vboxusers and wheel?  I would have expected the command to fail otherwise.

860lacov wrote:

home for a new user was created.
After logout from jm there were 2 accounts: jm and mag_ja  but I couldn't log in into mag_ja
In sddm there was an information that password for mag_ja is wrong.

I thought that It is necessary to add this password so under jm account I did

sudo passwd mag_ja 

I set password to 1 but... after logout I couldn't log in into jm nor mag_ja account

Timeshift helped. After restore there wasn't mag_ja account and my account password is working.

Do you have the journal for failed login or was the wiped with the use of timeshift?

Last edited by loqs (2021-01-23 12:33:04)

Offline

#3 2021-01-23 12:40:20

860lacov
Member
Registered: 2020-05-02
Posts: 497

Re: [SOLVED] What did I mess with users management?

My mistake in post creation.
The command was:

usaradd -mG vboxusers,wheel mag_ja

Even tho I don't fully understand how to user journal I believe that logs are placed in a different from /home location so timeshift wiped them.

If

usaradd -mG vboxusers,wheel mag_ja

Is a good way to add mag_ja user than I can repeat it without playing with passwd.

If you could tell me how can I find information that you need I'll try to post it here.

Last edited by 860lacov (2021-01-23 12:42:23)

Offline

#4 2021-01-23 12:57:55

loqs
Member
Registered: 2014-03-06
Posts: 19,025

Re: [SOLVED] What did I mess with users management?

That would create the user mag_ja with the passwd disabled so you can not log in to that account.
For the journal see Systemd/Journal#Filtering_output to filter the journal for the current boot.

Offline

#5 2021-01-23 13:00:22

860lacov
Member
Registered: 2020-05-02
Posts: 497

Re: [SOLVED] What did I mess with users management?

Ok.
So how can I create enabled account mag_ja without any password?

Offline

#6 2021-01-23 13:08:08

loqs
Member
Registered: 2014-03-06
Posts: 19,025

Re: [SOLVED] What did I mess with users management?

You do as you did intially set the passwd for mag_ja after the user is created with passwd.
If you are worried about a repeat of the issue,  leave a session logged in as root on a different tty.

Offline

#7 2021-01-23 13:56:44

860lacov
Member
Registered: 2020-05-02
Posts: 497

Re: [SOLVED] What did I mess with users management?

Ok
Thank you
I did usaradd -mG vboxusers mag_ja
Changed password for mag_ja and this time it worked.

Offline

Board footer

Powered by FluxBB