Static IP Configuration on Batocera
29 Jun 2026∞
I’ve been using a Raspberry Pi 5 to run Batocera (v43 as of this writing) and finally decided to connect it to the network so I could add some more games and perform regular updates, scrape the various artwork, and possibly enable some multi-player action. Unfortunately, after connecting it to the network, I noticed the only setting in the UI is to either enable or disable network functionality and WiFi. There’s no settings to configure a static IP, the gateway, the DNS servers, etc. When you search for this online, you’ll find in various communities users suggesting to just set a DHCP reservation because it’s “better” (dubious claim repeated frequently). Since this is Linux and I didn’t like the answer I was finding, I decided to do some digging. Mostly because the IPv6 information it kept discovering was broken, so I couldn’t actually do any Internet-facing activity.
Batocera v43 uses connman for the networking setup. The configuration files live in /var/lib/connman/ and /etc/connman/, but in the former there are helpfully some symbolic links outside the read-only filesystem intended for user customization. Great! It took me a bit to figure out the right edits to make and where to make it persistent, but if you happen to run into the same issue, here are the steps that worked for me.
root@BATOCERA# connmanctl services
*AO Wired ethernet_deadbeefcafe_cable
wifi_deadbeefcafe_hidden_managed_psk
SSID1 wifi_deadbeefcafe_12341234123456_managed_psk
SSID2 wifi_deadbeefcafe_12341234_managed_psk
This will list the discovered network interfaces and possibly discovered or configured SSIDs. I am specifically configuring the Ethernet interface, so you’ll want to note that id. In the example output above, ethernet_deadbeefcafe_cable.
root@BATOCERA# mount -o rw,remount /boot
root@BATOCERA# cat << END >> /var/lib/connman/batocera-boot-custom.config
[service_ethernet_deadbeefcafe_cable]
Name=Wired
Type=ethernet
IPv4=192.0.2.2/255.255.255.0/192.0.2.1
IPv6=off
Nameservers=192.0.2.53,198.51.100.53
Timeservers=192.0.2.123,198.51.100.123
SearchDomains=example.com,example.net
Domain=example.com
END
root@BATOCERA# batocera-save-overlay
These commands will (1) remount the /boot partition as read-write, so you can make a customization to the connman config (/var/lib/connman/batocera-boot-custom.config actually points to /boot/network-connman.config), (2) appends the config or creates it if it does not exist, and (3) saves the overlay filesystem and remounts /boot as read-only. All you need to do is reboot for the changes to take effect. I found the Debian connman-service.config(5) manpage to be particularly helpful, as well as tail -F /var/log/messages once it populates to check for errors.