After setting new users they get disabled

Discussion in general that pertains to Sabayon Linux - Must Pertain to Sabayon Linux

Moderator: Moderators

Post Reply
jcgg
Young Hen
Posts: 28
Joined: Mon Dec 28, 2009 2:37

After setting new users they get disabled

Post by jcgg » Sun Sep 19, 2010 22:42

Hi,

I am using Gnome and have tried to add new users via the GUI Users and Groups menu. Everytime I setup a new user give the user a password, etc. etc. I then reboot the system and the user's account is disabled. Is there a better way or something else I can do?

Thanks,

xlnagla
Sagely Hen
Posts: 1078
Joined: Mon May 28, 2007 2:44

Re: After setting new users they get disabled

Post by xlnagla » Sun Sep 19, 2010 23:16

define disabled.

If by disabled you mean locked (which is commonly referred to as disabled, so still a valid thing to call it), then chances are either it is password-locked, or it is set to expire 0 days from now. Both can be fixed by using the command: usermod.

Usage:
usermod -U <accountname> (unlocks the account)
usermod -e <expiredate> <accountname> (sets an expiration date for the account).

Usermod requires root privileges, and is a command line application.

~xlnagla

Fitzcarraldo
Sagely Hen
Posts: 8195
Joined: Sat Mar 10, 2007 5:40
Location: United Kingdom
Contact:

Re: After setting new users they get disabled

Post by Fitzcarraldo » Sun Sep 19, 2010 23:30

If that is not the problem then you could delete the inaccessible user accounts (userdel <username>, or userdel -r <userrname> if you want to delete the files in that user's home directory) and use superadduser to create new user accounts (it's in Portage). To install superadduser:

Code: Select all

# emerge --sync
# layman -S
# emerge -1v superadduser
# equo rescue spmsync
The above four commands do the following:
emerge --sync # Synchronise your PC with the Portage main tree ebuild repository (similar to 'equo update' command).
layman -S # Synchronise your PC with the Portage Sabayon ebuild overlay (similar to 'equo update' command).
emerge -1v superadduser # Merge (install) the package.
equo rescue spmsync # Tell Entropy what you did via Portage.

It's easy to use superadduser. Here is an actual example, when I added a new user (which I named "mediacentre") to my media centre nettop:

Code: Select all

$ groups
disk wheel floppy uucp cron audio cdrom dialout video games cdrw usb users haldaemon scanner plugdev entropy pulse-access pulse-rt pulse vboxusers crontab polkituser
$ su
Password: 
# superadduser

Login name for new user []: mediacentre

User ID ('UID') [ defaults to next available ]: 

Initial group [ users ]: 

Additional groups (comma separated) []: disk,wheel,floppy,uucp,cron,audio,cdrom,dialout,video,games,cdrw,usb,haldaemon,scanner,plugdev,entropy,pulse-access,pulse-rt,pulse,vboxusers,crontab,polkituser

Home directory [ /home/mediacentre ] 

Shell [ /bin/bash ] 

Expiry date (YYYY-MM-DD) []: 

New account will be created as follows:

---------------------------------------
Login name.......:  mediacentre
UID..............:  [ Next available ]
Initial group....:  users
Additional groups:  disk,wheel,floppy,uucp,cron,audio,cdrom,dialout,video,games,cdrw,usb,haldaemon,scanner,plugdev,entropy,pulse-access,pulse-rt,pulse,vboxusers,crontab,polkituser
Home directory...:  /home/mediacentre
Shell............:  /bin/bash
Expiry date......:  [ Never ]

This is it... if you want to bail out, hit Control-C.  Otherwise, press
ENTER to go ahead and make the account.


Creating new account...


Changing the user information for mediacentre
Enter the new value, or press ENTER for the default
        Full Name []: mediacentre
        Room Number []: 
        Work Phone []: 
        Home Phone []: 
        Other []: 
New password: 
Retype new password: 
BAD PASSWORD: it is based on a dictionary word
passwd: password updated successfully


Account setup complete.
# id mediacentre
uid=1001(mediacentre) gid=100(users) groups=100(users),6(disk),10(wheel),11(floppy),14(uucp),16(cron),18(audio),19(cdrom),20(dialout),27(video),35(games),80(cdrw),85(usb),411(haldaemon),441(scanner),442(plugdev),1003(pulse-access),1004(pulse-rt),1005(pulse),1009(vboxusers),1010(crontab),1000(entropy),1019(polkituser)
# id fitzcarraldo
uid=1000(fitzcarraldo) gid=100(users) groups=100(users),6(disk),10(wheel),11(floppy),14(uucp),16(cron),18(audio),19(cdrom),20(dialout),27(video),35(games),80(cdrw),85(usb),411(haldaemon),441(scanner),442(plugdev),1003(pulse-access),1004(pulse-rt),1005(pulse),1009(vboxusers),1010(crontab),1000(entropy),1019(polkituser)
#

Sisko43
Growing Hen
Posts: 195
Joined: Sun Mar 29, 2009 12:59

Re: After setting new users they get disabled

Post by Sisko43 » Fri Oct 01, 2010 9:16

When you setup a new user in gnome via gui, etc. be sure that the user-account you're using for setup, is in the group "stb-admin" otherwise the new account will be disabled automatically...

Post Reply