As you know, any Raspberry Pi installation starts with a default username (pi) and the same password each time (raspberry).
In my other tutorials, I always recommend changing the password first.
Today, I’ll also address the way to change the default username.
The Linux command usermod can be used to change the default Raspberry Pi username (pi). This command is used to change all the parameters for a Linux account, including its name. But there are a few prerequisites to do this safely and efficiently.
In this article I’ll show you three methods to change the “pi” user with something more pertinent. The first one is by using the usermod command, the second one is by changing a bunch of files manually, and the last one is by simply creating a new user.