0

Background

I know how to set up a static IP address by editing /etc/dhcpcd.conf.

How do I set up networking/WiFi/static IP address on Raspbian/Raspberry Pi OS? lists many ways.

For example, I have added the following lines:

# Custom static IP address for eth0
interface eth0
static ip_address=192.168.0.65/24
static routers=192.168.0.1

The interface name may be different in your Pi.

This method works fine for me in both Buster and Bullseye.

This method directly assigns a static IP address to the Pi. This is different from requesting a specific IP address from the dynamic IP address range set in the router or assigning a specific IP address to the Pi in the router settings.

Question

How do I achieve the same objective of assigning a static IP address via the GUI without manually editing the file?

Thanks

2 Answers 2

1

This is the GUI way to set a static IP address in the Raspberry Pi OS

If your /etc/dhcpcd.conf has the following lines:

interface enxb827ebaceb8a
static ip_address=192.168.0.65/24
static routers=192.168.0.1
static domain_name_servers=192.168.0.1

You can replicate the same by the following:

Right click on the network icon on the top right corner.

enter image description here

The icon may look different if you are using WiFi instead of the Ethernet cable pictured here.

Select the Wireless and Wired Network Settings

enter image description here

Change the Interfaces to the one you want to change. Here I have selected the wired network interface.

enter image description here

set up the IPv4 IP address to the desired one, and the correct IP address for the router, and the router's IP address for the DNS server.

Click close.

Updated Method inform equivalent:

If your /etc/dhcpcd.conf has the following lines:

interface enxb827ebaceb8a
inform 192.168.0.65

The equivalent in the GUI should be:

enter image description here

Hope this helps

1
  • @Seamus I have updated the answer to include the GUI equivalent of the inform option in dhcpcd.conf.
    – user68186
    Commented Nov 26, 2021 at 3:10
0

"In Bullseye it is a longer string of numbers and letters" This is a Predictable Network Interface Name which is normal for most Linux distributions.

If you did a fresh installation Bullseye would use eth0 - you presumably did one of the unsupported "upgrades" which fail to install/update dpkg rules.

You CAN get normal Pi names if you pass net.ifnames=0 on the kernel command line in /boot/cmdline.txt. See How to set up networking/WiFi.

Incidentally there is no need to obscure the value, it is just derived from MAC.

1
  • Thanks for the comments. I have updated my question based on your input. I knew that the "bunch of numbers and letters" is called Predictable Network Interface Name and is derived from the MAC. I was not sure that the switch of the interface name was another consequence of the unsupported upgrade process. Thanks again.
    – user68186
    Commented Nov 22, 2021 at 23:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.