How to change openhabian.conf to include wifi if using Quick Start method for SD flash

    • Platform information: Raspberry 4
    • Hardware: Raspberry 4
    • OS: _openHABian from zip file openhabian-pi-raspbian-201908050414-gitca0976f-crc6a66b5a1.img.xz
    • Java Runtime Environment: In the package. not sure I can choose?
    • openHAB version: See OS above
  • Issue of the topic:
    Under the installation guide Raspberry Pi (Prepackaged SD Card Image), Setup, 3rd bullet down is a link to (WiFi also supported it does not work.

Problem:
The directory of the flashed SD shows the files for OA and I noticed now I can find the openhabian.conf to communicate over WIFI. I copied the existing file to my notepad, changed the references to WIFi. Tried to save it to the SC card but it would not save to the SD card.

How do I copy my file to the SD card?

Thanks

  • 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:

i use an pizero with openhabian and i edited my openhabian.conf file so i could run a headless installation.
i found out that i must not edit the file on a windows machine - then it will not work. i put the openhabian-flashed sd-card in a linux-machine (ubuntu desktop-pc as virtual machine) and opended the file, edited and saved it. then i put it in the raspi and started the installation-process.

my openhabian.conf looks like (sorry, many “xx” because personal info):

# Modify your openHABian settings
# Handle with care, only touch if you need to!!

hostname=xx_your_hostname 
username=openhabian
userpw=xx_your_password

# Language and time. Be sure to set these to valid values
timeserver=xx_ip_address_of_my_fritzbox
locales="en_US.UTF-8 de_DE.UTF-8"
system_default_locale="de_DE.UTF-8"
timezone=Europe/Berlin

# Wi-Fi settings. An ethernet connection is recommended
# Requirement: RPi3, RPi0W, PineA64 or a supported external Wi-Fi dongle
# Fill in your SSID and password below, leave empty to use ethernet
wifi_ssid="xx_your_ssid"
wifi_psk="xx_your_wpa3_password"

# Wi-Fi setting. Select a two-letter country code suitable for your location
# E.g. US (default), DE, AU, NZ...
# You may infringe on local legislature otherwise
# See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab
wifi_country="DE"

# vim: filetype=sh

this file i saved on my windows-pc. if i ever want do do a new clean install i just can copy it direct to the sd-card (if you only copy the file without editing it then it is no problem to do this from a windows pc.

Did you eject the card and plug it back in? If not try that. Otherwise you have a windows problem it should just work. There is no magic, open in notepad make changes click save.

1 Like

That’s wrong.
To make sure: we talk about /boot/openhabian.conf. /boot you can mount from Windows which is explained in the Readme to set initial parameters such as WiFi credentials.
If you talk about /etc/openhabian.conf, that’s a copy created on unattended install and yes, that you must not edit from Windoze (then again you cannot, at least not directly, as / is a Linux filesystem and isn’t shared by default)

1 Like

i apologise if i wrote nonsense. when i installed openhabian (already some time ago) i prepared the sd-card with balenaetcher on my windows-machine. then i edited /boot/openhabian.conf with the windows editor and it failed to start.
so i did a secont try and then edited the /boot/openhabian.conf with an linux-editor and then the installation worked.
but perhaps there was something else that was the reason, sorry.