LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   newusersers command ???? (https://www.linuxquestions.org/questions/linux-newbie-8/newusersers-command-42107/)

80s 01-20-2003 02:11 AM

newusersers command ????
 
#Please advise me on the use on the newusers command.
#i use the following format.
alan:x:0:0:65534:Alan Machin:/home/alan/:/bin/bash
#but i get the following error
line 1 :to long
error detected, changes ingored..
#i have also tried just a name and i get the same error.

Many Thank

MasterC 01-20-2003 02:19 AM

useradd or adduser, I prefer adduser just because it prompts me on each portion.

Is this what you are asking? Or am I confused?

Cool

80s 01-20-2003 02:35 AM

newusers
 
newuser is a command that reads info from a text file in the same format a passwd file.

I need to be able to create about 500 users in one go. I can generate in file in passwd format from my data base..

but when i tested it with a single line as above i got the mentioned error ..


Thanks for your reply.

MasterC 01-20-2003 12:31 PM

Ok, so I tried reading around about it, I don't really see alot saying one way or the other, but maybe the space in the User's name is causing the error?

1 other thing I noticed looking at it:
alan:x:0:0:65534:Alan Machin:/home/alan/:/bin/bash

You have 0:0:65534

Well for 1 I think 0:0 is root, so I think you'd be giving this person root access, and 2....

Ahh, just tried it on my box, yeah it looks like that's your problem maybe. You've got too many entries. 0:0 will set both user/group as root's gid/uid I am thinking you maybe want something else, either way, you've got too many entries there for user/group so look at this part:
0:0:65534

And either remove a 0 to take away the root gid/uid or remove the 65534 to take away the "extra" gid.

HTH

Cool

80s 01-21-2003 12:44 AM

ifound the problem.. cause i was only using one line to test i wasn't pressing enter...


needs to see a caridge return to recognise the end of the line :)

MasterC 01-21-2003 12:50 AM

Good deal :) Glad you found that ;)

Cool


All times are GMT -5. The time now is 09:48 AM.