[ale] ubuntu create another user and remove old user

John Scott John.Scott at peak10.com
Mon Feb 28 21:00:06 EST 2011


Narahari wrote:

"I want to be able to make this new user devuser the only user and removed devpid.  Also I want to give devuser the rights to be sudo."


Narahari,

The quickest is to become root and make your changes:

$ sudo su -
# /usr/sbin/usermod -l devuser devpid

This will change the devpid login's username to devuser.

If you want to change the home directory name as well, add the following steps:

# mv /home/devpid /home/devuser
# /usr/sbin/usermod -d /home/devuser devuser

Not that it matters much, but you can consolidate to three commands by adding the -d option in the command above to the first usermod you did to change the username.

-John




From: ale-bounces at ale.org [mailto:ale-bounces at ale.org] On Behalf Of Wolf Halton
Sent: Monday, February 28, 2011 8:48 PM
To: Atlanta Linux Enthusiasts
Subject: Re: [ale] ubuntu create another user and remove old user

On 02/28/2011 08:15 PM, Narahari 'n' Savitha wrote: 
Friends:

I have created a user called devpid and it is the only user account in Ubuntu 10.10.

I selected the autologin option for this user devpid and when I do sudo, the password used for this devpid user works.

Now I need to create user called just devuser instead of devpid.

I want to be able to make this new user devuser the only user and removed devpid.  Also I want to give devuser the rights to be sudo.

How do I do that in Ubuntu ?

-Narahari



_______________________________________________
Ale mailing list
Ale at ale.org
http://mail.ale.org/mailman/listinfo/ale
See JOBS, ANNOUNCE and SCHOOLS lists at
http://mail.ale.org/mailman/listinfo
#sudo vi /etc/sudoers

When sudoers opens, check if there is a group shown as a sudoers group 'admin' is the one on my machine.  The sudoers file says it can be edited only with the visudo program.  I have never had any issues editing it with vi.

$ id devpid

output shows the groups devpid is a member of.  'admin' should be one of those groups.

# groupadd wheel
then add you user to the new admin group

# usermod -a -G admin devuser 


The last line I found on (http://www.cyberciti.biz/faq/howto-linux-add-user-to-group/) 




More information about the Ale mailing list