Command newusers vs useradd/adduser

So, I'm wondering if there are any major "under the hood" differences between command 'newusers' and 'useradd/adduser" on Linux.

I do understand newusers uses a file, but is there any major difference in how the accounts are created or why one is superior to the other/buggy?

Thanks!

1 Like

Newusers is for updating/adding users in batch whereas adduser is for a single user.

should be zero differences because the information is stored in /etc/passwd and follow a very strict standard.

newusers would be used in a very large linux envrioment where user information changes are done in batch.

you could have something like a master user panel, passwd reset panel, etc that outputs the data onto a file and have a cron job for newusers that reads that file and makes the changes needed.

if you want to learn more about how users and groups are manged in linux then i have a excellent post in my #ult series Insert comment about shilling your own posts here

1 Like

It seems to assign users to uids greater than 65534. Wayyy higher than my others and doesn't add to gshadow.

Thoughts?

no clue. never used newusers before.

The max UID of a modern Linux is 4 billion or so as an unsigned 32 bit number, this works fine:

sudo useradd --uid 10000000 testing

I think for compatibility and such a max of 5 digits is recommended, but I just checked and ls -n seems to displayed the big number fine.

gshadow is passworded groups, I think it's analogous to share level passwords in Windows, the newgrp command activates it, not something I have ever used.