I'm trying to rename the default pi
username after getting a new raspberry pi 4. I am completely new to Linux, so my knowledge of the matter is small. From what I've discovered, one way to rename pi
is to create a new root user and run commands from root
. I ran the following command to do this,
sudo passwd root
I then entered the password, logged out of pi
and into root
. In root
, I ran the following to change from pi
to joffin
(my favorite made up name),
root@raspberrypi:~# killall --user pi
root@raspberrypi:~# usermod -l joffin pi
usermod: user pi is currently used by process 8630
then ran this to get details for y'all to see (I don't know what this means).
root@raspberrypi:~# ps -lp 8630
F S UID PID PPID C PRI NI ADDR SZ WCHAN TTY TIME CMD
4 S 1000 8630 1 0 80 0 - 3679 do_epo ? 00:00:00 systemd
I tried again ...
root@raspberrypi:~# killall --user pi
root@raspberrypi:~# usermod -l joffin pi
usermod: user pi is currently used by process 8675
root@raspberrypi:~# ps -lp 8675
F S UID PID PPID C PRI NI ADDR SZ WCHAN TTY TIME CMD
4 S 1000 8675 1 0 80 0 - 3679 do_epo ? 00:00:00 systemd
How can I keep these new processes from spawning so that I can rename my pi?