Static IP Configuration

What is the proper procedure to set a static IP address for the eth0 connection on RatOS? There appears to be no active interfaces file in /etc/network, and it also appears that Network Manager is not running. How is the network configuration accomplished under RatOS? (In case you're wondering, I'm using a Pi 3B+ vice a 3A+, specifically because I wanted a wired Ethernet connection).
8 Replies
blacksmithforlife
blacksmithforlifeβ€’12mo ago
Set it in your router's DNS
miklschmidt
miklschmidtβ€’12mo ago
You pretty much always want to do that in whatever is responsible for DHCP in your network (typically your router)
flat-fuchsia
flat-fuchsiaβ€’12mo ago
This is on a corporate network with a DHCP server that is not the router. I do not have control over the DHCP server. The IT department gave me a static IP to use, I need to put it on the RPi.
ptegler
pteglerβ€’12mo ago
The Raspberry Pi Guide
Set up a static IP-address
A collection of tutorials to help set up and work with your Raspberry Pi
ptegler
pteglerβ€’12mo ago
works for me. I do not use DNS on my home network except for the Fois TV and cell phones. the other 50+ devices are all hardcoded IPs. Even the beehives (yes, Apis mellifera ) with there RPi based monitoring systems are fixed IPs
miklschmidt
miklschmidtβ€’12mo ago
Ah i see, yeah try what ptegler linked. There's nothing fancy on RatOS with regards to network configuration, what works on raspberry pi os bullseye works on RatOS πŸ™‚ Wifi configuration is done via wpa-supplicant (like stock raspberry pi os) if that's of any help
flat-fuchsia
flat-fuchsiaβ€’12mo ago
OK thanks. I tried the dhcpcd.conf method that ptegler was talking about and it didn't seem to work, but dhcpcd.conf is very picky about the syntax in the configuration file. I will try it again.
miklschmidt
miklschmidtβ€’12mo ago
If you can't get it working, maybe you can ask the IT department to automatically assign the IP through DHCP to the MAC address of the pi? You can read that out in the terminal with sudo ifconfig That'll also ensure that it works with zero configuration on your part if you have to reflash or something Plus it'll give them more control (which they usually like πŸ˜‚)