From whoami to “Who Am I?”: My Journey as a Renamed Linux User
🐧 It All Started With My First Linux Install
I typed a username without thinking much about it. For weeks, I knew I wanted to change it both for comfort and to learn how Linux manages users.
🔧 Renaming a User on Fedora Workstation 42
You can’t rename a logged-in user because system processes are running under that username. Here’s what worked:
- Log out completely by clicking the power icon in the top-right corner, then select log out.
- At the login screen, switch to TTY (Ctrl+Alt+F3).
- Login as root (you might need to enable root first):
sudo passwd -S rootif it showsroot L ...then unlock it by setting new passwordsudo passwd root - Verify the old user isn’t running any processes:
ps -u old_username - Rename the user:
usermod -l new_username old_username - Verify the change:
cat /etc/passwd | grep new_username - Update the home directory path:
usermod -d /home/new_username -m new_username - Return to the GUI (Ctrl+Alt+F1/F2).
🗂 Fixing File Manager
After changing username, I found broken bookmarks in Nautilus file manager. Here’s how I fixed them:
- Find the bookmarks file:
find ~/.config -name "*bookmarks*" -type f 2>/dev/null - Edit it:
nano ~/.config/gtk-3.0/bookmarks - Updated all paths from
/home/old_usernameto/home/new_username.
💡 Key Takeaways
- Linux user management involves multiple files and processes.
- The terminal becomes much more enjoyable when you love your username!😄