Sample Header Ad - 728x90

Ramifications of renaming a user

0 votes
0 answers
39 views
I'm setting up two computers with MX Linux that will be nearly identical, with a lot of customization from the original distro. I installed and customized the first one for User1, and will basically clone that (using the MX snapshot tools), as the starting point for the User2 system. Because much of the customization is stored in the /home directory, I'm using what MX calls a "personal" snapshot that includes the user-specific stuff in /home, rather than a generic respin, where User2 would be setup by the system during installation. So the starting point for User2 has User1 as the primary user. My plan is to rename the user (UID 1000) to User2 (sudo usermod -l User2 User1). I need to also change their group to match (sudo groupmod -n User2 User1), and will need to clean up their home directory (sudo usermod -d /home/User2 -m User2). And other obvious user-centric things like their password and various preferences. I'm wondering if there are any non-obvious OS ramifications of the name change that I need to deal with. - One that occurred to me is file/folder/device ownership. It isn't clear whether these are associated by UID (which won't change), or username (which is how ownership is typically displayed). - I am assuming that system lists, like the sudoers file, and system provisions relating to things like auto-login and keyrings are associated by UID. Bottom line: other than group and /home, does changing the username affect anything operational (system-related), that I need to modify?
Asked by fixer1234 (701 rep)
Aug 28, 2022, 09:57 AM