Creating new users in linux without using addmod or user add
Hi, I'm pretty new to linux and trying to figure out some things to help a friend that is taking a class.
What we're trying to do is write bash script to create a user, but can't use adduser or useradd or any other standard commands for adding a user in a single step. We've have been looking around but just haven't been able to find a way to do this.
Another thing that we're trying to do is write a script to create 100 users with names user001 through user100. With doing this we can use adduser or useradd or any other available programs to create a user in a single step, also make up the passwords, but they can all be the same. A way we can do this is create a script which creates a script to create the users. We are also having some trouble trying to do this.
The last thing that we are trying to do is write a script to create 100 users in the form of F######L where F is the first initial, ###### are the last 6 digits of an id or something like that, and L is the last initial. All of this stuff can just be random. The data will come from a file of the form lastname,firstname,IDnumber,password. We can use any of the available programs which create a user in a single step. We have to use the passwords given in the file for the users. We can also create a script which creates a script to create the users. We've been trying to do this but having problems.
Those are all of the things that we are trying to do. If anyone could help at all that would be greatly appreciated.
Thanks so much,
-John
|