How do I add a user in Ubuntu? [closed]

纵饮孤独 提交于 2019-11-28 14:35:42

问题


Specifically, what commands do I run from the terminal?


回答1:


Without a home directory

sudo useradd myuser

With home directory

sudo useradd -m myuser

Then set the password

sudo passwd myuser

Then set the shell

sudo usermod -s /bin/bash myuser



回答2:


Here's the command I almost always use (adding user kevin):

useradd -d /home/kevin -s /bin/bash -m kevin



回答3:


There's basicly 2 commands to do this...

  • useradd
  • adduser (which is a frendlier front end to useradd)

You have to run them has root. Just read their manuals to find out how to use them.



来源:https://stackoverflow.com/questions/38288/how-do-i-add-a-user-in-ubuntu

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!