How to Change Your BeagleBone’s Hostname and Password
Currently, the hostname of your BeagleBone is, rather boringly, beaglebone. You may want to change it to something more personal. Doing so is also useful when you start to use more than one BeagleBone on the same network, because the hostname is the name that’s displayed to all the other users on that network.
If you want to change the hostname, start by typing the following command:
debian@beaglebone:~$ sudo echo 'newHostName' > /etc/hostname
Your hostname is changed to the one that you prefer. The BeagleBone won’t recognize this “host,” however, so you need to edit the hosts file. To open and edit it, follow these steps:
Type the following in a text editor such as nano:
debian@beaglebone:~$ sudo nano /etc/hosts
On the line that reads 127.0.0.1 beaglebone, change beaglebone to your new hostname
Save the file, and quit nano.
Reboot your BeagleBone.
Your new hostname should appear during your next login.
Use the arrow keys to navigate nano, and press Ctrl+O to save and Ctrl+X to exit. If you attempt to exit without saving, you’re prompted to press Y if you want to save or N if you don’t.
The default debian user password is temppwd. If you want to change it, simply type the command passwd and follow the steps printed in the terminal:
debian@beaglebone:~$ passwd Changing password for debian. (current) UNIX password: Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully debian@beaglebone:~$
The text is hidden while you write the passwords.