mastodon.ar.al is one of the many independent Mastodon servers you can use to participate in the fediverse.
This is my personal fediverse server.

Administered by:

Server stats:

1
active users

Aral Balkan

Once we add AI to your Linux distribution, it will tell you whether you should use useradd or adduser with 50% accuracy.

@aral nah I think it will be more like 25% adduser, 25% useradd, 25% groupadd and the rest some hallucinations about crypto, snake fights, gender, edible glue and crisis of masculinity.

That would be an improvement over my current success rate @aral

@aral And it will burn way more electricity than you'd consume by trying out both operations :ablobcatneon:

@aral TIL you don't have to use vi to add users.

(j/k)

@aral I’d rather have a ln -s that works on the first try :P

@schrotthaufen @aral it is always: what you have, what you want.
cp source-file where-i-want-it
mv origin destination
ln -s existing-file where-the-link-should-be

The only thing messig with your brain is ls, which shows symlinks the other way around:
where-the-link-is -> existing-file

@gunstick @aral Oh believe me, I’ve tried to internalize this. I’ve been using some variation of *nix for decades by now😅

@gunstick @schrotthaufen @aral The exact contrary as for `tar -cf newArchive.tar what-existing-files-to-compress` 🙃

@Maoulkavien @gunstick @aral It’s so weird that I never had any issues remembering tar flags, and argument order

@schrotthaufen @Maoulkavien @aral I messed that up on occasion, destroying the first of the files.

@aral
What are the odds it tries to troll the user into doing a destructive operation like rm -rf /? Missed out on having the "sociopathic asshole in the Unix lab" experience in college? Generative AI is here to help.

@aral adduser maintainer here. adduser is the high level tool that will give you policy and support. useradd is the low level tool that you can use if you need features that adduser doesn't offer.

I haven't used useradd in years. At least not in the Debian world.

(All this toot relates to Debian only)

@Zugschlus @aral Okay, so “adduser” is kinda grammatically correct english so would be the verbose, hand holdy tool. And “useradd” sounds more like computer/programming syntax and just does the things if you include the right variables. Is this an accurate memory aid?

@helianthropy @aral That's sounds like a useable helper. having cared about adduser's code in Debian for two decades, I simply know which tool is "mine" ;-)

@Zugschlus@zug.network The very start of the manual for useradd says this as well, I don't really get what all the fuzz is about.
man useradd, the first line in the description section. At least on Debian.

CC: @aral@mastodon.ar.al

@Haijo7 @aral

The following applies to Debian only:

adduser historically has two target audiences: (1) Package Maintainers, who should get a policy conformant package/system account as silently as possible, idempotently, and as quietly as possible, without scffolding code needed inside maintainer scripts¹. (2) Local Administrators, who should get everything they need according to their local policy.

useradd, otoh, has grown many features in the mean time that adduser had implemented earlier. Hence, the difference between the two tools has reduced itself over the last 20 years.

So, as a package maintainer, use adduser. As a local administrator, use anything that fits your needs.

¹ we² still fall short on the scaffolding topic, see bugs.debian.org/adduser
² adduser is team maintained, and the team feels some shortage of personpower. So, if you enjoy test-driven development and know your way around perl, please check wither you want to contribute

@Zugschlus @aral Come for the AI jokes, stay for the but-seriously replies with genuinely useful SysAdmin info. :-) :-)

@aral Given that I currently have only 10% accuracy, that would actually be an improvement.

@aral If you ask it how to create a user it will install the postgres client and run createuser

@aral I'd take an AI to help me with sed/awk syntax. 😂

@aral
LLM (LinuxLeemurMumbler?): use makeuser. Makeuser was programmed by Linus and Stevne Jobs during their vacation inn 1881, where they also co-created BeOS.

I... need to go lay down for a while.

@aral can it do apt uninstall/remove and pip uninstall/remove?

@DetersHenning (In case you meant whether it can fully remove an app and all its dangling bits using those commands.)

@aral
That too, but if it could tell me which command requires which option, I'd be impressed already.