Static IP#
Easy way#
Configure Static IP from your Raspberry Shake’s internal web configuration page http://rs.local/
Step-by-step guide for advanced users#
SSH into your RaspberryShake (using linux or putty for Windows). See How to access your Raspberry Shake’s computer via ssh for details.
Edit this file using nano, for example:
$ sudo nano /etc/dhcpcd.conf
Note
To manually reset the network configuration, delete all the lines starting with “static”, leaving only “interface eth0”. Then reboot the Shake. Once done, if you require to set up a new Static IP, proceed with the points below.
Add these lines to the end of the file:
If using ethernet (LAN) connection:
interface eth0 static ip_address=192.168.1.100/24 static routers=192.168.1.1 static domain_name_servers=192.168.1.1
If using onboard or USB WiFi:
interface wlan0 static ip_address=192.168.1.100/24 static routers=192.168.1.1 static domain_name_servers=192.168.1.1
Note
Set the ip_address, routers and domain_name_servers values according to your network. The values provided above are for example purposes only.
Note
- If a subnet mask and/or a default gateway are also required:
The default gateway can be specified using the “static routers” line
The subnet mask can be specified by adding an additional parameter to the “static ip_address” line, using this logic:
255.255.255.0 –> IPaddress/24
255.255.0.0 –> IPaddress/16
255.0.0.0 –> IPaddress/8
Note
We recommend executing chattr +i on /etc/dhcpcd.conf file so that it becomes immutable, avoiding potentially unwanted changes.
Save the file with the sequence:
Ctrl+X, Y, Enter
To make sure those changes took hold, restart the service with:
$ sudo service dhcpcd restart
Check the output file with:
$ nano /etc/resolv.conf
Restart the Shake:
$ sudo reboot
See also: Why does my Raspberry Shake change IP?