[ale] ubuntu create another user and remove old user
david at systemoverlord.com
Mon Feb 28 21:01:41 EST 2011
On 02/28/2011 08:48 PM, Wolf Halton wrote:
> On 02/28/2011 08:15 PM, Narahari 'n' Savitha wrote:
>> 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 ?
> #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.
To be clear, sudo doesn't care what application you use to edit it. The
significance of using visudo is that it edits a copy of the file and
verifies the syntax of the file prior to replacing /etc/sudoers with the
new version. This is significant because, if /etc/sudoers is
syntactically incorrect, sudo refuses to allow ANYONE to sudo. (This is
not a bug; it's an important security feature.)
> $ id devpid
> output shows the groups devpid is a member of. 'admin' should be one of
> those groups.
> # groupadd wheel
I'm not sure why you'd want to add a new group named wheel. Ubuntu
creates an "admin" group in /etc/sudoers in all installs.
> then add you user to the new admin group
> # usermod -a -G admin devuser
More information about the Ale