I started my very first openHab setup last night on a RPI3 and its all going well, slowly getting to grips with it all, which is a bit of a learning curve as I have extremely limited knowledge of Linux code.
I have initially had my OH running on WiFi while I set it up but now I want to install it in its permanent home, where I would like it to use Ethernet. I thought that as I had connected it to Ethernet whilst setting it up which was working before entering the WiFi settings it would be as straight forward as saving the WiFi settings in the config tool as blank but this did not work. I also tried to set a static IP for eth0 in the dhcpcd file but again got no joy.
Am I missing something?
Also, if it is possible to set the Ethernet as default would it be possible to use the Wifi as a backup in case my Ethernet hub goes down?
what do you mean with âsaving Wifi Settings in config toolâ? which config tool, whatâs your Problem exactly. please add more info
you were asked for that information, but you deleted it - so please fill in now:
* Platform information:
* Hardware: _CPUArchitecture/RAM/storage_
* OS: _what OS is used and which version_
* Java Runtime Environment: _which java platform is used and what version_
* openHAB version:
* Issue of the topic: please be detailed explaining your issue
* Please post configurations (if applicable):
* Items configuration related to the issue
* Sitemap configuration related to the issue
* Rules code related to the issue
* Services configuration related to the issue
* If logs where generated please post these here using code fences:
Apologies about the missing info, I didnât realise it was required
Platform information:
Hardware: RPI3 Model B Rev 1.2 with 16GB SD Card
OS: OpenHABian 2.2.0-1
Java Runtime Environment: Not sure, default one that was installed with the OpenHABian disk image
openHAB version: 2.2.0-1
Issue of the topic:
After I first booted the OH I entered âsudo openhabian-configâ from the command line then in the Systems Settings Menu, selected Wifi Setup and entered my Wifi SSID and Password. This allowed me to access the the OH over my Wifi Network. When I plug the the RPI3 in its permanent location in my house it will be adjacent to Ethernet hub so I would prefer to use Ethernet comms instead of Wifi comms. How do I change the settings to Ethernet instead of Wifi? I have tried removing the Wifi SSID and Password in the OpenHABian Configuration Tool by leaving both SSID and Password blank and selecting OK, this removed the Wifi settings but I could not access the OH over Ethernet comms. I also tried to edit the /ect/dhcpcd.conf file and entered the following static IP settings like I have done on previous RPI projects but this did not work -
thanks, now we have a better overview of your system and your situation.
first of all: openHAB will look for network interfaces and use one (I figured, it will use WiFi before Ethernet, but that one could be of the lower IP address of my WiFi).
So, what you basically did is to configure the underlying network configuration of your Pi. So, thatâs not openHAB related, but siply Linux/Raspbian configuration. Normally raspbian (and openHABian is built on it) will work with DHCP, meaning the Pi will get its IP address from your router. What you did is to mess with this and add static IP configuration - it should work also, but this one depends on your router and your overall network configuration.
So, please make sure:
the Network connection, you connected your Pi on is active (meaning itâs patched through to your router)
I know, sounds basic, but sometimes youâre connected to a dead one.
deactivate the static configuration you changed and revert to dynamic DHCP
just plug Ethernet back in
Raspbian (and openHABian) works out-of-the-box with DHCP ethernet.
Your /etc/dhcpcf.conf file looks fine (except I would add more dns servers, but that´s just me). Are you sure your setting for eth0 in /etc/network/interfaces is
Thanks Guys, I have actually put everything back to DHCP and got it all working on Ethernet now, I have also decided to reserve the IP address on my router instead of assigning the OH with a static IP
Hi, I had a similar problem and canâtfind a thread about it. Last weekend (March 18) I tried to setup WiFi on my RPI3 with openhabian which essentially worked. Then I went about configuring further componants and I updated openhabian in the configuration command line console. After that it was nor possible to change the network (wifi) settings from this console anymore and I was not able to bring back the ethernet cable connection either. I had to physically setup keyboard and screen on the RPi to access it again.
After looking around a bit I found this article which helped me, I believe something about the newest versions of components in the update are not working well for network settings: https://www.raspberrypi.org/forums/viewtopic.php?t=191678
To get my system back I had to split the dhcp configuration into multiple files in the subdirectory /etc/network/interfaces.d
I have no clue what stretch, dhcpcd, interfaces.d are but with the split configuration my system works again.
Thatâs probably the way to do it with domestic routers.
When I get a new device I first let them connect to the network with DHCP.
I then log in the router config and reserve that IP for that device.
I then go back to the device and configure static IP.
Last thing is I add this to a list in a âcheatâ file where I keep the IPs the different ports that the OH server uses etcâŚ
I have a similar issue. I did not try to set a static address but Iâm not able anymore to connect on WIFI. Currently I need to connect a monitor on the HDMI port and a mouse-keyboard on the USB port to get access to RPI 3. Iâm working on latest update of Openhabian.
@arober02, you talked about splitting DHCP configuration in subdirectory /etc/network/interfaces.d
On my setup, this directory is empty? Is that normal or the cause of my problem?
Hi, the folder was empty on my pi and I took the dhcp configuration, removed each line (block of lines) that concerned one IP âdeviceâ like the wifi, eth0, etc and created a separate file in that subdirectory for that individual device configuration. Then my ethernet worked again.
It looks to me like there is a new way of configuring ip acquisition by dhcp in the updated packages.
Excuse me, but this does not work for the latest raspbian version that uses openhabian, stretch
Today in my new RPPi 3B+ with openhab runing I configured the wifi without problem, but I lost the ethernet lan conecction.
Solution:
Create a new plain file in /etc/network/interfaces.d folder. Inside of the new file (does not the matter the name) I define the lost interface:
auto eth0
iface eth0 inet dhcp
I am on OH 3 and would like to set a static IP for the WIFI. Where do I configure this? The Network Setting on the Dashboard only shows Ethernet settings, not Wifi and it does not allow you to change them either. I setup my static ethernet in dhcpcd.conf. But donât see where to setup WIFI.
Thank you
upfront: please avoid to wake up year old threads, context will be lost.
Depends on your OS.
OH is not an OS. openHABian is. If that is what your question was on, then the answer is âyou donâtâ.
The common way to handle that is to map your systemâs MAC address to a fixed IP on the DHCP server. Or hack the Raspberry Pi OS config files but for that please donât ask here but use G**gle.