Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I tried this command

root@node1:~# usermod -l node1admin serveradmin -d /home/node1admin -m
Usage: usermod [options] LOGIN

It keeps saying I have wrong command. The help provides only the options, doesn't really tell me the format. But where is the problem?

share|improve this question
up vote 4 down vote accepted

Assuming you're trying to change serveradmin's name to node1admin, use this instead:

usermod -l node1admin -m -d /home/node1admin serveradmin

In particular, the name of the user account you're operating on should be last, as the general syntax for usermod is:

usermod [options] LOGIN
share|improve this answer
Thank you it works ! – user1012451 Jul 31 '12 at 4:21

As the usage line explains, the current username (LOGIN) must be the last argument of the command.

share|improve this answer
Thanks. It works :)))))))))))) – user1012451 Jul 31 '12 at 4:21

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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