I’m checking out the latest qcow2 image and I changed the username in the settings but the terminal still shows me as “purism”. I tried changing the username with usermod but it just tells me usermod: user purism is currently used by process XXX.
How do I change the username because “purism” is simply not acceptable?
I think you probably need to drop to a terminal prior to logging in as purism. On a laptop/desktop, this would be done with Ctrl+Alt+F{2-7} or something like that, but I’m not sure how one might do it on the Librem 5 image.
Is that coded in to a program or service somewhere? I couldn’t find anything under /etc that had ‘purism’ in it that was relevant so I’m assuming it’s part of some application code?
What about the hostname? Can we change that without any negative side effects?
Right. /lib/systemd/system/phosh.service contains User=1000 which may mean that you could rename the purism account.
(From past experience though, changing the association between name and uid of an account on Linux involves changing things in quite a few different places. So it wouldn’t be a bad idea to have a second account that is allowed ssh access in and has sudo access, and of course working ssh access in, in case you break it.)
easiest way:
boot single user (add single to kernel boot parameter to ensure only root processess will run) usermod -l new-login-name old-name groupmod -n new-login-name old-name
reboot
But what if I wanted to create a new user from scratch and use it as the main user, and eradicate the original one? The log in screen on boot does not seem to be allowing to choose who is logging in.
I think so. Rename. But without fixing the home directory and anything else similar that might depend on it - and I read previously that this will break things because purism is hard-coded somewhere, so that is to be included within the “anything else”.
If done comprehensively, how would that differ? (Theoretically, doing it your way, the “main user” would end up with a different uid but would that matter to you?)
From past experience (not on the Librem 5), renaming the existing account and keeping the uid/gid the same is less hassle.