The default hostname for a Raspberry Pi is “raspberrypi” which is great if you’ve only got one Pi but as soon as you add a second to the network things start getting a bit confusing. This quick guide will show you how to change your Pi’s hostname.
You can perform this change though graphical interface but I much prefer to configure things like this via the command prompt. Open a terminal and enter the command:
From the main menu select the “System Options” entry
Select the “Hostname” option
The next page just tells you the rules for hostnames (a-z, 0-9 and -), select “Ok” and then on the next page enter a new name for the host.
Select “Ok” and you’ll be taken back to the start menu. Select “Finish”. You’ll now be asked if you want to reboot the system. If you want the new hostname to take effect you need to restart the system. That’s all there is to it.