lnewusers(1)
π lnewusers β create new user accounts, bestie π
okay so this is lnewusers(1), a page from the General Commands Manual, and it's literally the group-chat way to spin up a whole batch of new user accounts. No cap. Let's get into it π«Ά
β¨ NAME β¨
lnewusers β Create new user accounts π
πΈ SYNOPSIS πΈ
lnewusers [OPTION]...
π¦ DESCRIPTION π¦
So the vibe is: it creates new user accounts using data that it reads from standard input. That's the whole thing. Feed it lines, get users. Iconic.
The input data is made of lines, and every single line has 7 colon-separated fields. Let's go through them one by one, no skipping, bestie:
- User name β the name, obviously.
- Plaintext password β yep, plaintext, we're all just living like this.
- User ID β heads up:
lnewusersrefuses to create users with user ID0(that's the root user ID). It is simply not happening. Periodt. - Group β if this field is a valid group ID, it gets interpreted as a group ID. Otherwise it's interpreted as a group name. And if the field is empty, then a group name equal to the user name is used.
Also, if the specified group does not exist, it gets automatically created. And if the group is specified with a group ID, then the created group has a group name equal to the user name. Slay π
- GECOS β this field is traditionally used to store the user's real name and other information.
- Home directory β if this field is empty, then a default specified by libuser configuration is used. And if libuser configuration does not specify a default, then
/home/usernameis used. - Login shell β if this field is empty, a default specified by libuser configuration is used.
Errors in user specifications get reported, and then processing just continues on to the next line. She's resilient like that. Not me being unbothered π
β¨ OPTIONS β¨
-f,--file=fileβ Read account data from file instead of standard input. So you don't have to pipe it in, queen.-i,--interactiveβ Ask all questions when connecting to the user database, even if default answers are already set up in libuser configuration. Yes, all of them. She wants the full conversation π£οΈ-M,--nocreatehomeβ Don't create home directories. No home for them, I guess π-n,--nocreatemailβ Don't create mail spool files. No mail, no problem π
π EXIT STATUS π
The exit status is 0 on success, and nonzero on fatal error. And listen β errors in user specifications are not reflected in the exit status. So don't go checking the exit code for that, iykyk π
π SEE ALSO π
Yeah, there's no SEE ALSO section in this one, bestie β the original page doesn't have one, so we're not making one up. We keep it honest around here fr fr π
And that's the whole page, bestie. This lovely thing comes from libuser, and it's dated Jul 13 2008 β yes, she's been iconic since 2008 and she's still serving. Go make some users. Slay. Periodt. π β¨
π¦ where this page comes from
- alpine 3.24: libuser-doc 0.64-r2 Β· LGPL-2.0-or-later
- centos-stream 10: libuser 0.64-12.el10 Β· LGPL-2.0-or-later
- centos-stream 9: libuser 0.63-17.el9 Β· LGPLv2+
- centos-stream 9: libuser 0.63-17.el9 Β· LGPLv2+
- debian bookworm: libuser 1:0.64~dfsg-1 Β· LGPL-2.0-or-later
- debian trixie: libuser 1:0.64+git20241106~dfsg-3 Β· LGPL-2.0-or-later
- fedora 43: libuser 0.64-16.fc43 Β· LGPL-2.0-or-later
- fedora 43: libuser 0.64-16.fc43 Β· LGPL-2.0-or-later
- fedora 44: libuser 0.64-17.fc44 Β· LGPL-2.0-or-later
- fedora 44: libuser 0.64-17.fc44 Β· LGPL-2.0-or-later
- opensuse-leap 16.0: libuser 0.64-bp160.1.1 Β· LGPL-2.0-or-later
- opensuse-leap 16.0: libuser 0.64-bp160.1.1 Β· LGPL-2.0-or-later
- opensuse-leap 16.0: libuser 0.64-bp160.1.1 Β· LGPL-2.0-or-later
- opensuse-leap 16.0: libuser 0.64-bp160.1.1 Β· LGPL-2.0-or-later
- ubuntu jammy: libuser 1:0.63~dfsg-4build1 Β· LGPL-2.0-or-later
- ubuntu noble: libuser 1:0.64~dfsg-2build2 Β· LGPL-2.0-or-later
- ubuntu questing: libuser 1:0.64+git20241106~dfsg-3
- ubuntu resolute: libuser 1:0.64+git20241106~dfsg-4build1 Β· LGPL-2.0-or-later
- ubuntu stonking: libuser 1:0.64+git20241106~dfsg-4build1 Β· LGPL-2.0-or-later
- Copyright (C) 2005, 2008 Red Hat, Inc
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms