Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Hi I am not very experienced with user management in ubuntu. I needed to create a new user to manage my application server so following some instructions online, this is what i did:

I became root

sudo -i

I added a group

addgroup jbossgroup

I added a user and assigned it to a group

useradd -g jbossgroup jboss

I created a password

passwd jboss

Then I changed the ownership of a folder to check that the user was correctly created and that working fine.

chown jboss:jbossgroup /opt/jboss-as-7.1.1.Final/ -R

I made this user sudoer

gpasswd -a jboss sudo

But i think this is not working since when I use mkdir or rm... in a folder owned by root, i have to type sudo.(Did i do this step correctly?)

The next thing I noticed was that when i changed to the newly created user, the terminal only displayed this:


So I fixed that by doing this as the jboss user:

chsh -s /bin/bash

I have some doubts

  • Did I correctly create this user and is it safe to work with it?

  • Why the name of the user doesn't appear in the drop down menu when I click the shutdown button(Next to the time in the top right corner of the screen)?

  • Also I noticed that in the home folder there is not a jboss folder. Why this was not created?

  • What other features this user might be missing?

share|improve this question

closed as not a real question by Takkat, Rafał Cieślak, Jorge Castro, Thomas W., Ringtail Jan 7 '13 at 0:02

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

Rather than with useradd you should create a new user with adduser. See e.g. askubuntu.com/questions/139304/…, askubuntu.com/questions/54992/… –  Takkat Jan 6 '13 at 15:00

1 Answer 1

up vote 1 down vote accepted

You could have achieved your goal in only three steps:

sudo adduser jboss

sudo passwd jboss you have to supply the password :)

sudo adduser jboss sudo adds jboss to the group sudo

And please be aware that gpasswd is the wrong tool to add a user to a group!

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.