Questions tagged [useradd]
The useradd tag has no usage guidance.
1
vote
1answer
35 views
useradd -g option doesn't seem to be working
I tried:
sudo useradd -s "/bin/false" -g [existingGroupName] [userNameToAdd]
After the command I looked it up in /etc/group, but the user is not in the [existingGroupName]. Why is that so?
1
vote
1answer
170 views
.bashrc and .bash_profile not created with adduser but created with useradd [duplicate]
I am adding a user named 'test' in my Ubuntu 18.04 server. When I add the user using adduser, like this:
sudo adduser --system --group test --shell /bin/bash
all goes well, I can login fine, but ....
1
vote
2answers
94 views
How much disk space is assigned to a new user in ubuntu?
If I create a new user test1 using the adduser/useradd command, how much space does Ubuntu assign to the test1 user?
What happens when I have 10 users on my system? Do all of them use the same amount ...
1
vote
1answer
177 views
Running useradd with shell_exec
After trying to give permissions to /etc/passwd, the useradd command wont execute from php's shell_exec();
I also tried to visudo and change passwd's owner, the error is still
useradd: Permission ...
6
votes
2answers
1k views
Difference between adduser and usermod -G -a
What is the difference between
adduser user_name group_name
and
usermod -G -a user_name group_name
At first glance they seems to do the same thing : add a user to a group.
0
votes
0answers
31 views
useradd for no home and no loging [duplicate]
I want to make an user that have no home folder and no login ability.
sudo useradd -s /bin/false [demouser]
I omitted -m parameter since that makes the home folder for the demouser.
I did -s /bin/...
11
votes
4answers
3k views
programmatically clone /etc/skel for new users
/etc/skel is a folder that will be cloned for new users. Is there a possible way that we can define rules what to copy from /etc/skel folder?
For example, I'm looking for a way that if a user is ...
3
votes
1answer
441 views
user created unable to login [duplicate]
I created a user in terminal by
useradd xyz
I'm able to log in from the terminal but not in the GUI.
What is wrong?
3
votes
1answer
719 views
Running as a host user within a Docker container
In my team we use Docker containers to locally run our website applications while we do development on them.
Assuming I'm working on a Flask app at app.py with dependencies in requirements.txt, a ...
0
votes
0answers
690 views
How to change the default home directory?
On a server, I have mounted a big drive on /home2 in order to store all the user accounts.
Supposedly in order to set the default directory to /home2, we are supposed to edit /etc/default/useradd
...
1
vote
0answers
982 views
User is not in passwd and shadow file but when getent passwd user it shows
User is not in /etc/passwd and /etc/shadow file but when I "getent passwd userSec" it shows the account details.
[root@myServer systemadmin]# getent passwd userSec
userSec:...
3
votes
1answer
144 views
Removing and adding user back again doesn't remove it properly [duplicate]
If I, as a root user, add user milos, then the system asks me to provide some info, which I do.
When I, after that, userdel milos, it removes it and removes milos group.
Now, if I'm to useradd ...
0
votes
2answers
515 views
How to add current date or current time stamp to a manual useradd script?
This script I made is manually creating a user by taking in only the name the user wants to use. I'm currently trying to add the current date or current time stamp when the user is created in the ...
2
votes
0answers
310 views
useradd ignores defaults in /etc/default/useradd
FTP Migration. Moving the FTP server from Windows to Ubuntu, and rebuilding the storage for FTP on a different server. I'm doing a one time pass to create about 100 users, all with the same password,...
2
votes
2answers
1k views
How to add System user that not be shown in lightdm login screen window or User Accounts?
I want to create an user with no login, no home and that not be shown in lightdm login screen window or User Accounts tool. Just like others users in /etc/passwd: sshd, syslog, avahi...
I've tried ...
1
vote
2answers
54 views
Diff between 2 ways changing useradd defaults
I'm trying to change the useradd default shell, so when the next new user created its shell would be /usr/sbin/tcsh.
One way doing that is by running the following command :
useradd -D -s /usr/...
0
votes
1answer
106 views
the system doesn't read .bashrc and .profile of a user in Ubuntu14.04
Recently I added a new user to linux 14.04, user2, but the home directory of user2 is NOT in /home/user2, I've put it in different place, lets call it home2.
useradd -d home2 user2
I already had an ...
0
votes
0answers
253 views
Unable to login to default account after creating new account in ubuntu 16.04
I was trying to install cassandra in my local machine following this article
I created new group and user using the following commands as suggested in the article.
root@ubuntu:~# groupadd cassandra
...
2
votes
2answers
75 views
Why do I not have any directory except 'home' with new user? [duplicate]
I created a new non-root user and did the following:
useradd -m newusername
passwd newusername
usermod -a -G sudo newusername
chsh -s /bin/bash newusername
I need to install software as a non-...
1
vote
1answer
1k views
User add and shell script with password
I know how to use the useradd comand but would like to make a shell script to automate the process so how would I put the users input to the password part which is a dialog presented after I have ...
-1
votes
1answer
431 views
Encrypting of /etc/shadow file
When I add a user by -useradd command, if I go to /etc/shadow the password isn't encrypted, and therefore I cannot login to that user. How can I encrypt that password in shadow file?
1
vote
3answers
2k views
How do I encrypt a new user's password using the useradd command?
I would like to create an encrypted login password for a new user while using the useradd command in the CLI. I know that using option -p will allow me to create a password, but using this option does ...
10
votes
1answer
13k views
How to create new user with Public key authentication?
I have Ubuntu Server 14.04 LTS. I have Public key authentication enabled by default.
I used the following command to create new user:
sudo useradd -m -c "John T." john -s /bin/bash
The command ...
16
votes
1answer
49k views
what is the default password when you create new user in ubuntu?
I have created a new user by using useradd command e.g.:
sudo useradd acreddy
Then new user is created but it is asking for a password what is the password?
0
votes
1answer
953 views
useradd command in linux not working as expected?
I tried to change default shell in Ubuntu 14.04 using the following command
user@MyUbuntu:~$ sudo useradd -D -s /bin/tcsh
user@MyUbuntu:~$ sudo useradd -D
GROUP=101
HOME=/home
INACTIVE=-1
EXPIRE=
...
3
votes
2answers
18k views
password does not work with useradd -p
I am running ubuntu 14.04 LTS. I ran the following command to create a user
$sudo useradd -m -p password1 guest_user
and then tried to switch to the user with
$su guest_user
But i could not login ...
1
vote
0answers
999 views
create multiple users from csv file and communicate them the password
I have to create multiple users in an Ubuntu environment from a csv file that lists their names and password. I am using the following tutorial
Import users from CSV file
But I am not been able to ...
16
votes
5answers
71k views
Ubuntu 14.04: New user created from command line has missing features
I am trying to create a new user in Ubuntu 14.04 LTS from the bash command line. I use the following commands:
sudo useradd -c "Samwise the Brave" sam
sudo passwd sam
Enter new UNIX password: ...
1
vote
3answers
4k views
How to login with new user and fix error : “: No such file or directory”?
I created a user with root access
useradd -ou 0 -g 0 myuser -p [12345]
when I try to su to the new user, I get:
: No such file or directory
when I want to connect as that user via ssh, I get:
...
1
vote
2answers
966 views
I'm unable to add password to newly created user
I just created a new account with Administrator privileges but cannot set up the password to activate account. I don't know how to set-up the account password via terminal.
0
votes
1answer
1k views
Unable to create and delete an user account in the PC
When I try to create a new user account with command sudo adduser test-ser, I receive this error:
sudo adduser test-user
Adding user test-user ...
Adding new group test-user (1069) ...
Adding new ...
1
vote
2answers
9k views
When to use adduser or useradd [duplicate]
The Question consist of three parts
What are the differences between them
When to use adduser or useradd
and why there is more than one command for the same purpose
1
vote
1answer
6k views
How to add user from guest user?
I've installed ubuntu using wubi from windows. I remembered I provided an username and password. But now I can log in only as guest user from where I can't privileges to install or run program. Can ...
3
votes
1answer
12k views
How to add user from apache user group in linux
The question is simple. How we can add user without root privileges (because www-data is very important for security)?
For example adding user with root user:
sudo adduser user group
Without root ...
0
votes
3answers
625 views
Useradd command input
If you add a user using useradd you get asked to supply some other information about the user (Full name, room number, work phone etc).
Where exactly is this information being stored?
How do you ...
0
votes
3answers
5k views
useradd: cannot lock /etc/subuid; try again later
So, while trying to upgrade to 14.04 I encountered this error:
Could not calculate the upgrade
An unresolvable problem occurred while calculating the upgrade.
Please report this bug against the '...
2
votes
0answers
135 views
How to create multiple users during installation?
Now these days I am working on a Ubuntu customization project. In which I want to add this feature that Customizes OS can be able to create 2 users automatically during the installation. User can be ...
0
votes
1answer
466 views
sudo useradd wont make home directory
I have an automatic script which works, only it just never makes a home directory. The data is extracted from a database.
Heres the script:
$SQL -s -e "SELECT uid, password FROM registrations WHERE ...
0
votes
1answer
259 views
How many users can I create with useradd without having a visible performace degradation
Assuming that I have a PC with 2GHz processor, 4GB RAM.
How many users can I create with useradd without noticing a visible change in performance in server file operations like (copying files form ...
408
votes
6answers
397k views
What is the difference between adduser and useradd?
What is the difference between the commands adduser and useradd on Ubuntu?
0
votes
1answer
327 views
Problem in creating all default directories while adding a new user account in Ubuntu 12.04?
I am facing a bizarre problem recently in Ubuntu 12.04 while adding a new user. User adding command such as useradd -d /home/username -s /bin/bash -m username in the terminal only creates a example-...
1
vote
1answer
991 views
On Ubuntu 12.04 is /etc/skel/ the correct place to put extra files for new users?
On Ubuntu 12.04 is /etc/skel/ the correct place to put extra files for new users?
In the Linux Administration Handbook it mentions files from /usr/local/lib/skel which doesn't seem like an Ubuntu-...
0
votes
1answer
6k views
Ubuntu command 'adduser' is not creating directory 'usertes' in '/home'
I have been creating a user with command adduser, but it did not create directory /home/usertes,
# adduser usertes
And this happens if I delete the user with command userdel:
# userdel usertes
...
1
vote
1answer
95 views
switching to new user limits console capabilities
I'm creating a new user:
groupadd sybase
useradd -g sybase -d /opt/sybase sybase
passwd sybase
chown sybase:sybase /opt/sybase
chown sybase:sybase /var/sybase
then switch to this user:
su - sybase
...
22
votes
2answers
59k views
Cannot login to newly created user account
Trying to switch accounts to my newly created account I get a black screen and then it takes me back to the main login screen after entering the correct password.
Upon logging into my previously ...
4
votes
1answer
28k views
useradd: cannot lock /etc/passwd; try again later
Trying to add a user:
useradd -c "test" -d /home/bbbbbbbb -e "01-jan-2013"
-f 10 -g admin -p secretfgjdhdgd -s /bin/bash -u 123456 blobblob
but getting:
useradd: cannot lock /etc/passwd; try ...