2022-01-25_19:49:46_CET [openHABian] Checking for root privileges... OK + export UNATTENDED SILENT DEBUGMAX INTERACTIVE + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/auth.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/backup.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/config.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/ext-storage.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/find.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/habapp.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/helpers.bash ++ ESC='\033[' ++ COL_DEF='\033[39;49;00m' ++ COL_RED='\033[31;01m' ++ COL_GREEN='\033[32;01m' ++ COL_YELLOW='\033[33;01m' ++ COL_BLUE='\033[34;01m' ++ COL_MAGENTA='\033[35;01m' ++ COL_CYAN='\033[36;01m' ++ COL_LGRAY='\033[37;01m' ++ COL_DGRAY='\033[90;01m' ++ export COL_DEF COL_RED COL_GREEN COL_YELLOW COL_BLUE COL_MAGENTA COL_CYAN COL_LGRAY COL_DGRAY + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/influxdb+grafana.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/java-jre.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/menu.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/nodejs-apps.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhab.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhabian.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/packages.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/system.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/vpn.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/wifi.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/zram.bash ++ pwd + OLDWD=/opt/openhabian + cd /opt + update_openhabian_conf + local configFile=/etc/openhabian.conf + local referenceConfig=/opt/openhabian/build-image/openhabian.conf + cp /etc/openhabian.conf /etc/openhabian.conf.BAK + read -r line + [[ # Origin: openhabian.conf =~ ^(#)?[a-zA-Z] ]] + echo '# Origin: openhabian.conf' + read -r line + [[ # =~ ^(#)?[a-zA-Z] ]] + echo '#' + read -r line + [[ # Modify your openHABian settings =~ ^(#)?[a-zA-Z] ]] + echo '# Modify your openHABian settings' + read -r line + [[ # Handle with care, only touch if you need to! =~ ^(#)?[a-zA-Z] ]] + echo '# Handle with care, only touch if you need to!' + read -r line + [[ # This file will only be used on unattended initial install. =~ ^(#)?[a-zA-Z] ]] + echo '# This file will only be used on unattended initial install.' + read -r line + [[ # If you want to change anything after unattended install completed, use menu in openhabian-config. =~ ^(#)?[a-zA-Z] ]] + echo '# If you want to change anything after unattended install completed, use menu in openhabian-config.' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # ATTENTION: to disable an option a line MUST be of the format '# option=value' =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: to disable an option a line MUST be of the format '\''# option=value'\''' + read -r line + [[ # KEEP THE SPACE IT IS IMPORTANT !! =~ ^(#)?[a-zA-Z] ]] + echo '# KEEP THE SPACE IT IS IMPORTANT !!' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hostname to set this one to =~ ^(#)?[a-zA-Z] ]] + echo '# Hostname to set this one to' + read -r line + [[ hostname=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hostname=openhabian + [[ hostname=openhabian =~ ^#[a-zA-Z] ]] ++ echo hostname=openhabian ++ cut -d= -f1 + param=hostname + [[ -v hostname ]] + [[ openhabian == *\ * ]] + echo hostname=openhabian + read -r line + [[ # if it exists, the default user (with its working environment) will be renamed to this username given here ... =~ ^(#)?[a-zA-Z] ]] + echo '# if it exists, the default user (with its working environment) will be renamed to this username given here ...' + read -r line + [[ username=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=username=openhabian + [[ username=openhabian =~ ^#[a-zA-Z] ]] ++ echo username=openhabian ++ cut -d= -f1 + param=username + [[ -v username ]] + [[ openhabian == *\ * ]] + echo username=openhabian + read -r line + [[ # ... and given this password. The password will be removed from this file after completion for security reasons. =~ ^(#)?[a-zA-Z] ]] + echo '# ... and given this password. The password will be removed from this file after completion for security reasons.' + read -r line + [[ userpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=userpw=openhabian + [[ userpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo userpw=openhabian ++ cut -d= -f1 + param=userpw + [[ -v userpw ]] + [[ openhabian == *\ * ]] + echo userpw=openhabian + read -r line + [[ # set this to download a SSH key and authorize the owner to login as the admin user =~ ^(#)?[a-zA-Z] ]] + echo '# set this to download a SSH key and authorize the owner to login as the admin user' + read -r line + [[ adminkeyurl="" =~ ^(#)?[a-zA-Z] ]] + parsed='adminkeyurl=""' + [[ adminkeyurl="" =~ ^#[a-zA-Z] ]] ++ echo 'adminkeyurl=""' ++ cut -d= -f1 + param=adminkeyurl + [[ -v adminkeyurl ]] + [[ '' == *\ * ]] + echo adminkeyurl= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Language and timezone. See Debian documentation for valid values. =~ ^(#)?[a-zA-Z] ]] + echo '# Language and timezone. See Debian documentation for valid values.' + read -r line + [[ timezone=Europe/Berlin =~ ^(#)?[a-zA-Z] ]] + parsed=timezone=Europe/Berlin + [[ timezone=Europe/Berlin =~ ^#[a-zA-Z] ]] ++ echo timezone=Europe/Berlin ++ cut -d= -f1 + param=timezone + [[ -v timezone ]] + [[ Europe/Berlin == *\ * ]] + echo timezone=Europe/Berlin + read -r line + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='locales="en_US.UTF-8 de_DE.UTF-8"' + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'locales="en_US.UTF-8 de_DE.UTF-8"' ++ cut -d= -f1 + param=locales + [[ -v locales ]] + [[ en_US.UTF-8 de_DE.UTF-8 == *\ * ]] + echo 'locales="en_US.UTF-8 de_DE.UTF-8"' + read -r line + [[ system_default_locale="en_US.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='system_default_locale="en_US.UTF-8"' + [[ system_default_locale="en_US.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'system_default_locale="en_US.UTF-8"' ++ cut -d= -f1 + param=system_default_locale + [[ -v system_default_locale ]] + [[ en_US.UTF-8 == *\ * ]] + echo system_default_locale=en_US.UTF-8 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # WiFi settings. An ethernet connection is recommended. =~ ^(#)?[a-zA-Z] ]] + echo '# WiFi settings. An ethernet connection is recommended.' + read -r line + [[ # If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi =~ ^(#)?[a-zA-Z] ]] + echo '# If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi' + read -r line + [[ # interface can be setup and used for the initial installation. =~ ^(#)?[a-zA-Z] ]] + echo '# interface can be setup and used for the initial installation.' + read -r line + [[ # Fill in your SSID and password below, leave empty or put comment in front to =~ ^(#)?[a-zA-Z] ]] + echo '# Fill in your SSID and password below, leave empty or put comment in front to' + read -r line + [[ # have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works. =~ ^(#)?[a-zA-Z] ]] + echo '# have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works.' + read -r line + [[ # ATTENTION: you need to escape these special characters: $, `, ", \, (newline) =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: you need to escape these special characters: $, `, ", \, (newline)' + read -r line + [[ # 'Escaping' means to put an additional \ in front of that character =~ ^(#)?[a-zA-Z] ]] + echo '# '\''Escaping'\'' means to put an additional \ in front of that character' + read -r line + [[ wifi_ssid="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_ssid=""' + [[ wifi_ssid="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_ssid=""' ++ cut -d= -f1 + param=wifi_ssid + [[ -v wifi_ssid ]] + [[ '' == *\ * ]] + echo wifi_ssid= + read -r line + [[ wifi_password="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_password=""' + [[ wifi_password="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_password=""' ++ cut -d= -f1 + param=wifi_password + [[ -v wifi_password ]] + [[ '' == *\ * ]] + echo wifi_password= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Wi-Fi setting. Select a two-letter country code suitable for your location =~ ^(#)?[a-zA-Z] ]] + echo '# Wi-Fi setting. Select a two-letter country code suitable for your location' + read -r line + [[ # E.g. US (default), DE, AU, NZ... =~ ^(#)?[a-zA-Z] ]] + echo '# E.g. US (default), DE, AU, NZ...' + read -r line + [[ # You may infringe on local legislature otherwise =~ ^(#)?[a-zA-Z] ]] + echo '# You may infringe on local legislature otherwise' + read -r line + [[ # See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab =~ ^(#)?[a-zA-Z] ]] + echo '# See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab' + read -r line + [[ wifi_country="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_country=""' + [[ wifi_country="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_country=""' ++ cut -d= -f1 + param=wifi_country + [[ -v wifi_country ]] + [[ '' == *\ * ]] + echo wifi_country= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Eventually disable all IPv6 e.g. on installation problems =~ ^(#)?[a-zA-Z] ]] + echo '# Eventually disable all IPv6 e.g. on installation problems' + read -r line + [[ # values: "enable", "disable" =~ ^(#)?[a-zA-Z] ]] + echo '# values: "enable", "disable"' + read -r line + [[ ipv6=enable =~ ^(#)?[a-zA-Z] ]] + parsed=ipv6=enable + [[ ipv6=enable =~ ^#[a-zA-Z] ]] ++ echo ipv6=enable ++ cut -d= -f1 + param=ipv6 + [[ -v ipv6 ]] + [[ enable == *\ * ]] + echo ipv6=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # repo and branch to clone from =~ ^(#)?[a-zA-Z] ]] + echo '# repo and branch to clone from' + read -r line + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^(#)?[a-zA-Z] ]] + parsed=repositoryurl=https://github.com/openhab/openhabian.git + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^#[a-zA-Z] ]] ++ echo repositoryurl=https://github.com/openhab/openhabian.git ++ cut -d= -f1 + param=repositoryurl + [[ -v repositoryurl ]] + [[ https://github.com/openhab/openhabian == *\ * ]] + echo repositoryurl=https://github.com/openhab/openhabian + read -r line + [[ clonebranch=openHAB3 =~ ^(#)?[a-zA-Z] ]] + parsed=clonebranch=openHAB3 + [[ clonebranch=openHAB3 =~ ^#[a-zA-Z] ]] ++ echo clonebranch=openHAB3 ++ cut -d= -f1 + param=clonebranch + [[ -v clonebranch ]] + [[ openHAB3 == *\ * ]] + echo clonebranch=openHAB3 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # initial openHAB configuration to import (URL or filename) =~ ^(#)?[a-zA-Z] ]] + echo '# initial openHAB configuration to import (URL or filename)' + read -r line + [[ # the file needs to be a zip archive created from openhab-cli backup =~ ^(#)?[a-zA-Z] ]] + echo '# the file needs to be a zip archive created from openhab-cli backup' + read -r line + [[ # initialconfig=/boot/initial.zip =~ ^(#)?[a-zA-Z] ]] + echo '# initialconfig=/boot/initial.zip' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # debug verbosity mode =~ ^(#)?[a-zA-Z] ]] + echo '# debug verbosity mode' + read -r line + [[ # off, on (verbose output in log) or maximum (show every command) =~ ^(#)?[a-zA-Z] ]] + echo '# off, on (verbose output in log) or maximum (show every command)' + read -r line + [[ debugmode=off =~ ^(#)?[a-zA-Z] ]] + parsed=debugmode=off + [[ debugmode=off =~ ^#[a-zA-Z] ]] ++ echo debugmode=off ++ cut -d= -f1 + param=debugmode + [[ -v debugmode ]] + [[ maximum == *\ * ]] + echo debugmode=maximum + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # the framebuffer on RPi is enabled by default =~ ^(#)?[a-zA-Z] ]] + echo '# the framebuffer on RPi is enabled by default' + read -r line + [[ framebuffer=enable =~ ^(#)?[a-zA-Z] ]] + parsed=framebuffer=enable + [[ framebuffer=enable =~ ^#[a-zA-Z] ]] ++ echo framebuffer=enable ++ cut -d= -f1 + param=framebuffer + [[ -v framebuffer ]] + [[ enable == *\ * ]] + echo framebuffer=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # fake hardware =~ ^(#)?[a-zA-Z] ]] + echo '# fake hardware' + read -r line + [[ # force treating your box as if it was a ... =~ ^(#)?[a-zA-Z] ]] + echo '# force treating your box as if it was a ...' + read -r line + [[ # pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86 =~ ^(#)?[a-zA-Z] ]] + echo '# pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86' + read -r line + [[ # hw= =~ ^(#)?[a-zA-Z] ]] + echo '# hw=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hardware architecture =~ ^(#)?[a-zA-Z] ]] + echo '# Hardware architecture' + read -r line + [[ # x86_64, amd64, armv6l, armv7l, aarch64, arm64 =~ ^(#)?[a-zA-Z] ]] + echo '# x86_64, amd64, armv6l, armv7l, aarch64, arm64' + read -r line + [[ # hwarch= =~ ^(#)?[a-zA-Z] ]] + echo '# hwarch=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # OS distribution/release =~ ^(#)?[a-zA-Z] ]] + echo '# OS distribution/release' + read -r line + [[ # Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal =~ ^(#)?[a-zA-Z] ]] + echo '# Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal' + read -r line + [[ # osrelease= =~ ^(#)?[a-zA-Z] ]] + echo '# osrelease=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Java version to install =~ ^(#)?[a-zA-Z] ]] + echo '# Java version to install' + read -r line + [[ java_opt=11 =~ ^(#)?[a-zA-Z] ]] + parsed=java_opt=11 + [[ java_opt=11 =~ ^#[a-zA-Z] ]] ++ echo java_opt=11 ++ cut -d= -f1 + param=java_opt + [[ -v java_opt ]] + [[ 11 == *\ * ]] + echo java_opt=11 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # install zram per default, set to "disable" to skip installation =~ ^(#)?[a-zA-Z] ]] + echo '# install zram per default, set to "disable" to skip installation' + read -r line + [[ zraminstall=enable =~ ^(#)?[a-zA-Z] ]] + parsed=zraminstall=enable + [[ zraminstall=enable =~ ^#[a-zA-Z] ]] ++ echo zraminstall=enable ++ cut -d= -f1 + param=zraminstall + [[ -v zraminstall ]] + [[ enable == *\ * ]] + echo zraminstall=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # start comitup hotspot if internet is not reachable =~ ^(#)?[a-zA-Z] ]] + echo '# start comitup hotspot if internet is not reachable' + read -r line + [[ hotspot=enable =~ ^(#)?[a-zA-Z] ]] + parsed=hotspot=enable + [[ hotspot=enable =~ ^#[a-zA-Z] ]] ++ echo hotspot=enable ++ cut -d= -f1 + param=hotspot + [[ -v hotspot ]] + [[ enable == *\ * ]] + echo hotspot=enable + read -r line + [[ hotspotpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hotspotpw=openhabian + [[ hotspotpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo hotspotpw=openhabian ++ cut -d= -f1 + param=hotspotpw + [[ -v hotspotpw ]] + [[ openhabian == *\ * ]] + echo hotspotpw=openhabian + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # external SD card device to backup and mirror the internal SD card to =~ ^(#)?[a-zA-Z] ]] + echo '# external SD card device to backup and mirror the internal SD card to' + read -r line + [[ # backupdrive=/dev/sda =~ ^(#)?[a-zA-Z] ]] + echo '# backupdrive=/dev/sda' + read -r line + [[ storageconfig=openhab-dir =~ ^(#)?[a-zA-Z] ]] + parsed=storageconfig=openhab-dir + [[ storageconfig=openhab-dir =~ ^#[a-zA-Z] ]] ++ echo storageconfig=openhab-dir ++ cut -d= -f1 + param=storageconfig + [[ -v storageconfig ]] + [[ openhab-dir == *\ * ]] + echo storageconfig=openhab-dir + read -r line + [[ storagedir=/storage =~ ^(#)?[a-zA-Z] ]] + parsed=storagedir=/storage + [[ storagedir=/storage =~ ^#[a-zA-Z] ]] ++ echo storagedir=/storage ++ cut -d= -f1 + param=storagedir + [[ -v storagedir ]] + [[ /storage == *\ * ]] + echo storagedir=/storage + read -r line + [[ storagetapes=15 =~ ^(#)?[a-zA-Z] ]] + parsed=storagetapes=15 + [[ storagetapes=15 =~ ^#[a-zA-Z] ]] ++ echo storagetapes=15 ++ cut -d= -f1 + param=storagetapes + [[ -v storagetapes ]] + [[ 15 == *\ * ]] + echo storagetapes=15 + read -r line + [[ storagecapacity=1024 =~ ^(#)?[a-zA-Z] ]] + parsed=storagecapacity=1024 + [[ storagecapacity=1024 =~ ^#[a-zA-Z] ]] ++ echo storagecapacity=1024 ++ cut -d= -f1 + param=storagecapacity + [[ -v storagecapacity ]] + [[ 1024 == *\ * ]] + echo storagecapacity=1024 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # mail relay settings =~ ^(#)?[a-zA-Z] ]] + echo '# mail relay settings' + read -r line + [[ # adminmail=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# adminmail=john.doe@foo.bar' + read -r line + [[ # relayuser=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# relayuser=john.doe@foo.bar' + read -r line + [[ # relaypass=secret =~ ^(#)?[a-zA-Z] ]] + echo '# relaypass=secret' + read -r line + [[ # smarthost=smtp.gmail.com =~ ^(#)?[a-zA-Z] ]] + echo '# smarthost=smtp.gmail.com' + read -r line + [[ # smartport=587 =~ ^(#)?[a-zA-Z] ]] + echo '# smartport=587' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Tailscale VPN =~ ^(#)?[a-zA-Z] ]] + echo '# Tailscale VPN' + read -r line + [[ # preauthkey=tskey-xxxxxxxxxxxxxxxxx =~ ^(#)?[a-zA-Z] ]] + echo '# preauthkey=tskey-xxxxxxxxxxxxxxxxx' + read -r line + [[ # tstags=tag:client =~ ^(#)?[a-zA-Z] ]] + echo '# tstags=tag:client' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Custom log files =~ ^(#)?[a-zA-Z] ]] + echo '# Custom log files' + read -r line + [[ # custom_log_files=("/var/log/foo.log" "/var/log/bar.log") =~ ^(#)?[a-zA-Z] ]] + echo '# custom_log_files=("/var/log/foo.log" "/var/log/bar.log")' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # vim: filetype=sh =~ ^(#)?[a-zA-Z] ]] + echo '# vim: filetype=sh' + read -r line + set_cpu_speed + is_raspios + [[ '' == \r\a\s\p\i\o\s ]] + is_raspbian + [[ '' == \r\a\s\p\b\i\a\n ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ Raspbian ]] + return 0 + return 0 + running_in_docker + [[ -n '' ]] + grep -qs 'docker\|lxc' /proc/1/cgroup + [[ -f /.dockerenv ]] + return 1 + echo 'GOVERNOR="ondemand"' + echo ondemand + config_ipv6 + local aptConf=/etc/apt/apt.conf.d/S90force-ipv4 + local sysctlConf=/etc/sysctl.d/99-sysctl.conf + [[ enable == \d\i\s\a\b\l\e ]] + [[ enable == \e\n\a\b\l\e ]] + grep -qs '^[[:space:]]*# Disable all IPv6 functionality' /etc/sysctl.d/99-sysctl.conf + [[ -n '' ]] + apt_update + PID_APT=2159 + apt-get update + whiptail_check ++ command -v whiptail + [[ -x /usr/bin/whiptail ]] + load_create_config + local 'questionText=\nWelcome to openHABian!\n\nPlease provide the name of your Linux user i.e. the account you normally log in with.\n\nTypical user names are '\''pi'\'' or '\''ubuntu'\''.' + local input + [[ -f /etc/openhabian.conf ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:49:47_CET [openHABian] Loading configuration file '\''/etc/openhabian.conf'\''... ' 2022-01-25_19:49:47_CET [openHABian] Loading configuration file '/etc/openhabian.conf'... ++ getent group openhabian + [[ ! -n openhabian:x:1000:openhabian,frontail ]] + id -u openhabian + source /etc/openhabian.conf ++ hostname=openhabian ++ username=openhabian ++ userpw=openhabian ++ adminkeyurl= ++ timezone=Europe/Berlin ++ locales='en_US.UTF-8 de_DE.UTF-8' ++ system_default_locale=en_US.UTF-8 ++ wifi_ssid= ++ wifi_password= ++ wifi_country= ++ ipv6=enable ++ repositoryurl=https://github.com/openhab/openhabian ++ clonebranch=openHAB3 ++ debugmode=maximum ++ framebuffer=enable ++ java_opt=11 ++ zraminstall=enable ++ hotspot=enable ++ hotspotpw=openhabian ++ storageconfig=openhab-dir ++ storagedir=/storage ++ storagetapes=15 ++ storagecapacity=1024 + echo OK OK + openhabian_console_check + [[ -z 1 ]] ++ tput cols + [[ 151 -ge 120 ]] + return 0 + openhabian_update_check + [[ -z 1 ]] + local branch + local introText + local unsupportedOSText + branch=openHAB3 + introText='Additions, improvements or fixes were added to the openHABian configuration tool. Would you like to update now and benefit from them? The update will not automatically apply changes to your system.\n\nUpdating is recommended.' + unsupportedOSText='You are running an old Linux release that is no longer officially supported.\nWe recommend upgrading to the most current stable re lease of your distribution (or current Long Term Support version for distributions that offer LTS).\nDo you really want to continue using openHABian on this system?' ++ timestamp ++ date +%F_%T_%Z ++ get_git_revision ++ local branch ++ local commitDate ++ local shorthash +++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD ++ branch=openHAB3 +++ git -C /opt/openhabian log --pretty=format:%aI -n 1 ++ commitDate=2022-01-24T16:28:12-07:00 +++ git -C /opt/openhabian log --pretty=format:%h -n 1 ++ shorthash=08bc4ff ++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' + echo '2022-01-25_19:49:47_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' 2022-01-25_19:49:47_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff) ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:49:47_CET [openHABian] Checking for changes in origin branch openHAB3... ' 2022-01-25_19:49:47_CET [openHABian] Checking for changes in origin branch openHAB3... + is_stretch + [[ '' == \s\t\r\e\t\c\h ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ stretch ]] + return 1 + is_xenial + [[ '' == \x\e\n\i\a\l ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ xenial ]] + return 1 + git -C /opt/openhabian config user.email openhabian@openHABian + git -C /opt/openhabian config user.name openhabian + git -C /opt/openhabian fetch --quiet origin ++ git -C /opt/openhabian rev-parse openHAB3 ++ git -C /opt/openhabian rev-parse '@{u}' + [[ 08bc4ff34e8b7b059c126b6b999039cef7b48d33 == 08bc4ff34e8b7b059c126b6b999039cef7b48d33 ]] + echo OK OK + openhabian_announcements + [[ -z 1 ]] + local altReadNews + local newsFile + local readNews + altReadNews=/tmp/NEWS.md + newsFile=/opt/openhabian/NEWS.md + readNews=/opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /tmp/NEWS.md ++ cat /opt/openhabian/NEWS.md + whiptail --title 'openHABian announcements' --yes-button 'Stop displaying' --no-button 'Keep displaying' --defaultno --scrolltext --yesno 'Hit tab to unselect buttons and scroll through the text using UP/DOWN or PGUP/PGDN. All announcements are stored in `/opt/openhabian/docs/CHANGELOG.md` for you to lookup. ## Major Java provider switch ## December 15, 2021 We have switched to supporting only the OpenJDK package provided by default from the APT repo for all new installations of openHABian. Existing installations will be unaffected, however you will no longer receive updates to your current Java install until you install Java from the new provider which you can do by running menu option 45. Experimental support for Java 17 has also been added along with this change. In the future once Adoptium (formerly AdoptOpenJDK) releases a Debian based package repository support for Adoptium Java installs will be added as well. ## Node-RED and openHAB 3 ## December 10, 2021 We have updated the package of the Node-RED addon for openHAB 3 to `node-red-contrib-openhab3` to better support openHAB 3 installations which use this addon. You can install it today using `openhabian-config` menu option 25, which will install / upgrade all necessary components for Node-RED operation. ## openHABian 1.7 ## December 1, 2021 We have upgraded our base operating system to Raspberry Pi OS Bullseye. As usual upgrades on supported systems will be unaffected, use the `openhabian-config` menu to apply any updates available to your system. We will not automatically update your current base system (i.e buster -> bullseye) - don'\''t fix what ain'\''t broke. Debian buster will be at least supported two more years. If you are eager to upgrade, read up on `dist-upgrade` or reinstall your system. Please note that if you choose to upgrade and not reinstall, you are on your own, don'\''t expect to get support from the developers of openHABian if something goes wrong. Noteworthy changes since last image release: * New base OS: Raspberry Pi OS Bullseye * Added support for Raspberry Pi Zero 2 W * Ability to update zram without reinstalling it * More robust Java install routine * Fixed Amanda install not prompting for email address to send reports to * General bug fixes Known bugs: * Homegear is currently broken on Bullseye (complain to their devs)' 27 84 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:49:52_CET [openHABian] Switching to branch openHAB3... ' 2022-01-25_19:49:52_CET [openHABian] Switching to branch openHAB3... + git -C /opt/openhabian checkout --quiet openHAB3 + echo OK OK + bashrc_copy ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:49:52_CET [openHABian] Adding slightly tuned bash configuration files to system... ' 2022-01-25_19:49:52_CET [openHABian] Adding slightly tuned bash configuration files to system... + cp /opt/openhabian/includes/generic/bash.bashrc /etc/bash.bashrc + cp /opt/openhabian/includes/generic/bashrc-root /root/.bashrc + cp /opt/openhabian/includes/generic/bash_profile /home/openhabian/.bash_profile + cp /opt/openhabian/includes/generic/bash_aliases /home/openhabian/.bash_aliases + chown openhabian:openhabian /home/openhabian/.bash_aliases /home/openhabian/.bash_history /home/openhabian/.bash_logout /home/openhabian/.bash_profile + echo OK OK + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | Abo ut openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' ' Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 confi guration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional sof tware components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ► ' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice= + RET=1 + '[' 1 -eq 1 ']' + return 255 + system_check_default_password + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + local algo + local defaultPassword + local defaultUser + local generatedPassword + local introText + local originalPassword + local salt + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + id -u pi + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + defaultUser=openhabian + defaultPassword=openhabian ++ grep -w openhabian /etc/shadow ++ cut -d: -f2 + originalPassword='$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f2 + algo=y + introText='The default password was detected on your system! That is a serious security concern. Bad guys or malicious programs in your subnet are able to gain root access!\n\nPlease set a strong password by typing the command '\''passwd openhabian'\''!' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f3 + salt=j9T + export algo defaultPassword salt ++ perl -le 'print crypt("$ENV{defaultPassword}","\$$ENV{algo}\$$ENV{salt}\$")' + generatedPassword='$y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA' ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:49:55_CET [openHABian] Checking for default openHABian username:password combination... ' 2022-01-25_19:49:55_CET [openHABian] Checking for default openHABian username:password combination... ++ id -u openhabian + [[ -n 1000 ]] + [[ $y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA == \$\y\$\j\9\T\$\Q\R\t\E\2\O\.\Q\S\Y\H\l\o\E\Z\n\r\j\v\G\R\/\$\N\8\f\i\E\k\r\p\u\x\e\B\P\R\G\K\o\6\u\2\t\q\5\y\L\u\l\L\f\x\D\W \R\d\i\v\Q\r\/\y\k\g\0 ]] + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -e '2022-01-25_19:49:55_CET [openHABian] We hope you got what you came for! See you again soon ;)' 2022-01-25_19:49:55_CET [openHABian] We hope you got what you came for! See you again soon ;) + cd /opt/openhabian 2022-01-25_19:53:49_CET [openHABian] Checking for root privileges... OK + export UNATTENDED SILENT DEBUGMAX INTERACTIVE + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/auth.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/backup.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/config.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/ext-storage.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/find.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/habapp.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/helpers.bash ++ ESC='\033[' ++ COL_DEF='\033[39;49;00m' ++ COL_RED='\033[31;01m' ++ COL_GREEN='\033[32;01m' ++ COL_YELLOW='\033[33;01m' ++ COL_BLUE='\033[34;01m' ++ COL_MAGENTA='\033[35;01m' ++ COL_CYAN='\033[36;01m' ++ COL_LGRAY='\033[37;01m' ++ COL_DGRAY='\033[90;01m' ++ export COL_DEF COL_RED COL_GREEN COL_YELLOW COL_BLUE COL_MAGENTA COL_CYAN COL_LGRAY COL_DGRAY + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/influxdb+grafana.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/java-jre.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/menu.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/nodejs-apps.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhab.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhabian.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/packages.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/system.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/vpn.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/wifi.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/zram.bash ++ pwd + OLDWD=/opt/openhabian + cd /opt + update_openhabian_conf + local configFile=/etc/openhabian.conf + local referenceConfig=/opt/openhabian/build-image/openhabian.conf + cp /etc/openhabian.conf /etc/openhabian.conf.BAK + read -r line + [[ # Origin: openhabian.conf =~ ^(#)?[a-zA-Z] ]] + echo '# Origin: openhabian.conf' + read -r line + [[ # =~ ^(#)?[a-zA-Z] ]] + echo '#' + read -r line + [[ # Modify your openHABian settings =~ ^(#)?[a-zA-Z] ]] + echo '# Modify your openHABian settings' + read -r line + [[ # Handle with care, only touch if you need to! =~ ^(#)?[a-zA-Z] ]] + echo '# Handle with care, only touch if you need to!' + read -r line + [[ # This file will only be used on unattended initial install. =~ ^(#)?[a-zA-Z] ]] + echo '# This file will only be used on unattended initial install.' + read -r line + [[ # If you want to change anything after unattended install completed, use menu in openhabian-config. =~ ^(#)?[a-zA-Z] ]] + echo '# If you want to change anything after unattended install completed, use menu in openhabian-config.' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # ATTENTION: to disable an option a line MUST be of the format '# option=value' =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: to disable an option a line MUST be of the format '\''# option=value'\''' + read -r line + [[ # KEEP THE SPACE IT IS IMPORTANT !! =~ ^(#)?[a-zA-Z] ]] + echo '# KEEP THE SPACE IT IS IMPORTANT !!' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hostname to set this one to =~ ^(#)?[a-zA-Z] ]] + echo '# Hostname to set this one to' + read -r line + [[ hostname=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hostname=openhabian + [[ hostname=openhabian =~ ^#[a-zA-Z] ]] ++ echo hostname=openhabian ++ cut -d= -f1 + param=hostname + [[ -v hostname ]] + [[ openhabian == *\ * ]] + echo hostname=openhabian + read -r line + [[ # if it exists, the default user (with its working environment) will be renamed to this username given here ... =~ ^(#)?[a-zA-Z] ]] + echo '# if it exists, the default user (with its working environment) will be renamed to this username given here ...' + read -r line + [[ username=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=username=openhabian + [[ username=openhabian =~ ^#[a-zA-Z] ]] ++ echo username=openhabian ++ cut -d= -f1 + param=username + [[ -v username ]] + [[ openhabian == *\ * ]] + echo username=openhabian + read -r line + [[ # ... and given this password. The password will be removed from this file after completion for security reasons. =~ ^(#)?[a-zA-Z] ]] + echo '# ... and given this password. The password will be removed from this file after completion for security reasons.' + read -r line + [[ userpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=userpw=openhabian + [[ userpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo userpw=openhabian ++ cut -d= -f1 + param=userpw + [[ -v userpw ]] + [[ openhabian == *\ * ]] + echo userpw=openhabian + read -r line + [[ # set this to download a SSH key and authorize the owner to login as the admin user =~ ^(#)?[a-zA-Z] ]] + echo '# set this to download a SSH key and authorize the owner to login as the admin user' + read -r line + [[ adminkeyurl="" =~ ^(#)?[a-zA-Z] ]] + parsed='adminkeyurl=""' + [[ adminkeyurl="" =~ ^#[a-zA-Z] ]] ++ echo 'adminkeyurl=""' ++ cut -d= -f1 + param=adminkeyurl + [[ -v adminkeyurl ]] + [[ '' == *\ * ]] + echo adminkeyurl= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Language and timezone. See Debian documentation for valid values. =~ ^(#)?[a-zA-Z] ]] + echo '# Language and timezone. See Debian documentation for valid values.' + read -r line + [[ timezone=Europe/Berlin =~ ^(#)?[a-zA-Z] ]] + parsed=timezone=Europe/Berlin + [[ timezone=Europe/Berlin =~ ^#[a-zA-Z] ]] ++ echo timezone=Europe/Berlin ++ cut -d= -f1 + param=timezone + [[ -v timezone ]] + [[ Europe/Berlin == *\ * ]] + echo timezone=Europe/Berlin + read -r line + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='locales="en_US.UTF-8 de_DE.UTF-8"' + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'locales="en_US.UTF-8 de_DE.UTF-8"' ++ cut -d= -f1 + param=locales + [[ -v locales ]] + [[ en_US.UTF-8 de_DE.UTF-8 == *\ * ]] + echo 'locales="en_US.UTF-8 de_DE.UTF-8"' + read -r line + [[ system_default_locale="en_US.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='system_default_locale="en_US.UTF-8"' + [[ system_default_locale="en_US.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'system_default_locale="en_US.UTF-8"' ++ cut -d= -f1 + param=system_default_locale + [[ -v system_default_locale ]] + [[ en_US.UTF-8 == *\ * ]] + echo system_default_locale=en_US.UTF-8 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # WiFi settings. An ethernet connection is recommended. =~ ^(#)?[a-zA-Z] ]] + echo '# WiFi settings. An ethernet connection is recommended.' + read -r line + [[ # If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi =~ ^(#)?[a-zA-Z] ]] + echo '# If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi' + read -r line + [[ # interface can be setup and used for the initial installation. =~ ^(#)?[a-zA-Z] ]] + echo '# interface can be setup and used for the initial installation.' + read -r line + [[ # Fill in your SSID and password below, leave empty or put comment in front to =~ ^(#)?[a-zA-Z] ]] + echo '# Fill in your SSID and password below, leave empty or put comment in front to' + read -r line + [[ # have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works. =~ ^(#)?[a-zA-Z] ]] + echo '# have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works.' + read -r line + [[ # ATTENTION: you need to escape these special characters: $, `, ", \, (newline) =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: you need to escape these special characters: $, `, ", \, (newline)' + read -r line + [[ # 'Escaping' means to put an additional \ in front of that character =~ ^(#)?[a-zA-Z] ]] + echo '# '\''Escaping'\'' means to put an additional \ in front of that character' + read -r line + [[ wifi_ssid="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_ssid=""' + [[ wifi_ssid="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_ssid=""' ++ cut -d= -f1 + param=wifi_ssid + [[ -v wifi_ssid ]] + [[ '' == *\ * ]] + echo wifi_ssid= + read -r line + [[ wifi_password="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_password=""' + [[ wifi_password="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_password=""' ++ cut -d= -f1 + param=wifi_password + [[ -v wifi_password ]] + [[ '' == *\ * ]] + echo wifi_password= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Wi-Fi setting. Select a two-letter country code suitable for your location =~ ^(#)?[a-zA-Z] ]] + echo '# Wi-Fi setting. Select a two-letter country code suitable for your location' + read -r line + [[ # E.g. US (default), DE, AU, NZ... =~ ^(#)?[a-zA-Z] ]] + echo '# E.g. US (default), DE, AU, NZ...' + read -r line + [[ # You may infringe on local legislature otherwise =~ ^(#)?[a-zA-Z] ]] + echo '# You may infringe on local legislature otherwise' + read -r line + [[ # See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab =~ ^(#)?[a-zA-Z] ]] + echo '# See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab' + read -r line + [[ wifi_country="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_country=""' + [[ wifi_country="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_country=""' ++ cut -d= -f1 + param=wifi_country + [[ -v wifi_country ]] + [[ '' == *\ * ]] + echo wifi_country= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Eventually disable all IPv6 e.g. on installation problems =~ ^(#)?[a-zA-Z] ]] + echo '# Eventually disable all IPv6 e.g. on installation problems' + read -r line + [[ # values: "enable", "disable" =~ ^(#)?[a-zA-Z] ]] + echo '# values: "enable", "disable"' + read -r line + [[ ipv6=enable =~ ^(#)?[a-zA-Z] ]] + parsed=ipv6=enable + [[ ipv6=enable =~ ^#[a-zA-Z] ]] ++ echo ipv6=enable ++ cut -d= -f1 + param=ipv6 + [[ -v ipv6 ]] + [[ enable == *\ * ]] + echo ipv6=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # repo and branch to clone from =~ ^(#)?[a-zA-Z] ]] + echo '# repo and branch to clone from' + read -r line + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^(#)?[a-zA-Z] ]] + parsed=repositoryurl=https://github.com/openhab/openhabian.git + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^#[a-zA-Z] ]] ++ echo repositoryurl=https://github.com/openhab/openhabian.git ++ cut -d= -f1 + param=repositoryurl + [[ -v repositoryurl ]] + [[ https://github.com/openhab/openhabian == *\ * ]] + echo repositoryurl=https://github.com/openhab/openhabian + read -r line + [[ clonebranch=openHAB3 =~ ^(#)?[a-zA-Z] ]] + parsed=clonebranch=openHAB3 + [[ clonebranch=openHAB3 =~ ^#[a-zA-Z] ]] ++ echo clonebranch=openHAB3 ++ cut -d= -f1 + param=clonebranch + [[ -v clonebranch ]] + [[ openHAB3 == *\ * ]] + echo clonebranch=openHAB3 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # initial openHAB configuration to import (URL or filename) =~ ^(#)?[a-zA-Z] ]] + echo '# initial openHAB configuration to import (URL or filename)' + read -r line + [[ # the file needs to be a zip archive created from openhab-cli backup =~ ^(#)?[a-zA-Z] ]] + echo '# the file needs to be a zip archive created from openhab-cli backup' + read -r line + [[ # initialconfig=/boot/initial.zip =~ ^(#)?[a-zA-Z] ]] + echo '# initialconfig=/boot/initial.zip' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # debug verbosity mode =~ ^(#)?[a-zA-Z] ]] + echo '# debug verbosity mode' + read -r line + [[ # off, on (verbose output in log) or maximum (show every command) =~ ^(#)?[a-zA-Z] ]] + echo '# off, on (verbose output in log) or maximum (show every command)' + read -r line + [[ debugmode=off =~ ^(#)?[a-zA-Z] ]] + parsed=debugmode=off + [[ debugmode=off =~ ^#[a-zA-Z] ]] ++ echo debugmode=off ++ cut -d= -f1 + param=debugmode + [[ -v debugmode ]] + [[ maximum == *\ * ]] + echo debugmode=maximum + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # the framebuffer on RPi is enabled by default =~ ^(#)?[a-zA-Z] ]] + echo '# the framebuffer on RPi is enabled by default' + read -r line + [[ framebuffer=enable =~ ^(#)?[a-zA-Z] ]] + parsed=framebuffer=enable + [[ framebuffer=enable =~ ^#[a-zA-Z] ]] ++ echo framebuffer=enable ++ cut -d= -f1 + param=framebuffer + [[ -v framebuffer ]] + [[ enable == *\ * ]] + echo framebuffer=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # fake hardware =~ ^(#)?[a-zA-Z] ]] + echo '# fake hardware' + read -r line + [[ # force treating your box as if it was a ... =~ ^(#)?[a-zA-Z] ]] + echo '# force treating your box as if it was a ...' + read -r line + [[ # pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86 =~ ^(#)?[a-zA-Z] ]] + echo '# pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86' + read -r line + [[ # hw= =~ ^(#)?[a-zA-Z] ]] + echo '# hw=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hardware architecture =~ ^(#)?[a-zA-Z] ]] + echo '# Hardware architecture' + read -r line + [[ # x86_64, amd64, armv6l, armv7l, aarch64, arm64 =~ ^(#)?[a-zA-Z] ]] + echo '# x86_64, amd64, armv6l, armv7l, aarch64, arm64' + read -r line + [[ # hwarch= =~ ^(#)?[a-zA-Z] ]] + echo '# hwarch=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # OS distribution/release =~ ^(#)?[a-zA-Z] ]] + echo '# OS distribution/release' + read -r line + [[ # Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal =~ ^(#)?[a-zA-Z] ]] + echo '# Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal' + read -r line + [[ # osrelease= =~ ^(#)?[a-zA-Z] ]] + echo '# osrelease=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Java version to install =~ ^(#)?[a-zA-Z] ]] + echo '# Java version to install' + read -r line + [[ java_opt=11 =~ ^(#)?[a-zA-Z] ]] + parsed=java_opt=11 + [[ java_opt=11 =~ ^#[a-zA-Z] ]] ++ echo java_opt=11 ++ cut -d= -f1 + param=java_opt + [[ -v java_opt ]] + [[ 11 == *\ * ]] + echo java_opt=11 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # install zram per default, set to "disable" to skip installation =~ ^(#)?[a-zA-Z] ]] + echo '# install zram per default, set to "disable" to skip installation' + read -r line + [[ zraminstall=enable =~ ^(#)?[a-zA-Z] ]] + parsed=zraminstall=enable + [[ zraminstall=enable =~ ^#[a-zA-Z] ]] ++ echo zraminstall=enable ++ cut -d= -f1 + param=zraminstall + [[ -v zraminstall ]] + [[ enable == *\ * ]] + echo zraminstall=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # start comitup hotspot if internet is not reachable =~ ^(#)?[a-zA-Z] ]] + echo '# start comitup hotspot if internet is not reachable' + read -r line + [[ hotspot=enable =~ ^(#)?[a-zA-Z] ]] + parsed=hotspot=enable + [[ hotspot=enable =~ ^#[a-zA-Z] ]] ++ echo hotspot=enable ++ cut -d= -f1 + param=hotspot + [[ -v hotspot ]] + [[ enable == *\ * ]] + echo hotspot=enable + read -r line + [[ hotspotpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hotspotpw=openhabian + [[ hotspotpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo hotspotpw=openhabian ++ cut -d= -f1 + param=hotspotpw + [[ -v hotspotpw ]] + [[ openhabian == *\ * ]] + echo hotspotpw=openhabian + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # external SD card device to backup and mirror the internal SD card to =~ ^(#)?[a-zA-Z] ]] + echo '# external SD card device to backup and mirror the internal SD card to' + read -r line + [[ # backupdrive=/dev/sda =~ ^(#)?[a-zA-Z] ]] + echo '# backupdrive=/dev/sda' + read -r line + [[ storageconfig=openhab-dir =~ ^(#)?[a-zA-Z] ]] + parsed=storageconfig=openhab-dir + [[ storageconfig=openhab-dir =~ ^#[a-zA-Z] ]] ++ echo storageconfig=openhab-dir ++ cut -d= -f1 + param=storageconfig + [[ -v storageconfig ]] + [[ openhab-dir == *\ * ]] + echo storageconfig=openhab-dir + read -r line + [[ storagedir=/storage =~ ^(#)?[a-zA-Z] ]] + parsed=storagedir=/storage + [[ storagedir=/storage =~ ^#[a-zA-Z] ]] ++ echo storagedir=/storage ++ cut -d= -f1 + param=storagedir + [[ -v storagedir ]] + [[ /storage == *\ * ]] + echo storagedir=/storage + read -r line + [[ storagetapes=15 =~ ^(#)?[a-zA-Z] ]] + parsed=storagetapes=15 + [[ storagetapes=15 =~ ^#[a-zA-Z] ]] ++ echo storagetapes=15 ++ cut -d= -f1 + param=storagetapes + [[ -v storagetapes ]] + [[ 15 == *\ * ]] + echo storagetapes=15 + read -r line + [[ storagecapacity=1024 =~ ^(#)?[a-zA-Z] ]] + parsed=storagecapacity=1024 + [[ storagecapacity=1024 =~ ^#[a-zA-Z] ]] ++ echo storagecapacity=1024 ++ cut -d= -f1 + param=storagecapacity + [[ -v storagecapacity ]] + [[ 1024 == *\ * ]] + echo storagecapacity=1024 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # mail relay settings =~ ^(#)?[a-zA-Z] ]] + echo '# mail relay settings' + read -r line + [[ # adminmail=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# adminmail=john.doe@foo.bar' + read -r line + [[ # relayuser=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# relayuser=john.doe@foo.bar' + read -r line + [[ # relaypass=secret =~ ^(#)?[a-zA-Z] ]] + echo '# relaypass=secret' + read -r line + [[ # smarthost=smtp.gmail.com =~ ^(#)?[a-zA-Z] ]] + echo '# smarthost=smtp.gmail.com' + read -r line + [[ # smartport=587 =~ ^(#)?[a-zA-Z] ]] + echo '# smartport=587' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Tailscale VPN =~ ^(#)?[a-zA-Z] ]] + echo '# Tailscale VPN' + read -r line + [[ # preauthkey=tskey-xxxxxxxxxxxxxxxxx =~ ^(#)?[a-zA-Z] ]] + echo '# preauthkey=tskey-xxxxxxxxxxxxxxxxx' + read -r line + [[ # tstags=tag:client =~ ^(#)?[a-zA-Z] ]] + echo '# tstags=tag:client' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Custom log files =~ ^(#)?[a-zA-Z] ]] + echo '# Custom log files' + read -r line + [[ # custom_log_files=("/var/log/foo.log" "/var/log/bar.log") =~ ^(#)?[a-zA-Z] ]] + echo '# custom_log_files=("/var/log/foo.log" "/var/log/bar.log")' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # vim: filetype=sh =~ ^(#)?[a-zA-Z] ]] + echo '# vim: filetype=sh' + read -r line + set_cpu_speed + is_raspios + [[ '' == \r\a\s\p\i\o\s ]] + is_raspbian + [[ '' == \r\a\s\p\b\i\a\n ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ Raspbian ]] + return 0 + return 0 + running_in_docker + [[ -n '' ]] + grep -qs 'docker\|lxc' /proc/1/cgroup + [[ -f /.dockerenv ]] + return 1 + echo 'GOVERNOR="ondemand"' + echo ondemand + config_ipv6 + local aptConf=/etc/apt/apt.conf.d/S90force-ipv4 + local sysctlConf=/etc/sysctl.d/99-sysctl.conf + [[ enable == \d\i\s\a\b\l\e ]] + [[ enable == \e\n\a\b\l\e ]] + grep -qs '^[[:space:]]*# Disable all IPv6 functionality' /etc/sysctl.d/99-sysctl.conf + [[ -n '' ]] + apt_update + PID_APT=2609 + whiptail_check + apt-get update ++ command -v whiptail + [[ -x /usr/bin/whiptail ]] + load_create_config + local 'questionText=\nWelcome to openHABian!\n\nPlease provide the name of your Linux user i.e. the account you normally log in with.\n\nTypical user names are '\''pi'\'' or '\''ubuntu'\''.' + local input + [[ -f /etc/openhabian.conf ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:53:50_CET [openHABian] Loading configuration file '\''/etc/openhabian.conf'\''... ' 2022-01-25_19:53:50_CET [openHABian] Loading configuration file '/etc/openhabian.conf'... ++ getent group openhabian + [[ ! -n openhabian:x:1000:openhabian,frontail ]] + id -u openhabian + source /etc/openhabian.conf ++ hostname=openhabian ++ username=openhabian ++ userpw=openhabian ++ adminkeyurl= ++ timezone=Europe/Berlin ++ locales='en_US.UTF-8 de_DE.UTF-8' ++ system_default_locale=en_US.UTF-8 ++ wifi_ssid= ++ wifi_password= ++ wifi_country= ++ ipv6=enable ++ repositoryurl=https://github.com/openhab/openhabian ++ clonebranch=openHAB3 ++ debugmode=maximum ++ framebuffer=enable ++ java_opt=11 ++ zraminstall=enable ++ hotspot=enable ++ hotspotpw=openhabian ++ storageconfig=openhab-dir ++ storagedir=/storage ++ storagetapes=15 ++ storagecapacity=1024 + echo OK OK + openhabian_console_check + [[ -z 1 ]] ++ tput cols + [[ 237 -ge 120 ]] + return 0 + openhabian_update_check + [[ -z 1 ]] + local branch + local introText + local unsupportedOSText + branch=openHAB3 + introText='Additions, improvements or fixes were added to the openHABian configuration tool. Would you like to update now and benefit from them? The update will not automatically apply changes to your system.\n\nUpdating is recommended.' + unsupportedOSText='You are running an old Linux release that is no longer officially supported.\nWe recommend upgrading to the most current stable release of your distribution (or current Long Term Support version for distributions that offer LTS).\nDo you really want to continue using openHABian on this system?' ++ timestamp ++ date +%F_%T_%Z ++ get_git_revision ++ local branch ++ local commitDate ++ local shorthash +++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD ++ branch=openHAB3 +++ git -C /opt/openhabian log --pretty=format:%aI -n 1 ++ commitDate=2022-01-24T16:28:12-07:00 +++ git -C /opt/openhabian log --pretty=format:%h -n 1 ++ shorthash=08bc4ff ++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' + echo '2022-01-25_19:53:50_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' 2022-01-25_19:53:50_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff) ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:53:50_CET [openHABian] Checking for changes in origin branch openHAB3... ' 2022-01-25_19:53:50_CET [openHABian] Checking for changes in origin branch openHAB3... + is_stretch + [[ '' == \s\t\r\e\t\c\h ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ stretch ]] + return 1 + is_xenial + [[ '' == \x\e\n\i\a\l ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ xenial ]] + return 1 + git -C /opt/openhabian config user.email openhabian@openHABian + git -C /opt/openhabian config user.name openhabian + git -C /opt/openhabian fetch --quiet origin ++ git -C /opt/openhabian rev-parse openHAB3 ++ git -C /opt/openhabian rev-parse '@{u}' + [[ 08bc4ff34e8b7b059c126b6b999039cef7b48d33 == 08bc4ff34e8b7b059c126b6b999039cef7b48d33 ]] + echo OK OK + openhabian_announcements + [[ -z 1 ]] + local altReadNews + local newsFile + local readNews + altReadNews=/tmp/NEWS.md + newsFile=/opt/openhabian/NEWS.md + readNews=/opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /tmp/NEWS.md ++ cat /opt/openhabian/NEWS.md + whiptail --title 'openHABian announcements' --yes-button 'Stop displaying' --no-button 'Keep displaying' --defaultno --scrolltext --yesno 'Hit tab to unselect buttons and scroll through the text using UP/DOWN or PGUP/PGDN. All announcements are stored in `/opt/openhabian/docs/CHANGELOG.md` for you to lookup. ## Major Java provider switch ## December 15, 2021 We have switched to supporting only the OpenJDK package provided by default from the APT repo for all new installations of openHABian. Existing installations will be unaffected, however you will no longer receive updates to your current Java install until you install Java from the new provider which you can do by running menu option 45. Experimental support for Java 17 has also been added along with this change. In the future once Adoptium (formerly AdoptOpenJDK) releases a Debian based package repository support for Adoptium Java installs will be added as well. ## Node-RED and openHAB 3 ## December 10, 2021 We have updated the package of the Node-RED addon for openHAB 3 to `node-red-contrib-openhab3` to better support openHAB 3 installations which use this addon. You can install it today using `openhabian-config` menu option 25, which will install / upgrade all necessary components for Node-RED operation. ## openHABian 1.7 ## December 1, 2021 We have upgraded our base operating system to Raspberry Pi OS Bullseye. As usual upgrades on supported systems will be unaffected, use the `openhabian-config` menu to apply any updates available to your system. We will not automatically update your current base system (i.e buster -> bullseye) - don'\''t fix what ain'\''t broke. Debian buster will be at least supported two more years. If you are eager to upgrade, read up on `dist-upgrade` or reinstall your system. Please note that if you choose to upgrade and not reinstall, you are on your own, don'\''t expect to get support from the developers of openHABian if something goes wrong. Noteworthy changes since last image release: * New base OS: Raspberry Pi OS Bullseye * Added support for Raspberry Pi Zero 2 W * Ability to update zram without reinstalling it * More robust Java install routine * Fixed Amanda install not prompting for email address to send reports to * General bug fixes Known bugs: * Homegear is currently broken on Bullseye (complain to their devs)' 27 84 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:53:56_CET [openHABian] Switching to branch openHAB3... ' 2022-01-25_19:53:56_CET [openHABian] Switching to branch openHAB3... + git -C /opt/openhabian checkout --quiet openHAB3 + echo OK OK + bashrc_copy ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:53:56_CET [openHABian] Adding slightly tuned bash configuration files to system... ' 2022-01-25_19:53:56_CET [openHABian] Adding slightly tuned bash configuration files to system... + cp /opt/openhabian/includes/generic/bash.bashrc /etc/bash.bashrc + cp /opt/openhabian/includes/generic/bashrc-root /root/.bashrc + cp /opt/openhabian/includes/generic/bash_profile /home/openhabian/.bash_profile + cp /opt/openhabian/includes/generic/bash_aliases /home/openhabian/.bash_aliases + chown openhabian:openhabian /home/openhabian/.bash_aliases /home/openhabian/.bash_history /home/openhabian/.bash_logout /home/openhabian/.bash_profile + echo OK OK + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='30 | System Settings' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 30 | System Settings == '' ]] + [[ 30 | System Settings == \0\0* ]] + [[ 30 | System Settings == \0\1* ]] + [[ 30 | System Settings == \0\2* ]] + [[ 30 | System Settings == \0\3* ]] + [[ 30 | System Settings == \0\4* ]] + [[ 30 | System Settings == \1\0* ]] + [[ 30 | System Settings == \2\0* ]] + [[ 30 | System Settings == \3\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' +++ hostname +++ env +++ grep '^[[:space:]]*LANG=' +++ sed 's|LANG=||g' +++ date +%H:%M ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'System Settings' 26 118 19 --cancel-button Back --ok-button Execute '31 | Change hostname' 'Change the name of this system, currently '\''openhabian'\''' '32 | Set system locale' 'Change system language, currently '\''de_DE.UTF-8'\''' '33 | Set system timezone' 'Change your timezone, execute if it'\''s not '\''19:53'\'' now' ' | Enable NTP' 'Enable time synchronization via systemd-timesyncd to NTP servers' ' | Disable NTP' 'Disable time synchronization via systemd-timesyncd to NTP servers' '34 | Change passwords' 'Change passwords for Samba, openHAB Console or the system user' '35 | Serial port' 'Prepare serial ports for peripherals like RaZberry, ZigBee adapters etc' '36 | Disable framebuffer' 'Disable framebuffer on RPi to minimize memory usage' ' | Enable framebuffer' 'Enable framebuffer (standard setting)' '37 | WiFi setup' 'Configure wireless network connection' ' | Disable WiFi' 'Disable wireless network connection' '38 | Use zram' 'Use compressed RAM/disk sync for active directories to avoid SD card corruption' ' | Update zram' 'Update a currently installed zram instance' ' | Uninstall zram' 'Don'\''t use compressed memory (back to standard Raspberry Pi OS filesystem layout)' '39 | Move root to USB' 'Move the system root from the SD card to a USB device (SSD or stick)' '3A | Setup Exim Mail Relay' 'Install Exim4 to relay mails via public email provider' '3B | Setup Tailscale VPN' 'Establish or join a WireGuard based VPN using the Tailscale service' ' | Remove Tailscale VPN' 'Remove the Tailscale VPN service' ' | Install WireGuard' 'Setup WireGuard to enable secure remote access to this openHABian system' ' | Remove WireGuard' 'Remove WireGuard VPN from this system' + choice2= + '[' 1 -eq 1 ']' + return 0 + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='40 | openHAB Related' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 40 | openHAB Related == '' ]] + [[ 40 | openHAB Related == \0\0* ]] + [[ 40 | openHAB Related == \0\1* ]] + [[ 40 | openHAB Related == \0\2* ]] + [[ 40 | openHAB Related == \0\3* ]] + [[ 40 | openHAB Related == \0\4* ]] + [[ 40 | openHAB Related == \1\0* ]] + [[ 40 | openHAB Related == \2\0* ]] + [[ 40 | openHAB Related == \3\0* ]] + [[ 40 | openHAB Related == \4\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'openHAB Related' 18 116 11 --cancel-button Back --ok-button Execute '41 | openHAB Release' 'Install or switch to the latest openHAB Release' ' | openHAB Milestone' 'Install or switch to the latest openHAB Milestone Build' ' | openHAB Snapshot' 'Install or switch to the latest openHAB Snapshot Build' '42 | Upgrade to openHAB 3' 'Upgrade OS environment to openHAB 3 release' ' | Downgrade to openHAB 2' 'Downgrade OS environment from openHAB 3 back to openHAB 2 (DANGEROUS)' '43 | Remote Console' 'Bind the openHAB SSH console to all external interfaces' '44 | Nginx Proxy' 'Setup reverse and forward web proxy' '45 | OpenJDK 11' 'Install OpenJDK 11 as Java provider' ' | OpenJDK 17' 'Install OpenJDK 17 as Java provider' ' | Zulu 11 OpenJDK 32-bit' 'Install Zulu 11 32-bit OpenJDK as Java provider' ' | Zulu 11 OpenJDK 64-bit' 'Install Zulu 11 64-bit OpenJDK as Java provider' + choice2= + '[' 1 -eq 1 ']' + return 0 + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='10 | Apply Improvements' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 10 | Apply Improvements == '' ]] + [[ 10 | Apply Improvements == \0\0* ]] + [[ 10 | Apply Improvements == \0\1* ]] + [[ 10 | Apply Improvements == \0\2* ]] + [[ 10 | Apply Improvements == \0\3* ]] + [[ 10 | Apply Improvements == \0\4* ]] + [[ 10 | Apply Improvements == \1\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Apply Improvements' 13 116 6 --cancel-button Back --ok-button Execute '11 | Packages' 'Install needed and recommended system packages' '12 | Bash&Vim Settings' 'Update customized openHABian settings for bash, vim and nano' '13 | System Tweaks' 'Add /srv mounts and update settings typical for openHAB' '14 | Fix Permissions' 'Update file permissions of commonly used files and folders' '15 | FireMotD' 'Upgrade the program behind the system overview on SSH login' '16 | Samba' 'Install the Samba file sharing service and set up openHAB shares' + choice2='14 | Fix Permissions' + '[' 0 -eq 1 ']' + '[' 1 -eq 255 ']' + wait_for_apt_to_finish_update ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:54:14_CET [openHABian] Updating Linux package information... ' 2022-01-25_19:54:14_CET [openHABian] Updating Linux package information... + [[ -z 2609 ]] + tail --pid=2609 -f /dev/null + echo OK OK + case "$choice2" in + permissions_corrections + local gpioDir=/sys/devices/platform/soc + groups=('audio' 'bluetooth' 'dialout' 'gpio' 'tty') + local groups + openhabFolders=('/etc/openhab' '/var/lib/openhab' '/var/log/openhab' '/usr/share/openhab') + local openhabFolders + local openhabHome=/var/lib/openhab + local backupsFolder=/var/lib/openhab/backups + local retval=0 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:54:14_CET [openHABian] Applying file permissions recommendations... ' 2022-01-25_19:54:14_CET [openHABian] Applying file permissions recommendations... + openhab_is_installed + openhab2_is_installed ++ dpkg -s openhab2 ++ grep Status ++ cut '-d ' -f2 + [[ '' == \i\n\s\t\a\l\l ]] + return 1 + openhab3_is_installed ++ dpkg -s openhab ++ grep Status ++ cut '-d ' -f2 + [[ install == \i\n\s\t\a\l\l ]] + return 0 + return 0 + cond_echo '\nSetting Java and arping file capabilites' + [[ -z '' ]] + echo -e '\033[33;01m\nSetting Java and arping file capabilites\033[39;49;00m' Setting Java and arping file capabilites +++ command -v java ++ realpath /usr/bin/java + cond_redirect setcap 'cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep' /usr/lib/jvm/java-11-openjdk-armhf/bin/java + [[ -n '' ]] + echo -e '\n\033[90;01m$ setcap cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep /usr/lib/jvm/java-11-openjdk-armhf/bin/java \033[39;49;00m' $ setcap cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep /usr/lib/jvm/java-11-openjdk-armhf/bin/java + setcap 'cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep' /usr/lib/jvm/java-11-openjdk-armhf/bin/java + return 0 + cond_redirect setcap 'cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep' /usr/sbin/arping + [[ -n '' ]] + echo -e '\n\033[90;01m$ setcap cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep /usr/sbin/arping \033[39;49;00m' $ setcap cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep /usr/sbin/arping + setcap 'cap_net_raw,cap_net_admin=+eip cap_net_bind_service=+ep' /usr/sbin/arping + return 0 + for pGroup in "${groups[@]}" + grep -qs '^[[:space:]]*audio:' /etc/group + cond_redirect usermod --append --groups audio openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups audio openhab \033[39;49;00m' $ usermod --append --groups audio openhab + usermod --append --groups audio openhab + return 0 + cond_redirect usermod --append --groups audio openhabian + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups audio openhabian \033[39;49;00m' $ usermod --append --groups audio openhabian + usermod --append --groups audio openhabian + return 0 + for pGroup in "${groups[@]}" + grep -qs '^[[:space:]]*bluetooth:' /etc/group + cond_redirect usermod --append --groups bluetooth openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups bluetooth openhab \033[39;49;00m' $ usermod --append --groups bluetooth openhab + usermod --append --groups bluetooth openhab + return 0 + cond_redirect usermod --append --groups bluetooth openhabian + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups bluetooth openhabian \033[39;49;00m' $ usermod --append --groups bluetooth openhabian + usermod --append --groups bluetooth openhabian + return 0 + for pGroup in "${groups[@]}" + grep -qs '^[[:space:]]*dialout:' /etc/group + cond_redirect usermod --append --groups dialout openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups dialout openhab \033[39;49;00m' $ usermod --append --groups dialout openhab + usermod --append --groups dialout openhab + return 0 + cond_redirect usermod --append --groups dialout openhabian + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups dialout openhabian \033[39;49;00m' $ usermod --append --groups dialout openhabian + usermod --append --groups dialout openhabian + return 0 + for pGroup in "${groups[@]}" + grep -qs '^[[:space:]]*gpio:' /etc/group + cond_redirect usermod --append --groups gpio openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups gpio openhab \033[39;49;00m' $ usermod --append --groups gpio openhab + usermod --append --groups gpio openhab + return 0 + cond_redirect usermod --append --groups gpio openhabian + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups gpio openhabian \033[39;49;00m' $ usermod --append --groups gpio openhabian + usermod --append --groups gpio openhabian + return 0 + for pGroup in "${groups[@]}" + grep -qs '^[[:space:]]*tty:' /etc/group + cond_redirect usermod --append --groups tty openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups tty openhab \033[39;49;00m' $ usermod --append --groups tty openhab + usermod --append --groups tty openhab + return 0 + cond_redirect usermod --append --groups tty openhabian + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups tty openhabian \033[39;49;00m' $ usermod --append --groups tty openhabian + usermod --append --groups tty openhabian + return 0 + cond_redirect usermod --append --groups openhab openhabian + [[ -n '' ]] + echo -e '\n\033[90;01m$ usermod --append --groups openhab openhabian \033[39;49;00m' $ usermod --append --groups openhab openhabian + usermod --append --groups openhab openhabian + return 0 + cond_redirect chown --silent openhab:openhab /srv /opt + [[ -n '' ]] + echo -e '\n\033[90;01m$ chown --silent openhab:openhab /srv /opt \033[39;49;00m' $ chown --silent openhab:openhab /srv /opt + chown --silent openhab:openhab /srv /opt + return 0 + cond_redirect chmod --silent ugo+w /srv + [[ -n '' ]] + echo -e '\n\033[90;01m$ chmod --silent ugo+w /srv \033[39;49;00m' $ chmod --silent ugo+w /srv + chmod --silent ugo+w /srv + return 0 + cond_redirect chown --recursive openhab:openhab /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ chown --recursive openhab:openhab /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab \033[39;49;00m' $ chown --recursive openhab:openhab /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + chown --recursive openhab:openhab /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + return 0 + cond_redirect chmod --recursive u+wX,g+wX /opt /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ chmod --recursive u+wX,g+wX /opt /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab \033[39;49;00m' $ chmod --recursive u+wX,g+wX /opt /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + chmod --recursive u+wX,g+wX /opt /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + return 0 + [[ -d /var/lib/openhab/.ssh ]] + [[ -d /var/lib/openhab/backups ]] + cond_redirect chown openhab:openhab /var/lib/openhab/backups + [[ -n '' ]] + echo -e '\n\033[90;01m$ chown openhab:openhab /var/lib/openhab/backups \033[39;49;00m' $ chown openhab:openhab /var/lib/openhab/backups + chown openhab:openhab /var/lib/openhab/backups + return 0 + cond_redirect chmod g+s /var/lib/openhab/backups + [[ -n '' ]] + echo -e '\n\033[90;01m$ chmod g+s /var/lib/openhab/backups \033[39;49;00m' $ chmod g+s /var/lib/openhab/backups + chmod g+s /var/lib/openhab/backups + return 0 + cond_redirect fix_permissions /home/openhabian openhabian:openhabian + [[ -n '' ]] + echo -e '\n\033[90;01m$ fix_permissions /home/openhabian openhabian:openhabian \033[39;49;00m' $ fix_permissions /home/openhabian openhabian:openhabian + fix_permissions /home/openhabian openhabian:openhabian + [[ -e /home/openhabian ]] + chown openhabian:openhabian /home/openhabian + [[ -n '' ]] + return 0 + return 0 + cond_redirect setfacl --recursive --remove-all /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + [[ -n '' ]] + echo -e '\n\033[90;01m$ setfacl --recursive --remove-all /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab \033[39;49;00m' $ setfacl --recursive --remove-all /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + setfacl --recursive --remove-all /etc/openhab /var/lib/openhab /var/log/openhab /usr/share/openhab + return 0 + cond_redirect fix_permissions /var/log/unattended-upgrades root:root 644 755 + [[ -n '' ]] + echo -e '\n\033[90;01m$ fix_permissions /var/log/unattended-upgrades root:root 644 755 \033[39;49;00m' $ fix_permissions /var/log/unattended-upgrades root:root 644 755 + fix_permissions /var/log/unattended-upgrades root:root 644 755 + [[ -e /var/log/unattended-upgrades ]] + chown root:root /var/log/unattended-upgrades + [[ -n 644 ]] + [[ -f /var/log/unattended-upgrades ]] + [[ -n 755 ]] + [[ -d /var/log/unattended-upgrades ]] + find /var/log/unattended-upgrades -type d -print0 + xargs -0 chmod 755 + return 0 + return 0 + cond_redirect fix_permissions /var/log/samba root:root 640 750 + [[ -n '' ]] + echo -e '\n\033[90;01m$ fix_permissions /var/log/samba root:root 640 750 \033[39;49;00m' $ fix_permissions /var/log/samba root:root 640 750 + fix_permissions /var/log/samba root:root 640 750 + [[ -e /var/log/samba ]] + chown root:root /var/log/samba + [[ -n 640 ]] + [[ -f /var/log/samba ]] + [[ -n 750 ]] + [[ -d /var/log/samba ]] + find /var/log/samba -type d -print0 + xargs -0 chmod 750 + return 0 + return 0 + cond_redirect fix_permissions /var/log/openhab openhab:openhabian 664 775 + [[ -n '' ]] + echo -e '\n\033[90;01m$ fix_permissions /var/log/openhab openhab:openhabian 664 775 \033[39;49;00m' $ fix_permissions /var/log/openhab openhab:openhabian 664 775 + fix_permissions /var/log/openhab openhab:openhabian 664 775 + [[ -e /var/log/openhab ]] + chown openhab:openhabian /var/log/openhab + [[ -n 664 ]] + [[ -f /var/log/openhab ]] + [[ -n 775 ]] + [[ -d /var/log/openhab ]] + find /var/log/openhab -type d -print0 + xargs -0 chmod 775 + return 0 + return 0 + mosquitto_is_installed + dpkg -s mosquitto mosquitto-clients + return 1 + zram_is_installed + [[ -s /etc/ztab ]] + [[ -d /opt/zram ]] + return 0 + influxdb_is_installed + dpkg -s influxdb + return 1 + grafana_is_installed + dpkg -s grafana + return 1 + mosquitto_is_installed + dpkg -s mosquitto mosquitto-clients + return 1 + cond_redirect fix_permissions /opt/zram/log.bind/samba root:root 640 750 + [[ -n '' ]] + echo -e '\n\033[90;01m$ fix_permissions /opt/zram/log.bind/samba root:root 640 750 \033[39;49;00m' $ fix_permissions /opt/zram/log.bind/samba root:root 640 750 + fix_permissions /opt/zram/log.bind/samba root:root 640 750 + [[ -e /opt/zram/log.bind/samba ]] + chown root:root /opt/zram/log.bind/samba + [[ -n 640 ]] + [[ -f /opt/zram/log.bind/samba ]] + [[ -n 750 ]] + [[ -d /opt/zram/log.bind/samba ]] + xargs -0 chmod 750 + find /opt/zram/log.bind/samba -type d -print0 + return 0 + return 0 + cond_redirect fix_permissions /opt/zram/log.bind/openhab openhab:openhabian 664 775 + [[ -n '' ]] + echo -e '\n\033[90;01m$ fix_permissions /opt/zram/log.bind/openhab openhab:openhabian 664 775 \033[39;49;00m' $ fix_permissions /opt/zram/log.bind/openhab openhab:openhabian 664 775 + fix_permissions /opt/zram/log.bind/openhab openhab:openhabian 664 775 + [[ -e /opt/zram/log.bind/openhab ]] + chown openhab:openhabian /opt/zram/log.bind/openhab + [[ -n 664 ]] + [[ -f /opt/zram/log.bind/openhab ]] + [[ -n 775 ]] + [[ -d /opt/zram/log.bind/openhab ]] + xargs -0 chmod 775 + find /opt/zram/log.bind/openhab -type d -print0 + return 0 + return 0 + cond_redirect fix_permissions /opt/zram/persistence.bind openhab:openhabian 664 775 + [[ -n '' ]] + echo -e '\n\033[90;01m$ fix_permissions /opt/zram/persistence.bind openhab:openhabian 664 775 \033[39;49;00m' $ fix_permissions /opt/zram/persistence.bind openhab:openhabian 664 775 + fix_permissions /opt/zram/persistence.bind openhab:openhabian 664 775 + [[ -e /opt/zram/persistence.bind ]] + chown openhab:openhabian /opt/zram/persistence.bind + [[ -n 664 ]] + [[ -f /opt/zram/persistence.bind ]] + [[ -n 775 ]] + [[ -d /opt/zram/persistence.bind ]] + find /opt/zram/persistence.bind -type d -print0 + xargs -0 chmod 775 + return 0 + return 0 + echo OK OK + homegear_is_installed + dpkg -s homegear + return 1 + [[ -d /opt/habapp ]] + return 0 + '[' 0 -ne 0 ']' + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice= + RET=1 + '[' 1 -eq 1 ']' + return 255 + system_check_default_password + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + local algo + local defaultPassword + local defaultUser + local generatedPassword + local introText + local originalPassword + local salt + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + id -u pi + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + defaultUser=openhabian + defaultPassword=openhabian ++ grep -w openhabian /etc/shadow ++ cut -d: -f2 + originalPassword='$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f2 + algo=y + introText='The default password was detected on your system! That is a serious security concern. Bad guys or malicious programs in your subnet are able to gain root access!\n\nPlease set a strong password by typing the command '\''passwd openhabian'\''!' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f3 + salt=j9T + export algo defaultPassword salt ++ perl -le 'print crypt("$ENV{defaultPassword}","\$$ENV{algo}\$$ENV{salt}\$")' + generatedPassword='$y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA' ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:54:18_CET [openHABian] Checking for default openHABian username:password combination... ' 2022-01-25_19:54:18_CET [openHABian] Checking for default openHABian username:password combination... ++ id -u openhabian + [[ -n 1000 ]] + [[ $y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA == \$\y\$\j\9\T\$\Q\R\t\E\2\O\.\Q\S\Y\H\l\o\E\Z\n\r\j\v\G\R\/\$\N\8\f\i\E\k\r\p\u\x\e\B\P\R\G\K\o\6\u\2\t\q\5\y\L\u\l\L\f\x\D\W\R\d\i\v\Q\r\/\y\k\g\0 ]] + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -e '2022-01-25_19:54:18_CET [openHABian] We hope you got what you came for! See you again soon ;)' 2022-01-25_19:54:18_CET [openHABian] We hope you got what you came for! See you again soon ;) + cd /opt/openhabian 2022-01-25_19:56:28_CET [openHABian] Checking for root privileges... OK + export UNATTENDED SILENT DEBUGMAX INTERACTIVE + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/auth.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/backup.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/config.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/ext-storage.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/find.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/habapp.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/helpers.bash ++ ESC='\033[' ++ COL_DEF='\033[39;49;00m' ++ COL_RED='\033[31;01m' ++ COL_GREEN='\033[32;01m' ++ COL_YELLOW='\033[33;01m' ++ COL_BLUE='\033[34;01m' ++ COL_MAGENTA='\033[35;01m' ++ COL_CYAN='\033[36;01m' ++ COL_LGRAY='\033[37;01m' ++ COL_DGRAY='\033[90;01m' ++ export COL_DEF COL_RED COL_GREEN COL_YELLOW COL_BLUE COL_MAGENTA COL_CYAN COL_LGRAY COL_DGRAY + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/influxdb+grafana.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/java-jre.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/menu.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/nodejs-apps.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhab.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhabian.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/packages.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/system.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/vpn.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/wifi.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/zram.bash ++ pwd + OLDWD=/opt/openhabian + cd /opt + update_openhabian_conf + local configFile=/etc/openhabian.conf + local referenceConfig=/opt/openhabian/build-image/openhabian.conf + cp /etc/openhabian.conf /etc/openhabian.conf.BAK + read -r line + [[ # Origin: openhabian.conf =~ ^(#)?[a-zA-Z] ]] + echo '# Origin: openhabian.conf' + read -r line + [[ # =~ ^(#)?[a-zA-Z] ]] + echo '#' + read -r line + [[ # Modify your openHABian settings =~ ^(#)?[a-zA-Z] ]] + echo '# Modify your openHABian settings' + read -r line + [[ # Handle with care, only touch if you need to! =~ ^(#)?[a-zA-Z] ]] + echo '# Handle with care, only touch if you need to!' + read -r line + [[ # This file will only be used on unattended initial install. =~ ^(#)?[a-zA-Z] ]] + echo '# This file will only be used on unattended initial install.' + read -r line + [[ # If you want to change anything after unattended install completed, use menu in openhabian-config. =~ ^(#)?[a-zA-Z] ]] + echo '# If you want to change anything after unattended install completed, use menu in openhabian-config.' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # ATTENTION: to disable an option a line MUST be of the format '# option=value' =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: to disable an option a line MUST be of the format '\''# option=value'\''' + read -r line + [[ # KEEP THE SPACE IT IS IMPORTANT !! =~ ^(#)?[a-zA-Z] ]] + echo '# KEEP THE SPACE IT IS IMPORTANT !!' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hostname to set this one to =~ ^(#)?[a-zA-Z] ]] + echo '# Hostname to set this one to' + read -r line + [[ hostname=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hostname=openhabian + [[ hostname=openhabian =~ ^#[a-zA-Z] ]] ++ echo hostname=openhabian ++ cut -d= -f1 + param=hostname + [[ -v hostname ]] + [[ openhabian == *\ * ]] + echo hostname=openhabian + read -r line + [[ # if it exists, the default user (with its working environment) will be renamed to this username given here ... =~ ^(#)?[a-zA-Z] ]] + echo '# if it exists, the default user (with its working environment) will be renamed to this username given here ...' + read -r line + [[ username=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=username=openhabian + [[ username=openhabian =~ ^#[a-zA-Z] ]] ++ echo username=openhabian ++ cut -d= -f1 + param=username + [[ -v username ]] + [[ openhabian == *\ * ]] + echo username=openhabian + read -r line + [[ # ... and given this password. The password will be removed from this file after completion for security reasons. =~ ^(#)?[a-zA-Z] ]] + echo '# ... and given this password. The password will be removed from this file after completion for security reasons.' + read -r line + [[ userpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=userpw=openhabian + [[ userpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo userpw=openhabian ++ cut -d= -f1 + param=userpw + [[ -v userpw ]] + [[ openhabian == *\ * ]] + echo userpw=openhabian + read -r line + [[ # set this to download a SSH key and authorize the owner to login as the admin user =~ ^(#)?[a-zA-Z] ]] + echo '# set this to download a SSH key and authorize the owner to login as the admin user' + read -r line + [[ adminkeyurl="" =~ ^(#)?[a-zA-Z] ]] + parsed='adminkeyurl=""' + [[ adminkeyurl="" =~ ^#[a-zA-Z] ]] ++ echo 'adminkeyurl=""' ++ cut -d= -f1 + param=adminkeyurl + [[ -v adminkeyurl ]] + [[ '' == *\ * ]] + echo adminkeyurl= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Language and timezone. See Debian documentation for valid values. =~ ^(#)?[a-zA-Z] ]] + echo '# Language and timezone. See Debian documentation for valid values.' + read -r line + [[ timezone=Europe/Berlin =~ ^(#)?[a-zA-Z] ]] + parsed=timezone=Europe/Berlin + [[ timezone=Europe/Berlin =~ ^#[a-zA-Z] ]] ++ echo timezone=Europe/Berlin ++ cut -d= -f1 + param=timezone + [[ -v timezone ]] + [[ Europe/Berlin == *\ * ]] + echo timezone=Europe/Berlin + read -r line + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='locales="en_US.UTF-8 de_DE.UTF-8"' + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'locales="en_US.UTF-8 de_DE.UTF-8"' ++ cut -d= -f1 + param=locales + [[ -v locales ]] + [[ en_US.UTF-8 de_DE.UTF-8 == *\ * ]] + echo 'locales="en_US.UTF-8 de_DE.UTF-8"' + read -r line + [[ system_default_locale="en_US.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='system_default_locale="en_US.UTF-8"' + [[ system_default_locale="en_US.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'system_default_locale="en_US.UTF-8"' ++ cut -d= -f1 + param=system_default_locale + [[ -v system_default_locale ]] + [[ en_US.UTF-8 == *\ * ]] + echo system_default_locale=en_US.UTF-8 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # WiFi settings. An ethernet connection is recommended. =~ ^(#)?[a-zA-Z] ]] + echo '# WiFi settings. An ethernet connection is recommended.' + read -r line + [[ # If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi =~ ^(#)?[a-zA-Z] ]] + echo '# If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi' + read -r line + [[ # interface can be setup and used for the initial installation. =~ ^(#)?[a-zA-Z] ]] + echo '# interface can be setup and used for the initial installation.' + read -r line + [[ # Fill in your SSID and password below, leave empty or put comment in front to =~ ^(#)?[a-zA-Z] ]] + echo '# Fill in your SSID and password below, leave empty or put comment in front to' + read -r line + [[ # have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works. =~ ^(#)?[a-zA-Z] ]] + echo '# have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works.' + read -r line + [[ # ATTENTION: you need to escape these special characters: $, `, ", \, (newline) =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: you need to escape these special characters: $, `, ", \, (newline)' + read -r line + [[ # 'Escaping' means to put an additional \ in front of that character =~ ^(#)?[a-zA-Z] ]] + echo '# '\''Escaping'\'' means to put an additional \ in front of that character' + read -r line + [[ wifi_ssid="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_ssid=""' + [[ wifi_ssid="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_ssid=""' ++ cut -d= -f1 + param=wifi_ssid + [[ -v wifi_ssid ]] + [[ '' == *\ * ]] + echo wifi_ssid= + read -r line + [[ wifi_password="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_password=""' + [[ wifi_password="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_password=""' ++ cut -d= -f1 + param=wifi_password + [[ -v wifi_password ]] + [[ '' == *\ * ]] + echo wifi_password= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Wi-Fi setting. Select a two-letter country code suitable for your location =~ ^(#)?[a-zA-Z] ]] + echo '# Wi-Fi setting. Select a two-letter country code suitable for your location' + read -r line + [[ # E.g. US (default), DE, AU, NZ... =~ ^(#)?[a-zA-Z] ]] + echo '# E.g. US (default), DE, AU, NZ...' + read -r line + [[ # You may infringe on local legislature otherwise =~ ^(#)?[a-zA-Z] ]] + echo '# You may infringe on local legislature otherwise' + read -r line + [[ # See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab =~ ^(#)?[a-zA-Z] ]] + echo '# See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab' + read -r line + [[ wifi_country="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_country=""' + [[ wifi_country="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_country=""' ++ cut -d= -f1 + param=wifi_country + [[ -v wifi_country ]] + [[ '' == *\ * ]] + echo wifi_country= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Eventually disable all IPv6 e.g. on installation problems =~ ^(#)?[a-zA-Z] ]] + echo '# Eventually disable all IPv6 e.g. on installation problems' + read -r line + [[ # values: "enable", "disable" =~ ^(#)?[a-zA-Z] ]] + echo '# values: "enable", "disable"' + read -r line + [[ ipv6=enable =~ ^(#)?[a-zA-Z] ]] + parsed=ipv6=enable + [[ ipv6=enable =~ ^#[a-zA-Z] ]] ++ echo ipv6=enable ++ cut -d= -f1 + param=ipv6 + [[ -v ipv6 ]] + [[ enable == *\ * ]] + echo ipv6=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # repo and branch to clone from =~ ^(#)?[a-zA-Z] ]] + echo '# repo and branch to clone from' + read -r line + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^(#)?[a-zA-Z] ]] + parsed=repositoryurl=https://github.com/openhab/openhabian.git + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^#[a-zA-Z] ]] ++ echo repositoryurl=https://github.com/openhab/openhabian.git ++ cut -d= -f1 + param=repositoryurl + [[ -v repositoryurl ]] + [[ https://github.com/openhab/openhabian == *\ * ]] + echo repositoryurl=https://github.com/openhab/openhabian + read -r line + [[ clonebranch=openHAB3 =~ ^(#)?[a-zA-Z] ]] + parsed=clonebranch=openHAB3 + [[ clonebranch=openHAB3 =~ ^#[a-zA-Z] ]] ++ echo clonebranch=openHAB3 ++ cut -d= -f1 + param=clonebranch + [[ -v clonebranch ]] + [[ openHAB3 == *\ * ]] + echo clonebranch=openHAB3 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # initial openHAB configuration to import (URL or filename) =~ ^(#)?[a-zA-Z] ]] + echo '# initial openHAB configuration to import (URL or filename)' + read -r line + [[ # the file needs to be a zip archive created from openhab-cli backup =~ ^(#)?[a-zA-Z] ]] + echo '# the file needs to be a zip archive created from openhab-cli backup' + read -r line + [[ # initialconfig=/boot/initial.zip =~ ^(#)?[a-zA-Z] ]] + echo '# initialconfig=/boot/initial.zip' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # debug verbosity mode =~ ^(#)?[a-zA-Z] ]] + echo '# debug verbosity mode' + read -r line + [[ # off, on (verbose output in log) or maximum (show every command) =~ ^(#)?[a-zA-Z] ]] + echo '# off, on (verbose output in log) or maximum (show every command)' + read -r line + [[ debugmode=off =~ ^(#)?[a-zA-Z] ]] + parsed=debugmode=off + [[ debugmode=off =~ ^#[a-zA-Z] ]] ++ echo debugmode=off ++ cut -d= -f1 + param=debugmode + [[ -v debugmode ]] + [[ maximum == *\ * ]] + echo debugmode=maximum + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # the framebuffer on RPi is enabled by default =~ ^(#)?[a-zA-Z] ]] + echo '# the framebuffer on RPi is enabled by default' + read -r line + [[ framebuffer=enable =~ ^(#)?[a-zA-Z] ]] + parsed=framebuffer=enable + [[ framebuffer=enable =~ ^#[a-zA-Z] ]] ++ echo framebuffer=enable ++ cut -d= -f1 + param=framebuffer + [[ -v framebuffer ]] + [[ enable == *\ * ]] + echo framebuffer=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # fake hardware =~ ^(#)?[a-zA-Z] ]] + echo '# fake hardware' + read -r line + [[ # force treating your box as if it was a ... =~ ^(#)?[a-zA-Z] ]] + echo '# force treating your box as if it was a ...' + read -r line + [[ # pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86 =~ ^(#)?[a-zA-Z] ]] + echo '# pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86' + read -r line + [[ # hw= =~ ^(#)?[a-zA-Z] ]] + echo '# hw=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hardware architecture =~ ^(#)?[a-zA-Z] ]] + echo '# Hardware architecture' + read -r line + [[ # x86_64, amd64, armv6l, armv7l, aarch64, arm64 =~ ^(#)?[a-zA-Z] ]] + echo '# x86_64, amd64, armv6l, armv7l, aarch64, arm64' + read -r line + [[ # hwarch= =~ ^(#)?[a-zA-Z] ]] + echo '# hwarch=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # OS distribution/release =~ ^(#)?[a-zA-Z] ]] + echo '# OS distribution/release' + read -r line + [[ # Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal =~ ^(#)?[a-zA-Z] ]] + echo '# Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal' + read -r line + [[ # osrelease= =~ ^(#)?[a-zA-Z] ]] + echo '# osrelease=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Java version to install =~ ^(#)?[a-zA-Z] ]] + echo '# Java version to install' + read -r line + [[ java_opt=11 =~ ^(#)?[a-zA-Z] ]] + parsed=java_opt=11 + [[ java_opt=11 =~ ^#[a-zA-Z] ]] ++ echo java_opt=11 ++ cut -d= -f1 + param=java_opt + [[ -v java_opt ]] + [[ 11 == *\ * ]] + echo java_opt=11 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # install zram per default, set to "disable" to skip installation =~ ^(#)?[a-zA-Z] ]] + echo '# install zram per default, set to "disable" to skip installation' + read -r line + [[ zraminstall=enable =~ ^(#)?[a-zA-Z] ]] + parsed=zraminstall=enable + [[ zraminstall=enable =~ ^#[a-zA-Z] ]] ++ echo zraminstall=enable ++ cut -d= -f1 + param=zraminstall + [[ -v zraminstall ]] + [[ enable == *\ * ]] + echo zraminstall=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # start comitup hotspot if internet is not reachable =~ ^(#)?[a-zA-Z] ]] + echo '# start comitup hotspot if internet is not reachable' + read -r line + [[ hotspot=enable =~ ^(#)?[a-zA-Z] ]] + parsed=hotspot=enable + [[ hotspot=enable =~ ^#[a-zA-Z] ]] ++ echo hotspot=enable ++ cut -d= -f1 + param=hotspot + [[ -v hotspot ]] + [[ enable == *\ * ]] + echo hotspot=enable + read -r line + [[ hotspotpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hotspotpw=openhabian + [[ hotspotpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo hotspotpw=openhabian ++ cut -d= -f1 + param=hotspotpw + [[ -v hotspotpw ]] + [[ openhabian == *\ * ]] + echo hotspotpw=openhabian + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # external SD card device to backup and mirror the internal SD card to =~ ^(#)?[a-zA-Z] ]] + echo '# external SD card device to backup and mirror the internal SD card to' + read -r line + [[ # backupdrive=/dev/sda =~ ^(#)?[a-zA-Z] ]] + echo '# backupdrive=/dev/sda' + read -r line + [[ storageconfig=openhab-dir =~ ^(#)?[a-zA-Z] ]] + parsed=storageconfig=openhab-dir + [[ storageconfig=openhab-dir =~ ^#[a-zA-Z] ]] ++ echo storageconfig=openhab-dir ++ cut -d= -f1 + param=storageconfig + [[ -v storageconfig ]] + [[ openhab-dir == *\ * ]] + echo storageconfig=openhab-dir + read -r line + [[ storagedir=/storage =~ ^(#)?[a-zA-Z] ]] + parsed=storagedir=/storage + [[ storagedir=/storage =~ ^#[a-zA-Z] ]] ++ echo storagedir=/storage ++ cut -d= -f1 + param=storagedir + [[ -v storagedir ]] + [[ /storage == *\ * ]] + echo storagedir=/storage + read -r line + [[ storagetapes=15 =~ ^(#)?[a-zA-Z] ]] + parsed=storagetapes=15 + [[ storagetapes=15 =~ ^#[a-zA-Z] ]] ++ echo storagetapes=15 ++ cut -d= -f1 + param=storagetapes + [[ -v storagetapes ]] + [[ 15 == *\ * ]] + echo storagetapes=15 + read -r line + [[ storagecapacity=1024 =~ ^(#)?[a-zA-Z] ]] + parsed=storagecapacity=1024 + [[ storagecapacity=1024 =~ ^#[a-zA-Z] ]] ++ echo storagecapacity=1024 ++ cut -d= -f1 + param=storagecapacity + [[ -v storagecapacity ]] + [[ 1024 == *\ * ]] + echo storagecapacity=1024 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # mail relay settings =~ ^(#)?[a-zA-Z] ]] + echo '# mail relay settings' + read -r line + [[ # adminmail=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# adminmail=john.doe@foo.bar' + read -r line + [[ # relayuser=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# relayuser=john.doe@foo.bar' + read -r line + [[ # relaypass=secret =~ ^(#)?[a-zA-Z] ]] + echo '# relaypass=secret' + read -r line + [[ # smarthost=smtp.gmail.com =~ ^(#)?[a-zA-Z] ]] + echo '# smarthost=smtp.gmail.com' + read -r line + [[ # smartport=587 =~ ^(#)?[a-zA-Z] ]] + echo '# smartport=587' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Tailscale VPN =~ ^(#)?[a-zA-Z] ]] + echo '# Tailscale VPN' + read -r line + [[ # preauthkey=tskey-xxxxxxxxxxxxxxxxx =~ ^(#)?[a-zA-Z] ]] + echo '# preauthkey=tskey-xxxxxxxxxxxxxxxxx' + read -r line + [[ # tstags=tag:client =~ ^(#)?[a-zA-Z] ]] + echo '# tstags=tag:client' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Custom log files =~ ^(#)?[a-zA-Z] ]] + echo '# Custom log files' + read -r line + [[ # custom_log_files=("/var/log/foo.log" "/var/log/bar.log") =~ ^(#)?[a-zA-Z] ]] + echo '# custom_log_files=("/var/log/foo.log" "/var/log/bar.log")' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # vim: filetype=sh =~ ^(#)?[a-zA-Z] ]] + echo '# vim: filetype=sh' + read -r line + set_cpu_speed + is_raspios + [[ '' == \r\a\s\p\i\o\s ]] + is_raspbian + [[ '' == \r\a\s\p\b\i\a\n ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ Raspbian ]] + return 0 + return 0 + running_in_docker + [[ -n '' ]] + grep -qs 'docker\|lxc' /proc/1/cgroup + [[ -f /.dockerenv ]] + return 1 + echo 'GOVERNOR="ondemand"' + echo ondemand + config_ipv6 + local aptConf=/etc/apt/apt.conf.d/S90force-ipv4 + local sysctlConf=/etc/sysctl.d/99-sysctl.conf + [[ enable == \d\i\s\a\b\l\e ]] + [[ enable == \e\n\a\b\l\e ]] + grep -qs '^[[:space:]]*# Disable all IPv6 functionality' /etc/sysctl.d/99-sysctl.conf + [[ -n '' ]] + apt_update + PID_APT=3209 + whiptail_check + apt-get update ++ command -v whiptail + [[ -x /usr/bin/whiptail ]] + load_create_config + local 'questionText=\nWelcome to openHABian!\n\nPlease provide the name of your Linux user i.e. the account you normally log in with.\n\nTypical user names are '\''pi'\'' or '\''ubuntu'\''.' + local input + [[ -f /etc/openhabian.conf ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:56:28_CET [openHABian] Loading configuration file '\''/etc/openhabian.conf'\''... ' 2022-01-25_19:56:28_CET [openHABian] Loading configuration file '/etc/openhabian.conf'... ++ getent group openhabian + [[ ! -n openhabian:x:1000:openhabian,frontail ]] + id -u openhabian + source /etc/openhabian.conf ++ hostname=openhabian ++ username=openhabian ++ userpw=openhabian ++ adminkeyurl= ++ timezone=Europe/Berlin ++ locales='en_US.UTF-8 de_DE.UTF-8' ++ system_default_locale=en_US.UTF-8 ++ wifi_ssid= ++ wifi_password= ++ wifi_country= ++ ipv6=enable ++ repositoryurl=https://github.com/openhab/openhabian ++ clonebranch=openHAB3 ++ debugmode=maximum ++ framebuffer=enable ++ java_opt=11 ++ zraminstall=enable ++ hotspot=enable ++ hotspotpw=openhabian ++ storageconfig=openhab-dir ++ storagedir=/storage ++ storagetapes=15 ++ storagecapacity=1024 + echo OK OK + openhabian_console_check + [[ -z 1 ]] ++ tput cols + [[ 237 -ge 120 ]] + return 0 + openhabian_update_check + [[ -z 1 ]] + local branch + local introText + local unsupportedOSText + branch=openHAB3 + introText='Additions, improvements or fixes were added to the openHABian configuration tool. Would you like to update now and benefit from them? The update will not automatically apply changes to your system.\n\nUpdating is recommended.' + unsupportedOSText='You are running an old Linux release that is no longer officially supported.\nWe recommend upgrading to the most current stable release of your distribution (or current Long Term Support version for distributions that offer LTS).\nDo you really want to continue using openHABian on this system?' ++ timestamp ++ date +%F_%T_%Z ++ get_git_revision ++ local branch ++ local commitDate ++ local shorthash +++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD ++ branch=openHAB3 +++ git -C /opt/openhabian log --pretty=format:%aI -n 1 ++ commitDate=2022-01-24T16:28:12-07:00 +++ git -C /opt/openhabian log --pretty=format:%h -n 1 ++ shorthash=08bc4ff ++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' + echo '2022-01-25_19:56:28_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' 2022-01-25_19:56:28_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff) ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:56:28_CET [openHABian] Checking for changes in origin branch openHAB3... ' 2022-01-25_19:56:28_CET [openHABian] Checking for changes in origin branch openHAB3... + is_stretch + [[ '' == \s\t\r\e\t\c\h ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ stretch ]] + return 1 + is_xenial + [[ '' == \x\e\n\i\a\l ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ xenial ]] + return 1 + git -C /opt/openhabian config user.email openhabian@openHABian + git -C /opt/openhabian config user.name openhabian + git -C /opt/openhabian fetch --quiet origin ++ git -C /opt/openhabian rev-parse openHAB3 ++ git -C /opt/openhabian rev-parse '@{u}' + [[ 08bc4ff34e8b7b059c126b6b999039cef7b48d33 == 08bc4ff34e8b7b059c126b6b999039cef7b48d33 ]] + echo OK OK + openhabian_announcements + [[ -z 1 ]] + local altReadNews + local newsFile + local readNews + altReadNews=/tmp/NEWS.md + newsFile=/opt/openhabian/NEWS.md + readNews=/opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /tmp/NEWS.md ++ cat /opt/openhabian/NEWS.md + whiptail --title 'openHABian announcements' --yes-button 'Stop displaying' --no-button 'Keep displaying' --defaultno --scrolltext --yesno 'Hit tab to unselect buttons and scroll through the text using UP/DOWN or PGUP/PGDN. All announcements are stored in `/opt/openhabian/docs/CHANGELOG.md` for you to lookup. ## Major Java provider switch ## December 15, 2021 We have switched to supporting only the OpenJDK package provided by default from the APT repo for all new installations of openHABian. Existing installations will be unaffected, however you will no longer receive updates to your current Java install until you install Java from the new provider which you can do by running menu option 45. Experimental support for Java 17 has also been added along with this change. In the future once Adoptium (formerly AdoptOpenJDK) releases a Debian based package repository support for Adoptium Java installs will be added as well. ## Node-RED and openHAB 3 ## December 10, 2021 We have updated the package of the Node-RED addon for openHAB 3 to `node-red-contrib-openhab3` to better support openHAB 3 installations which use this addon. You can install it today using `openhabian-config` menu option 25, which will install / upgrade all necessary components for Node-RED operation. ## openHABian 1.7 ## December 1, 2021 We have upgraded our base operating system to Raspberry Pi OS Bullseye. As usual upgrades on supported systems will be unaffected, use the `openhabian-config` menu to apply any updates available to your system. We will not automatically update your current base system (i.e buster -> bullseye) - don'\''t fix what ain'\''t broke. Debian buster will be at least supported two more years. If you are eager to upgrade, read up on `dist-upgrade` or reinstall your system. Please note that if you choose to upgrade and not reinstall, you are on your own, don'\''t expect to get support from the developers of openHABian if something goes wrong. Noteworthy changes since last image release: * New base OS: Raspberry Pi OS Bullseye * Added support for Raspberry Pi Zero 2 W * Ability to update zram without reinstalling it * More robust Java install routine * Fixed Amanda install not prompting for email address to send reports to * General bug fixes Known bugs: * Homegear is currently broken on Bullseye (complain to their devs)' 27 84 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:56:31_CET [openHABian] Switching to branch openHAB3... ' 2022-01-25_19:56:31_CET [openHABian] Switching to branch openHAB3... + git -C /opt/openhabian checkout --quiet openHAB3 + echo OK OK + bashrc_copy ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:56:31_CET [openHABian] Adding slightly tuned bash configuration files to system... ' 2022-01-25_19:56:31_CET [openHABian] Adding slightly tuned bash configuration files to system... + cp /opt/openhabian/includes/generic/bash.bashrc /etc/bash.bashrc + cp /opt/openhabian/includes/generic/bashrc-root /root/.bashrc + cp /opt/openhabian/includes/generic/bash_profile /home/openhabian/.bash_profile + cp /opt/openhabian/includes/generic/bash_aliases /home/openhabian/.bash_aliases + chown openhabian:openhabian /home/openhabian/.bash_aliases /home/openhabian/.bash_history /home/openhabian/.bash_logout /home/openhabian/.bash_profile + echo OK OK + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='10 | Apply Improvements' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 10 | Apply Improvements == '' ]] + [[ 10 | Apply Improvements == \0\0* ]] + [[ 10 | Apply Improvements == \0\1* ]] + [[ 10 | Apply Improvements == \0\2* ]] + [[ 10 | Apply Improvements == \0\3* ]] + [[ 10 | Apply Improvements == \0\4* ]] + [[ 10 | Apply Improvements == \1\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Apply Improvements' 13 116 6 --cancel-button Back --ok-button Execute '11 | Packages' 'Install needed and recommended system packages' '12 | Bash&Vim Settings' 'Update customized openHABian settings for bash, vim and nano' '13 | System Tweaks' 'Add /srv mounts and update settings typical for openHAB' '14 | Fix Permissions' 'Update file permissions of commonly used files and folders' '15 | FireMotD' 'Upgrade the program behind the system overview on SSH login' '16 | Samba' 'Install the Samba file sharing service and set up openHAB shares' + choice2= + '[' 1 -eq 1 ']' + return 0 + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='20 | Optional Components' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 20 | Optional Components == '' ]] + [[ 20 | Optional Components == \0\0* ]] + [[ 20 | Optional Components == \0\1* ]] + [[ 20 | Optional Components == \0\2* ]] + [[ 20 | Optional Components == \0\3* ]] + [[ 20 | Optional Components == \0\4* ]] + [[ 20 | Optional Components == \1\0* ]] + [[ 20 | Optional Components == \2\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Optional Components' 22 118 15 --cancel-button Back --ok-button Execute '21 | Log Viewer' 'openHAB Log Viewer webapp (frontail)' ' | Add log to viewer' 'Add a custom log to openHAB Log Viewer (frontail)' ' | Remove log from viewer' 'Remove a custom log from openHAB Log Viewer (frontail)' '22 | miflora-mqtt-daemon' 'Xiaomi Mi Flora Plant Sensor MQTT Client/Daemon' '23 | Mosquitto' 'MQTT broker Eclipse Mosquitto' '24 | InfluxDB+Grafana' 'A powerful persistence and graphing solution' '25 | Node-RED' 'Flow-based programming for the Internet of Things' '26 | Homegear' 'Homematic specific, the CCU2 emulation software Homegear' '27 | knxd' 'KNX specific, the KNX router/gateway daemon knxd' '28 | 1wire' '1wire specific, owserver and related packages' '29 | deCONZ' 'deCONZ / Phoscon companion app for Conbee/Raspbee controller' '2A | FIND 3' 'Framework for Internal Navigation and Discovery' ' | Monitor Mode' 'Patch firmware to enable monitor mode (ALPHA/DANGEROUS)' '2B | Install HABApp' 'Python 3 integration and rule engine for openHAB' ' | Remove HABApp' 'Remove HABApp from this system' + choice2= + '[' 1 -eq 1 ']' + return 0 + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='30 | System Settings' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 30 | System Settings == '' ]] + [[ 30 | System Settings == \0\0* ]] + [[ 30 | System Settings == \0\1* ]] + [[ 30 | System Settings == \0\2* ]] + [[ 30 | System Settings == \0\3* ]] + [[ 30 | System Settings == \0\4* ]] + [[ 30 | System Settings == \1\0* ]] + [[ 30 | System Settings == \2\0* ]] + [[ 30 | System Settings == \3\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' +++ hostname +++ env +++ grep '^[[:space:]]*LANG=' +++ sed 's|LANG=||g' +++ date +%H:%M ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'System Settings' 26 118 19 --cancel-button Back --ok-button Execute '31 | Change hostname' 'Change the name of this system, currently '\''openhabian'\''' '32 | Set system locale' 'Change system language, currently '\''de_DE.UTF-8'\''' '33 | Set system timezone' 'Change your timezone, execute if it'\''s not '\''19:56'\'' now' ' | Enable NTP' 'Enable time synchronization via systemd-timesyncd to NTP servers' ' | Disable NTP' 'Disable time synchronization via systemd-timesyncd to NTP servers' '34 | Change passwords' 'Change passwords for Samba, openHAB Console or the system user' '35 | Serial port' 'Prepare serial ports for peripherals like RaZberry, ZigBee adapters etc' '36 | Disable framebuffer' 'Disable framebuffer on RPi to minimize memory usage' ' | Enable framebuffer' 'Enable framebuffer (standard setting)' '37 | WiFi setup' 'Configure wireless network connection' ' | Disable WiFi' 'Disable wireless network connection' '38 | Use zram' 'Use compressed RAM/disk sync for active directories to avoid SD card corruption' ' | Update zram' 'Update a currently installed zram instance' ' | Uninstall zram' 'Don'\''t use compressed memory (back to standard Raspberry Pi OS filesystem layout)' '39 | Move root to USB' 'Move the system root from the SD card to a USB device (SSD or stick)' '3A | Setup Exim Mail Relay' 'Install Exim4 to relay mails via public email provider' '3B | Setup Tailscale VPN' 'Establish or join a WireGuard based VPN using the Tailscale service' ' | Remove Tailscale VPN' 'Remove the Tailscale VPN service' ' | Install WireGuard' 'Setup WireGuard to enable secure remote access to this openHABian system' ' | Remove WireGuard' 'Remove WireGuard VPN from this system' + choice2='38 | Use zram' + '[' 0 -eq 1 ']' + '[' 1 -eq 255 ']' + wait_for_apt_to_finish_update ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:56:51_CET [openHABian] Updating Linux package information... ' 2022-01-25_19:56:51_CET [openHABian] Updating Linux package information... + [[ -z 3209 ]] + tail --pid=3209 -f /dev/null + echo OK OK + case "$choice2" in + init_zram_mounts install + is_arm + is_armv6l + [[ '' == \a\r\m\v\6\l ]] + case "$(uname -m)" in ++ uname -m + return 1 + is_armv7l + [[ '' == \a\r\m\v\7\l ]] + case "$(uname -m)" in ++ uname -m + return 0 + return 0 + local 'introText=You are about to activate the zram feature.\nBe aware you do this at your own risk of data loss.\nPlease check out the "zram status" thread at https://community.openhab.org/t/zram-status/80996 before proceeding.' + local 'lowMemText=Your system has less than 1 GB of RAM. It is definitely NOT recommended to run zram (AND openHAB) on your box. If you proceed now you will do so at your own risk!' + local zramInstallLocation=/opt/zram + [[ install == \i\n\s\t\a\l\l ]] + [[ -f /etc/ztab ]] + [[ install == \u\n\i\n\s\t\a\l\l ]] + [[ -f /etc/ztab ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:56:51_CET [openHABian] Updating zram service... ' 2022-01-25_19:56:51_CET [openHABian] Updating zram service... + cond_redirect zram-config stop + [[ -n '' ]] + echo -e '\n\033[90;01m$ zram-config stop \033[39;49;00m' $ zram-config stop + zram-config stop Failed to kill zram-config.service. Exiting! + return 1 + echo 'FAILED (stop zram)' FAILED (stop zram) + return 1 + '[' 1 -ne 0 ']' + whiptail --msgbox 'There was an error or interruption during the execution of:\n "30 | System Settings"\n\nPlease try again. If the error persists, please read /opt/openhabian/docs/openhabian-DEBUG.md or https://github.com/openhab/openhabian/blob/main/docs/openhabian-DEBUG.md how to proceed.' 14 80 + return 0 + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='30 | System Settings' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 30 | System Settings == '' ]] + [[ 30 | System Settings == \0\0* ]] + [[ 30 | System Settings == \0\1* ]] + [[ 30 | System Settings == \0\2* ]] + [[ 30 | System Settings == \0\3* ]] + [[ 30 | System Settings == \0\4* ]] + [[ 30 | System Settings == \1\0* ]] + [[ 30 | System Settings == \2\0* ]] + [[ 30 | System Settings == \3\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' +++ hostname +++ env +++ grep '^[[:space:]]*LANG=' +++ sed 's|LANG=||g' +++ date +%H:%M ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'System Settings' 26 118 19 --cancel-button Back --ok-button Execute '31 | Change hostname' 'Change the name of this system, currently '\''openhabian'\''' '32 | Set system locale' 'Change system language, currently '\''de_DE.UTF-8'\''' '33 | Set system timezone' 'Change your timezone, execute if it'\''s not '\''19:57'\'' now' ' | Enable NTP' 'Enable time synchronization via systemd-timesyncd to NTP servers' ' | Disable NTP' 'Disable time synchronization via systemd-timesyncd to NTP servers' '34 | Change passwords' 'Change passwords for Samba, openHAB Console or the system user' '35 | Serial port' 'Prepare serial ports for peripherals like RaZberry, ZigBee adapters etc' '36 | Disable framebuffer' 'Disable framebuffer on RPi to minimize memory usage' ' | Enable framebuffer' 'Enable framebuffer (standard setting)' '37 | WiFi setup' 'Configure wireless network connection' ' | Disable WiFi' 'Disable wireless network connection' '38 | Use zram' 'Use compressed RAM/disk sync for active directories to avoid SD card corruption' ' | Update zram' 'Update a currently installed zram instance' ' | Uninstall zram' 'Don'\''t use compressed memory (back to standard Raspberry Pi OS filesystem layout)' '39 | Move root to USB' 'Move the system root from the SD card to a USB device (SSD or stick)' '3A | Setup Exim Mail Relay' 'Install Exim4 to relay mails via public email provider' '3B | Setup Tailscale VPN' 'Establish or join a WireGuard based VPN using the Tailscale service' ' | Remove Tailscale VPN' 'Remove the Tailscale VPN service' ' | Install WireGuard' 'Setup WireGuard to enable secure remote access to this openHABian system' ' | Remove WireGuard' 'Remove WireGuard VPN from this system' + choice2= + '[' 1 -eq 1 ']' + return 0 + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice= + RET=1 + '[' 1 -eq 1 ']' + return 255 + system_check_default_password + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + local algo + local defaultPassword + local defaultUser + local generatedPassword + local introText + local originalPassword + local salt + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + id -u pi + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + defaultUser=openhabian + defaultPassword=openhabian ++ grep -w openhabian /etc/shadow ++ cut -d: -f2 + originalPassword='$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f2 + algo=y + introText='The default password was detected on your system! That is a serious security concern. Bad guys or malicious programs in your subnet are able to gain root access!\n\nPlease set a strong password by typing the command '\''passwd openhabian'\''!' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f3 + salt=j9T + export algo defaultPassword salt ++ perl -le 'print crypt("$ENV{defaultPassword}","\$$ENV{algo}\$$ENV{salt}\$")' + generatedPassword='$y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA' ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:57:51_CET [openHABian] Checking for default openHABian username:password combination... ' 2022-01-25_19:57:51_CET [openHABian] Checking for default openHABian username:password combination... ++ id -u openhabian + [[ -n 1000 ]] + [[ $y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA == \$\y\$\j\9\T\$\Q\R\t\E\2\O\.\Q\S\Y\H\l\o\E\Z\n\r\j\v\G\R\/\$\N\8\f\i\E\k\r\p\u\x\e\B\P\R\G\K\o\6\u\2\t\q\5\y\L\u\l\L\f\x\D\W\R\d\i\v\Q\r\/\y\k\g\0 ]] + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -e '2022-01-25_19:57:51_CET [openHABian] We hope you got what you came for! See you again soon ;)' 2022-01-25_19:57:51_CET [openHABian] We hope you got what you came for! See you again soon ;) + cd /opt/openhabian 2022-01-25_19:58:17_CET [openHABian] Checking for root privileges... OK + export UNATTENDED SILENT DEBUGMAX INTERACTIVE + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/auth.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/backup.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/config.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/ext-storage.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/find.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/habapp.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/helpers.bash ++ ESC='\033[' ++ COL_DEF='\033[39;49;00m' ++ COL_RED='\033[31;01m' ++ COL_GREEN='\033[32;01m' ++ COL_YELLOW='\033[33;01m' ++ COL_BLUE='\033[34;01m' ++ COL_MAGENTA='\033[35;01m' ++ COL_CYAN='\033[36;01m' ++ COL_LGRAY='\033[37;01m' ++ COL_DGRAY='\033[90;01m' ++ export COL_DEF COL_RED COL_GREEN COL_YELLOW COL_BLUE COL_MAGENTA COL_CYAN COL_LGRAY COL_DGRAY + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/influxdb+grafana.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/java-jre.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/menu.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/nodejs-apps.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhab.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhabian.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/packages.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/system.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/vpn.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/wifi.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/zram.bash ++ pwd + OLDWD=/opt/openhabian + cd /opt + update_openhabian_conf + local configFile=/etc/openhabian.conf + local referenceConfig=/opt/openhabian/build-image/openhabian.conf + cp /etc/openhabian.conf /etc/openhabian.conf.BAK + read -r line + [[ # Origin: openhabian.conf =~ ^(#)?[a-zA-Z] ]] + echo '# Origin: openhabian.conf' + read -r line + [[ # =~ ^(#)?[a-zA-Z] ]] + echo '#' + read -r line + [[ # Modify your openHABian settings =~ ^(#)?[a-zA-Z] ]] + echo '# Modify your openHABian settings' + read -r line + [[ # Handle with care, only touch if you need to! =~ ^(#)?[a-zA-Z] ]] + echo '# Handle with care, only touch if you need to!' + read -r line + [[ # This file will only be used on unattended initial install. =~ ^(#)?[a-zA-Z] ]] + echo '# This file will only be used on unattended initial install.' + read -r line + [[ # If you want to change anything after unattended install completed, use menu in openhabian-config. =~ ^(#)?[a-zA-Z] ]] + echo '# If you want to change anything after unattended install completed, use menu in openhabian-config.' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # ATTENTION: to disable an option a line MUST be of the format '# option=value' =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: to disable an option a line MUST be of the format '\''# option=value'\''' + read -r line + [[ # KEEP THE SPACE IT IS IMPORTANT !! =~ ^(#)?[a-zA-Z] ]] + echo '# KEEP THE SPACE IT IS IMPORTANT !!' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hostname to set this one to =~ ^(#)?[a-zA-Z] ]] + echo '# Hostname to set this one to' + read -r line + [[ hostname=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hostname=openhabian + [[ hostname=openhabian =~ ^#[a-zA-Z] ]] ++ echo hostname=openhabian ++ cut -d= -f1 + param=hostname + [[ -v hostname ]] + [[ openhabian == *\ * ]] + echo hostname=openhabian + read -r line + [[ # if it exists, the default user (with its working environment) will be renamed to this username given here ... =~ ^(#)?[a-zA-Z] ]] + echo '# if it exists, the default user (with its working environment) will be renamed to this username given here ...' + read -r line + [[ username=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=username=openhabian + [[ username=openhabian =~ ^#[a-zA-Z] ]] ++ echo username=openhabian ++ cut -d= -f1 + param=username + [[ -v username ]] + [[ openhabian == *\ * ]] + echo username=openhabian + read -r line + [[ # ... and given this password. The password will be removed from this file after completion for security reasons. =~ ^(#)?[a-zA-Z] ]] + echo '# ... and given this password. The password will be removed from this file after completion for security reasons.' + read -r line + [[ userpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=userpw=openhabian + [[ userpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo userpw=openhabian ++ cut -d= -f1 + param=userpw + [[ -v userpw ]] + [[ openhabian == *\ * ]] + echo userpw=openhabian + read -r line + [[ # set this to download a SSH key and authorize the owner to login as the admin user =~ ^(#)?[a-zA-Z] ]] + echo '# set this to download a SSH key and authorize the owner to login as the admin user' + read -r line + [[ adminkeyurl="" =~ ^(#)?[a-zA-Z] ]] + parsed='adminkeyurl=""' + [[ adminkeyurl="" =~ ^#[a-zA-Z] ]] ++ echo 'adminkeyurl=""' ++ cut -d= -f1 + param=adminkeyurl + [[ -v adminkeyurl ]] + [[ '' == *\ * ]] + echo adminkeyurl= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Language and timezone. See Debian documentation for valid values. =~ ^(#)?[a-zA-Z] ]] + echo '# Language and timezone. See Debian documentation for valid values.' + read -r line + [[ timezone=Europe/Berlin =~ ^(#)?[a-zA-Z] ]] + parsed=timezone=Europe/Berlin + [[ timezone=Europe/Berlin =~ ^#[a-zA-Z] ]] ++ echo timezone=Europe/Berlin ++ cut -d= -f1 + param=timezone + [[ -v timezone ]] + [[ Europe/Berlin == *\ * ]] + echo timezone=Europe/Berlin + read -r line + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='locales="en_US.UTF-8 de_DE.UTF-8"' + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'locales="en_US.UTF-8 de_DE.UTF-8"' ++ cut -d= -f1 + param=locales + [[ -v locales ]] + [[ en_US.UTF-8 de_DE.UTF-8 == *\ * ]] + echo 'locales="en_US.UTF-8 de_DE.UTF-8"' + read -r line + [[ system_default_locale="en_US.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='system_default_locale="en_US.UTF-8"' + [[ system_default_locale="en_US.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'system_default_locale="en_US.UTF-8"' ++ cut -d= -f1 + param=system_default_locale + [[ -v system_default_locale ]] + [[ en_US.UTF-8 == *\ * ]] + echo system_default_locale=en_US.UTF-8 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # WiFi settings. An ethernet connection is recommended. =~ ^(#)?[a-zA-Z] ]] + echo '# WiFi settings. An ethernet connection is recommended.' + read -r line + [[ # If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi =~ ^(#)?[a-zA-Z] ]] + echo '# If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi' + read -r line + [[ # interface can be setup and used for the initial installation. =~ ^(#)?[a-zA-Z] ]] + echo '# interface can be setup and used for the initial installation.' + read -r line + [[ # Fill in your SSID and password below, leave empty or put comment in front to =~ ^(#)?[a-zA-Z] ]] + echo '# Fill in your SSID and password below, leave empty or put comment in front to' + read -r line + [[ # have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works. =~ ^(#)?[a-zA-Z] ]] + echo '# have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works.' + read -r line + [[ # ATTENTION: you need to escape these special characters: $, `, ", \, (newline) =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: you need to escape these special characters: $, `, ", \, (newline)' + read -r line + [[ # 'Escaping' means to put an additional \ in front of that character =~ ^(#)?[a-zA-Z] ]] + echo '# '\''Escaping'\'' means to put an additional \ in front of that character' + read -r line + [[ wifi_ssid="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_ssid=""' + [[ wifi_ssid="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_ssid=""' ++ cut -d= -f1 + param=wifi_ssid + [[ -v wifi_ssid ]] + [[ '' == *\ * ]] + echo wifi_ssid= + read -r line + [[ wifi_password="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_password=""' + [[ wifi_password="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_password=""' ++ cut -d= -f1 + param=wifi_password + [[ -v wifi_password ]] + [[ '' == *\ * ]] + echo wifi_password= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Wi-Fi setting. Select a two-letter country code suitable for your location =~ ^(#)?[a-zA-Z] ]] + echo '# Wi-Fi setting. Select a two-letter country code suitable for your location' + read -r line + [[ # E.g. US (default), DE, AU, NZ... =~ ^(#)?[a-zA-Z] ]] + echo '# E.g. US (default), DE, AU, NZ...' + read -r line + [[ # You may infringe on local legislature otherwise =~ ^(#)?[a-zA-Z] ]] + echo '# You may infringe on local legislature otherwise' + read -r line + [[ # See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab =~ ^(#)?[a-zA-Z] ]] + echo '# See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab' + read -r line + [[ wifi_country="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_country=""' + [[ wifi_country="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_country=""' ++ cut -d= -f1 + param=wifi_country + [[ -v wifi_country ]] + [[ '' == *\ * ]] + echo wifi_country= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Eventually disable all IPv6 e.g. on installation problems =~ ^(#)?[a-zA-Z] ]] + echo '# Eventually disable all IPv6 e.g. on installation problems' + read -r line + [[ # values: "enable", "disable" =~ ^(#)?[a-zA-Z] ]] + echo '# values: "enable", "disable"' + read -r line + [[ ipv6=enable =~ ^(#)?[a-zA-Z] ]] + parsed=ipv6=enable + [[ ipv6=enable =~ ^#[a-zA-Z] ]] ++ echo ipv6=enable ++ cut -d= -f1 + param=ipv6 + [[ -v ipv6 ]] + [[ enable == *\ * ]] + echo ipv6=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # repo and branch to clone from =~ ^(#)?[a-zA-Z] ]] + echo '# repo and branch to clone from' + read -r line + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^(#)?[a-zA-Z] ]] + parsed=repositoryurl=https://github.com/openhab/openhabian.git + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^#[a-zA-Z] ]] ++ echo repositoryurl=https://github.com/openhab/openhabian.git ++ cut -d= -f1 + param=repositoryurl + [[ -v repositoryurl ]] + [[ https://github.com/openhab/openhabian == *\ * ]] + echo repositoryurl=https://github.com/openhab/openhabian + read -r line + [[ clonebranch=openHAB3 =~ ^(#)?[a-zA-Z] ]] + parsed=clonebranch=openHAB3 + [[ clonebranch=openHAB3 =~ ^#[a-zA-Z] ]] ++ echo clonebranch=openHAB3 ++ cut -d= -f1 + param=clonebranch + [[ -v clonebranch ]] + [[ openHAB3 == *\ * ]] + echo clonebranch=openHAB3 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # initial openHAB configuration to import (URL or filename) =~ ^(#)?[a-zA-Z] ]] + echo '# initial openHAB configuration to import (URL or filename)' + read -r line + [[ # the file needs to be a zip archive created from openhab-cli backup =~ ^(#)?[a-zA-Z] ]] + echo '# the file needs to be a zip archive created from openhab-cli backup' + read -r line + [[ # initialconfig=/boot/initial.zip =~ ^(#)?[a-zA-Z] ]] + echo '# initialconfig=/boot/initial.zip' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # debug verbosity mode =~ ^(#)?[a-zA-Z] ]] + echo '# debug verbosity mode' + read -r line + [[ # off, on (verbose output in log) or maximum (show every command) =~ ^(#)?[a-zA-Z] ]] + echo '# off, on (verbose output in log) or maximum (show every command)' + read -r line + [[ debugmode=off =~ ^(#)?[a-zA-Z] ]] + parsed=debugmode=off + [[ debugmode=off =~ ^#[a-zA-Z] ]] ++ echo debugmode=off ++ cut -d= -f1 + param=debugmode + [[ -v debugmode ]] + [[ maximum == *\ * ]] + echo debugmode=maximum + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # the framebuffer on RPi is enabled by default =~ ^(#)?[a-zA-Z] ]] + echo '# the framebuffer on RPi is enabled by default' + read -r line + [[ framebuffer=enable =~ ^(#)?[a-zA-Z] ]] + parsed=framebuffer=enable + [[ framebuffer=enable =~ ^#[a-zA-Z] ]] ++ echo framebuffer=enable ++ cut -d= -f1 + param=framebuffer + [[ -v framebuffer ]] + [[ enable == *\ * ]] + echo framebuffer=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # fake hardware =~ ^(#)?[a-zA-Z] ]] + echo '# fake hardware' + read -r line + [[ # force treating your box as if it was a ... =~ ^(#)?[a-zA-Z] ]] + echo '# force treating your box as if it was a ...' + read -r line + [[ # pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86 =~ ^(#)?[a-zA-Z] ]] + echo '# pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86' + read -r line + [[ # hw= =~ ^(#)?[a-zA-Z] ]] + echo '# hw=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hardware architecture =~ ^(#)?[a-zA-Z] ]] + echo '# Hardware architecture' + read -r line + [[ # x86_64, amd64, armv6l, armv7l, aarch64, arm64 =~ ^(#)?[a-zA-Z] ]] + echo '# x86_64, amd64, armv6l, armv7l, aarch64, arm64' + read -r line + [[ # hwarch= =~ ^(#)?[a-zA-Z] ]] + echo '# hwarch=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # OS distribution/release =~ ^(#)?[a-zA-Z] ]] + echo '# OS distribution/release' + read -r line + [[ # Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal =~ ^(#)?[a-zA-Z] ]] + echo '# Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal' + read -r line + [[ # osrelease= =~ ^(#)?[a-zA-Z] ]] + echo '# osrelease=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Java version to install =~ ^(#)?[a-zA-Z] ]] + echo '# Java version to install' + read -r line + [[ java_opt=11 =~ ^(#)?[a-zA-Z] ]] + parsed=java_opt=11 + [[ java_opt=11 =~ ^#[a-zA-Z] ]] ++ echo java_opt=11 ++ cut -d= -f1 + param=java_opt + [[ -v java_opt ]] + [[ 11 == *\ * ]] + echo java_opt=11 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # install zram per default, set to "disable" to skip installation =~ ^(#)?[a-zA-Z] ]] + echo '# install zram per default, set to "disable" to skip installation' + read -r line + [[ zraminstall=enable =~ ^(#)?[a-zA-Z] ]] + parsed=zraminstall=enable + [[ zraminstall=enable =~ ^#[a-zA-Z] ]] ++ echo zraminstall=enable ++ cut -d= -f1 + param=zraminstall + [[ -v zraminstall ]] + [[ enable == *\ * ]] + echo zraminstall=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # start comitup hotspot if internet is not reachable =~ ^(#)?[a-zA-Z] ]] + echo '# start comitup hotspot if internet is not reachable' + read -r line + [[ hotspot=enable =~ ^(#)?[a-zA-Z] ]] + parsed=hotspot=enable + [[ hotspot=enable =~ ^#[a-zA-Z] ]] ++ echo hotspot=enable ++ cut -d= -f1 + param=hotspot + [[ -v hotspot ]] + [[ enable == *\ * ]] + echo hotspot=enable + read -r line + [[ hotspotpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hotspotpw=openhabian + [[ hotspotpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo hotspotpw=openhabian ++ cut -d= -f1 + param=hotspotpw + [[ -v hotspotpw ]] + [[ openhabian == *\ * ]] + echo hotspotpw=openhabian + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # external SD card device to backup and mirror the internal SD card to =~ ^(#)?[a-zA-Z] ]] + echo '# external SD card device to backup and mirror the internal SD card to' + read -r line + [[ # backupdrive=/dev/sda =~ ^(#)?[a-zA-Z] ]] + echo '# backupdrive=/dev/sda' + read -r line + [[ storageconfig=openhab-dir =~ ^(#)?[a-zA-Z] ]] + parsed=storageconfig=openhab-dir + [[ storageconfig=openhab-dir =~ ^#[a-zA-Z] ]] ++ echo storageconfig=openhab-dir ++ cut -d= -f1 + param=storageconfig + [[ -v storageconfig ]] + [[ openhab-dir == *\ * ]] + echo storageconfig=openhab-dir + read -r line + [[ storagedir=/storage =~ ^(#)?[a-zA-Z] ]] + parsed=storagedir=/storage + [[ storagedir=/storage =~ ^#[a-zA-Z] ]] ++ echo storagedir=/storage ++ cut -d= -f1 + param=storagedir + [[ -v storagedir ]] + [[ /storage == *\ * ]] + echo storagedir=/storage + read -r line + [[ storagetapes=15 =~ ^(#)?[a-zA-Z] ]] + parsed=storagetapes=15 + [[ storagetapes=15 =~ ^#[a-zA-Z] ]] ++ echo storagetapes=15 ++ cut -d= -f1 + param=storagetapes + [[ -v storagetapes ]] + [[ 15 == *\ * ]] + echo storagetapes=15 + read -r line + [[ storagecapacity=1024 =~ ^(#)?[a-zA-Z] ]] + parsed=storagecapacity=1024 + [[ storagecapacity=1024 =~ ^#[a-zA-Z] ]] ++ echo storagecapacity=1024 ++ cut -d= -f1 + param=storagecapacity + [[ -v storagecapacity ]] + [[ 1024 == *\ * ]] + echo storagecapacity=1024 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # mail relay settings =~ ^(#)?[a-zA-Z] ]] + echo '# mail relay settings' + read -r line + [[ # adminmail=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# adminmail=john.doe@foo.bar' + read -r line + [[ # relayuser=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# relayuser=john.doe@foo.bar' + read -r line + [[ # relaypass=secret =~ ^(#)?[a-zA-Z] ]] + echo '# relaypass=secret' + read -r line + [[ # smarthost=smtp.gmail.com =~ ^(#)?[a-zA-Z] ]] + echo '# smarthost=smtp.gmail.com' + read -r line + [[ # smartport=587 =~ ^(#)?[a-zA-Z] ]] + echo '# smartport=587' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Tailscale VPN =~ ^(#)?[a-zA-Z] ]] + echo '# Tailscale VPN' + read -r line + [[ # preauthkey=tskey-xxxxxxxxxxxxxxxxx =~ ^(#)?[a-zA-Z] ]] + echo '# preauthkey=tskey-xxxxxxxxxxxxxxxxx' + read -r line + [[ # tstags=tag:client =~ ^(#)?[a-zA-Z] ]] + echo '# tstags=tag:client' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Custom log files =~ ^(#)?[a-zA-Z] ]] + echo '# Custom log files' + read -r line + [[ # custom_log_files=("/var/log/foo.log" "/var/log/bar.log") =~ ^(#)?[a-zA-Z] ]] + echo '# custom_log_files=("/var/log/foo.log" "/var/log/bar.log")' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # vim: filetype=sh =~ ^(#)?[a-zA-Z] ]] + echo '# vim: filetype=sh' + read -r line + set_cpu_speed + is_raspios + [[ '' == \r\a\s\p\i\o\s ]] + is_raspbian + [[ '' == \r\a\s\p\b\i\a\n ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ Raspbian ]] + return 0 + return 0 + running_in_docker + [[ -n '' ]] + grep -qs 'docker\|lxc' /proc/1/cgroup + [[ -f /.dockerenv ]] + return 1 + echo 'GOVERNOR="ondemand"' + echo ondemand + config_ipv6 + local aptConf=/etc/apt/apt.conf.d/S90force-ipv4 + local sysctlConf=/etc/sysctl.d/99-sysctl.conf + [[ enable == \d\i\s\a\b\l\e ]] + [[ enable == \e\n\a\b\l\e ]] + grep -qs '^[[:space:]]*# Disable all IPv6 functionality' /etc/sysctl.d/99-sysctl.conf + [[ -n '' ]] + apt_update + PID_APT=3952 + apt-get update + whiptail_check ++ command -v whiptail + [[ -x /usr/bin/whiptail ]] + load_create_config + local 'questionText=\nWelcome to openHABian!\n\nPlease provide the name of your Linux user i.e. the account you normally log in with.\n\nTypical user names are '\''pi'\'' or '\''ubun + local input + [[ -f /etc/openhabian.conf ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:17_CET [openHABian] Loading configuration file '\''/etc/openhabian.conf'\''... ' 2022-01-25_19:58:17_CET [openHABian] Loading configuration file '/etc/openhabian.conf'... ++ getent group openhabian + [[ ! -n openhabian:x:1000:openhabian,frontail ]] + id -u openhabian + source /etc/openhabian.conf ++ hostname=openhabian ++ username=openhabian ++ userpw=openhabian ++ adminkeyurl= ++ timezone=Europe/Berlin ++ locales='en_US.UTF-8 de_DE.UTF-8' ++ system_default_locale=en_US.UTF-8 ++ wifi_ssid= ++ wifi_password= ++ wifi_country= ++ ipv6=enable ++ repositoryurl=https://github.com/openhab/openhabian ++ clonebranch=openHAB3 ++ debugmode=maximum ++ framebuffer=enable ++ java_opt=11 ++ zraminstall=enable ++ hotspot=enable ++ hotspotpw=openhabian ++ storageconfig=openhab-dir ++ storagedir=/storage ++ storagetapes=15 ++ storagecapacity=1024 + echo OK OK + openhabian_console_check + [[ -z 1 ]] ++ tput cols + [[ 237 -ge 120 ]] + return 0 + openhabian_update_check + [[ -z 1 ]] + local branch + local introText + local unsupportedOSText + branch=openHAB3 + introText='Additions, improvements or fixes were added to the openHABian configuration tool. Would you like to update now and benefit from them? The update will not automatically app.' + unsupportedOSText='You are running an old Linux release that is no longer officially supported.\nWe recommend upgrading to the most current stable release of your distribution (or cut offer LTS).\nDo you really want to continue using openHABian on this system?' ++ timestamp ++ date +%F_%T_%Z ++ get_git_revision ++ local branch ++ local commitDate ++ local shorthash +++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD ++ branch=openHAB3 +++ git -C /opt/openhabian log --pretty=format:%aI -n 1 ++ commitDate=2022-01-24T16:28:12-07:00 +++ git -C /opt/openhabian log --pretty=format:%h -n 1 ++ shorthash=08bc4ff ++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' + echo '2022-01-25_19:58:17_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' 2022-01-25_19:58:17_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff) ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:17_CET [openHABian] Checking for changes in origin branch openHAB3... ' 2022-01-25_19:58:17_CET [openHABian] Checking for changes in origin branch openHAB3... + is_stretch + [[ '' == \s\t\r\e\t\c\h ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ stretch ]] + return 1 + is_xenial + [[ '' == \x\e\n\i\a\l ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ xenial ]] + return 1 + git -C /opt/openhabian config user.email openhabian@openHABian + git -C /opt/openhabian config user.name openhabian + git -C /opt/openhabian fetch --quiet origin ++ git -C /opt/openhabian rev-parse openHAB3 ++ git -C /opt/openhabian rev-parse '@{u}' + [[ 08bc4ff34e8b7b059c126b6b999039cef7b48d33 == 08bc4ff34e8b7b059c126b6b999039cef7b48d33 ]] + echo OK OK + openhabian_announcements + [[ -z 1 ]] + local altReadNews + local newsFile + local readNews + altReadNews=/tmp/NEWS.md + newsFile=/opt/openhabian/NEWS.md + readNews=/opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /tmp/NEWS.md ++ cat /opt/openhabian/NEWS.md + whiptail --title 'openHABian announcements' --yes-button 'Stop displaying' --no-button 'Keep displaying' --defaultno --scrolltext --yesno 'Hit tab to unselect buttons and scroll through the text using UP/DOWN or PGUP/PGDN. All announcements are stored in `/opt/openhabian/docs/CHANGELOG.md` for you to lookup. ## Major Java provider switch ## December 15, 2021 We have switched to supporting only the OpenJDK package provided by default from the APT repo for all new installations of openHABian. Existing installations will be unaffected, however you will no longer receive updates to your current Java install until you install Java from the new provider which you can do by running menu option 45. Experimental support for Java 17 has also been added along with this change. In the future once Adoptium (formerly AdoptOpenJDK) releases a Debian based package repository support for Adoptium Java installs will be added as well. ## Node-RED and openHAB 3 ## December 10, 2021 We have updated the package of the Node-RED addon for openHAB 3 to `node-red-contrib-openhab3` to better support openHAB 3 installations which use this addon. You can install it today using `openhabian-config` menu option 25, which will install / upgrade all necessary components for Node-RED operation. ## openHABian 1.7 ## December 1, 2021 We have upgraded our base operating system to Raspberry Pi OS Bullseye. As usual upgrades on supported systems will be unaffected, use the `openhabian-config` menu to apply any updates available to your system. We will not automatically update your current base system (i.e buster -> bullseye) - don'\''t fix what ain'\''t broke. Debian buster will be at least supported two more years. If you are eager to upgrade, read up on `dist-upgrade` or reinstall your system. Please note that if you choose to upgrade and not reinstall, you are on your own, don'\''t expect to get support from the developers of openHABian if something goes wrong. Noteworthy changes since last image release: * New base OS: Raspberry Pi OS Bullseye * Added support for Raspberry Pi Zero 2 W * Ability to update zram without reinstalling it * More robust Java install routine * Fixed Amanda install not prompting for email address to send reports to * General bug fixes Known bugs: * Homegear is currently broken on Bullseye (complain to their devs)' 27 84 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:24_CET [openHABian] Switching to branch openHAB3... ' 2022-01-25_19:58:24_CET [openHABian] Switching to branch openHAB3... + git -C /opt/openhabian checkout --quiet openHAB3 + echo OK OK + bashrc_copy ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:24_CET [openHABian] Adding slightly tuned bash configuration files to system... ' 2022-01-25_19:58:24_CET [openHABian] Adding slightly tuned bash configuration files to system... + cp /opt/openhabian/includes/generic/bash.bashrc /etc/bash.bashrc + cp /opt/openhabian/includes/generic/bashrc-root /root/.bashrc + cp /opt/openhabian/includes/generic/bash_profile /home/openhabian/.bash_profile + cp /opt/openhabian/includes/generic/bash_aliases /home/openhabian/.bash_aliases + chown openhabian:openhabian /home/openhabian/.bash_aliases /home/openhabian/.bash_history /home/openhabian/.bash_logout /home/openhabian/.bash_profile + echo OK OK + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='30 | System Settings' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 30 | System Settings == '' ]] + [[ 30 | System Settings == \0\0* ]] + [[ 30 | System Settings == \0\1* ]] + [[ 30 | System Settings == \0\2* ]] + [[ 30 | System Settings == \0\3* ]] + [[ 30 | System Settings == \0\4* ]] + [[ 30 | System Settings == \1\0* ]] + [[ 30 | System Settings == \2\0* ]] + [[ 30 | System Settings == \3\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' +++ hostname +++ env +++ grep '^[[:space:]]*LANG=' +++ sed 's|LANG=||g' +++ date +%H:%M ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'System Settings' 26 118 19 --cancel-button Back --ok-button Execute '31 | Change hostname' 'Change the name of this system, currently '\''openhabian'\''' '32 | Set system locale' 'Change system language, currently '\''de_DE.UTF-8'\''' '33 | Set system timezone' 'Change your timezone, execute if it'\''s not '\''19:58'\'' now' ' | Enable NTP' 'Enable time synchronization via systemd-timesyncd to NTP servers' ' | Disable NTP' 'Disable time synchronization via systemd-timesyncd to NTP servers' '34 | Change passwords' 'Change passwords for Samba, openHAB Console or the system user' '35 | Serial port' 'Prepare serial ports for peripherals like RaZberry, ZigBee adapters etc' '36 | Disable framebuffer' 'Disable framebuffer on RPi to minimize memory usage' ' | Enable framebuffer' 'Enable framebuffer (standard setting)' '37 | WiFi setup' 'Configure wireless network connection' ' | Disable WiFi' 'Disable wireless network connection' '38 | Use zram' 'Use compressed RAM/disk sync for active directories to avoid SD card corruption' ' | Update zram' 'Update a currently installed zram instance' ' | Uninstall zram' 'Don'\''t use compressed memory (back to standard Raspberry Pi OS filesystem layout)' '39 | Move root to USB' 'Move the system root from the SD card to a USB device (SSD or stick)' '3A | Setup Exim Mail Relay' 'Install Exim4 to relay mails via public email provider' '3B | Setup Tailscale VPN' 'Establish or join a WireGuard based VPN using the Tailscale service' ' | Remove Tailscale VPN' 'Remove the Tailscale VPN service' ' | Install WireGuard' 'Setup WireGuard to enable secure remote access to this openHABian system' ' | Remove WireGuard' 'Remove WireGuard VPN from this system' + choice2=' | Update zram' + '[' 0 -eq 1 ']' + '[' 1 -eq 255 ']' + wait_for_apt_to_finish_update ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:36_CET [openHABian] Updating Linux package information... ' 2022-01-25_19:58:36_CET [openHABian] Updating Linux package information... + [[ -z 3952 ]] + tail --pid=3952 -f /dev/null + echo OK OK + case "$choice2" in + init_zram_mounts + is_arm + is_armv6l + [[ '' == \a\r\m\v\6\l ]] + case "$(uname -m)" in ++ uname -m + return 1 + is_armv7l + [[ '' == \a\r\m\v\7\l ]] + case "$(uname -m)" in ++ uname -m + return 0 + return 0 + local 'introText=You are about to activate the zram feature.\nBe aware you do this at your own risk of data loss.\nPlease check out the "zram status" thread at https://community.openhab.org/t/zram-status/80996 before proceeding.' + local 'lowMemText=Your system has less than 1 GB of RAM. It is definitely NOT recommended to run zram (AND openHAB) on your box. If you proceed now you will do so at your own risk!' + local zramInstallLocation=/opt/zram + [[ '' == \i\n\s\t\a\l\l ]] + [[ '' == \u\n\i\n\s\t\a\l\l ]] + [[ -f /etc/ztab ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:37_CET [openHABian] Updating zram service... ' 2022-01-25_19:58:37_CET [openHABian] Updating zram service... + cond_redirect zram-config stop + [[ -n '' ]] + echo -e '\n\033[90;01m$ zram-config stop \033[39;49;00m' $ zram-config stop + zram-config stop zram-config stop 2022-01-25-19:58:37 tac: '/tmp/zram-device-list' konnte nicht zum Lesen geöffnet werden: Datei oder Verzeichnis nicht gefunden + return 0 + cond_redirect install_zram_code /opt/zram + [[ -n '' ]] + echo -e '\n\033[90;01m$ install_zram_code /opt/zram \033[39;49;00m' $ install_zram_code /opt/zram + install_zram_code /opt/zram + local zramGit=https://github.com/ecdye/zram-config ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:37_CET [openHABian] Installing zram code... ' 2022-01-25_19:58:37_CET [openHABian] Installing zram code... + cond_redirect mkdir -p /opt/zram + [[ -n '' ]] + echo -e '\n\033[90;01m$ mkdir -p /opt/zram \033[39;49;00m' $ mkdir -p /opt/zram + mkdir -p /opt/zram + return 0 + [[ -d /opt/zram/zram-config ]] + cond_redirect update_git_repo /opt/zram/zram-config openHAB + [[ -n '' ]] + echo -e '\n\033[90;01m$ update_git_repo /opt/zram/zram-config openHAB \033[39;49;00m' $ update_git_repo /opt/zram/zram-config openHAB + update_git_repo /opt/zram/zram-config openHAB + local branch + local path + branch=openHAB + path=/opt/zram/zram-config ++ timestamp ++ date +%F_%T_%Z ++ basename /opt/zram/zram-config + echo -n '2022-01-25_19:58:37_CET [openHABian] Updating zram-config, openHAB branch from git... ' 2022-01-25_19:58:37_CET [openHABian] Updating zram-config, openHAB branch from git... + cond_redirect git -C /opt/zram/zram-config fetch origin + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/zram/zram-config fetch origin \033[39;49;00m' $ git -C /opt/zram/zram-config fetch origin + git -C /opt/zram/zram-config fetch origin + return 0 + cond_redirect git -C /opt/zram/zram-config fetch --tags --force --prune + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/zram/zram-config fetch --tags --force --prune \033[39;49;00m' $ git -C /opt/zram/zram-config fetch --tags --force --prune + git -C /opt/zram/zram-config fetch --tags --force --prune + return 0 + cond_redirect git -C /opt/zram/zram-config reset --hard origin/openHAB + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/zram/zram-config reset --hard origin/openHAB \033[39;49;00m' $ git -C /opt/zram/zram-config reset --hard origin/openHAB + git -C /opt/zram/zram-config reset --hard origin/openHAB HEAD ist jetzt bei 8442a33 Add openHAB specific changes + return 0 + cond_redirect git -C /opt/zram/zram-config clean --force -x -d + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/zram/zram-config clean --force -x -d \033[39;49;00m' $ git -C /opt/zram/zram-config clean --force -x -d + git -C /opt/zram/zram-config clean --force -x -d Lösche overlayfs-tools/logic.o Lösche overlayfs-tools/main.o Lösche overlayfs-tools/overlay Lösche overlayfs-tools/sh.o + return 0 + cond_redirect git -C /opt/zram/zram-config checkout openHAB + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/zram/zram-config checkout openHAB \033[39;49;00m' $ git -C /opt/zram/zram-config checkout openHAB + git -C /opt/zram/zram-config checkout openHAB Bereits auf 'openHAB' Ihr Branch ist auf demselben Stand wie 'origin/openHAB'. + return 0 + echo OK OK + return 0 + echo OK OK + return 0 + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:44_CET [openHABian] Updating OverlayFS... ' 2022-01-25_19:58:44_CET [openHABian] Updating OverlayFS... + cond_redirect make --always-make --directory=/opt/zram/zram-config/overlayfs-tools + [[ -n '' ]] + echo -e '\n\033[90;01m$ make --always-make --directory=/opt/zram/zram-config/overlayfs-tools \033[39;49;00m' $ make --always-make --directory=/opt/zram/zram-config/overlayfs-tools + make --always-make --directory=/opt/zram/zram-config/overlayfs-tools make: Verzeichnis „/opt/zram/zram-config/overlayfs-tools“ wird betreten gcc -Wall -std=c99 -c main.c gcc -Wall -std=c99 -c logic.c gcc -Wall -std=c99 -c sh.c gcc -lm main.o logic.o sh.o -o overlay make: Verzeichnis „/opt/zram/zram-config/overlayfs-tools“ wird verlassen + return 0 + cond_redirect mkdir -p /usr/local/lib/zram-config/ + [[ -n '' ]] + echo -e '\n\033[90;01m$ mkdir -p /usr/local/lib/zram-config/ \033[39;49;00m' $ mkdir -p /usr/local/lib/zram-config/ + mkdir -p /usr/local/lib/zram-config/ + return 0 + cond_redirect install -m 755 /opt/zram/zram-config/overlayfs-tools/overlay /usr/local/lib/zram-config/overlay + [[ -n '' ]] + echo -e '\n\033[90;01m$ install -m 755 /opt/zram/zram-config/overlayfs-tools/overlay /usr/local/lib/zram-config/overlay \033[39;49;00m' $ install -m 755 /opt/zram/zram-config/overlayfs-tools/overlay /usr/local/lib/zram-config/overlay + install -m 755 /opt/zram/zram-config/overlayfs-tools/overlay /usr/local/lib/zram-config/overlay + return 0 + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:46_CET [openHABian] Updating zram... ' 2022-01-25_19:58:46_CET [openHABian] Updating zram... + cond_redirect install -m 755 /opt/zram/zram-config/zram-config /usr/local/sbin + [[ -n '' ]] + echo -e '\n\033[90;01m$ install -m 755 /opt/zram/zram-config/zram-config /usr/local/sbin \033[39;49;00m' $ install -m 755 /opt/zram/zram-config/zram-config /usr/local/sbin + install -m 755 /opt/zram/zram-config/zram-config /usr/local/sbin + return 0 + cond_redirect mkdir -p /usr/local/share/zram-config/log + [[ -n '' ]] + echo -e '\n\033[90;01m$ mkdir -p /usr/local/share/zram-config/log \033[39;49;00m' $ mkdir -p /usr/local/share/zram-config/log + mkdir -p /usr/local/share/zram-config/log + return 0 + [[ -h /var/log/zram-config ]] + cond_redirect install -m 644 /opt/zram/zram-config/zram-config.logrotate /etc/logrotate.d/zram-config + [[ -n '' ]] + echo -e '\n\033[90;01m$ install -m 644 /opt/zram/zram-config/zram-config.logrotate /etc/logrotate.d/zram-config \033[39;49;00m' $ install -m 644 /opt/zram/zram-config/zram-config.logrotate /etc/logrotate.d/zram-config + install -m 644 /opt/zram/zram-config/zram-config.logrotate /etc/logrotate.d/zram-config + return 0 + grep -qs ReadWritePaths=/usr/local/share/zram-config/log /lib/systemd/system/logrotate.service + cond_redirect systemctl start zram-config.service + [[ -n '' ]] + echo -e '\n\033[90;01m$ systemctl start zram-config.service \033[39;49;00m' $ systemctl start zram-config.service + systemctl start zram-config.service + return 0 + echo OK OK + '[' 0 -ne 0 ']' + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice= + RET=1 + '[' 1 -eq 1 ']' + return 255 + system_check_default_password + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + local algo + local defaultPassword + local defaultUser + local generatedPassword + local introText + local originalPassword + local salt + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + id -u pi + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + defaultUser=openhabian + defaultPassword=openhabian ++ grep -w openhabian /etc/shadow ++ cut -d: -f2 + originalPassword='$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f2 + algo=y + introText='The default password was detected on your system! That is a serious security concern. Bad guys or malicious programs in your subnet are able to gain root access!\n\nPlease set a strong password by typing the command '\''passwd openhabian'\''!' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f3 + salt=j9T + export algo defaultPassword salt ++ perl -le 'print crypt("$ENV{defaultPassword}","\$$ENV{algo}\$$ENV{salt}\$")' + generatedPassword='$y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA' ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:58:51_CET [openHABian] Checking for default openHABian username:password combination... ' 2022-01-25_19:58:51_CET [openHABian] Checking for default openHABian username:password combination... ++ id -u openhabian + [[ -n 1000 ]] + [[ $y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA == \$\y\$\j\9\T\$\Q\R\t\E\2\O\.\Q\S\Y\H\l\o\E\Z\n\r\j\v\G\R\/\$\N\8\f\i\E\k\r\p\u\x\e\B\P\R\G\K\o\6\u\2\t\q\5\y\L\u\l\L\f\x\D\W\R\d\i\v\Q\r\/\y\k\g\0 ]] + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -e '2022-01-25_19:58:51_CET [openHABian] We hope you got what you came for! See you again soon ;)' 2022-01-25_19:58:51_CET [openHABian] We hope you got what you came for! See you again soon ;) + cd /opt/openhabian 2022-01-25_19:59:30_CET [openHABian] Checking for root privileges... OK + export UNATTENDED SILENT DEBUGMAX INTERACTIVE + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/auth.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/backup.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/config.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/ext-storage.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/find.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/habapp.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/helpers.bash ++ ESC='\033[' ++ COL_DEF='\033[39;49;00m' ++ COL_RED='\033[31;01m' ++ COL_GREEN='\033[32;01m' ++ COL_YELLOW='\033[33;01m' ++ COL_BLUE='\033[34;01m' ++ COL_MAGENTA='\033[35;01m' ++ COL_CYAN='\033[36;01m' ++ COL_LGRAY='\033[37;01m' ++ COL_DGRAY='\033[90;01m' ++ export COL_DEF COL_RED COL_GREEN COL_YELLOW COL_BLUE COL_MAGENTA COL_CYAN COL_LGRAY COL_DGRAY + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/influxdb+grafana.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/java-jre.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/menu.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/nodejs-apps.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhab.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhabian.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/packages.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/system.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/vpn.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/wifi.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/zram.bash ++ pwd + OLDWD=/opt/openhabian + cd /opt + update_openhabian_conf + local configFile=/etc/openhabian.conf + local referenceConfig=/opt/openhabian/build-image/openhabian.conf + cp /etc/openhabian.conf /etc/openhabian.conf.BAK + read -r line + [[ # Origin: openhabian.conf =~ ^(#)?[a-zA-Z] ]] + echo '# Origin: openhabian.conf' + read -r line + [[ # =~ ^(#)?[a-zA-Z] ]] + echo '#' + read -r line + [[ # Modify your openHABian settings =~ ^(#)?[a-zA-Z] ]] + echo '# Modify your openHABian settings' + read -r line + [[ # Handle with care, only touch if you need to! =~ ^(#)?[a-zA-Z] ]] + echo '# Handle with care, only touch if you need to!' + read -r line + [[ # This file will only be used on unattended initial install. =~ ^(#)?[a-zA-Z] ]] + echo '# This file will only be used on unattended initial install.' + read -r line + [[ # If you want to change anything after unattended install completed, use menu in openhabian-config. =~ ^(#)?[a-zA-Z] ]] + echo '# If you want to change anything after unattended install completed, use menu in openhabian-config.' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # ATTENTION: to disable an option a line MUST be of the format '# option=value' =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: to disable an option a line MUST be of the format '\''# option=value'\''' + read -r line + [[ # KEEP THE SPACE IT IS IMPORTANT !! =~ ^(#)?[a-zA-Z] ]] + echo '# KEEP THE SPACE IT IS IMPORTANT !!' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hostname to set this one to =~ ^(#)?[a-zA-Z] ]] + echo '# Hostname to set this one to' + read -r line + [[ hostname=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hostname=openhabian + [[ hostname=openhabian =~ ^#[a-zA-Z] ]] ++ echo hostname=openhabian ++ cut -d= -f1 + param=hostname + [[ -v hostname ]] + [[ openhabian == *\ * ]] + echo hostname=openhabian + read -r line + [[ # if it exists, the default user (with its working environment) will be renamed to this username given here ... =~ ^(#)?[a-zA-Z] ]] + echo '# if it exists, the default user (with its working environment) will be renamed to this username given here ...' + read -r line + [[ username=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=username=openhabian + [[ username=openhabian =~ ^#[a-zA-Z] ]] ++ echo username=openhabian ++ cut -d= -f1 + param=username + [[ -v username ]] + [[ openhabian == *\ * ]] + echo username=openhabian + read -r line + [[ # ... and given this password. The password will be removed from this file after completion for security reasons. =~ ^(#)?[a-zA-Z] ]] + echo '# ... and given this password. The password will be removed from this file after completion for security reasons.' + read -r line + [[ userpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=userpw=openhabian + [[ userpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo userpw=openhabian ++ cut -d= -f1 + param=userpw + [[ -v userpw ]] + [[ openhabian == *\ * ]] + echo userpw=openhabian + read -r line + [[ # set this to download a SSH key and authorize the owner to login as the admin user =~ ^(#)?[a-zA-Z] ]] + echo '# set this to download a SSH key and authorize the owner to login as the admin user' + read -r line + [[ adminkeyurl="" =~ ^(#)?[a-zA-Z] ]] + parsed='adminkeyurl=""' + [[ adminkeyurl="" =~ ^#[a-zA-Z] ]] ++ echo 'adminkeyurl=""' ++ cut -d= -f1 + param=adminkeyurl + [[ -v adminkeyurl ]] + [[ '' == *\ * ]] + echo adminkeyurl= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Language and timezone. See Debian documentation for valid values. =~ ^(#)?[a-zA-Z] ]] + echo '# Language and timezone. See Debian documentation for valid values.' + read -r line + [[ timezone=Europe/Berlin =~ ^(#)?[a-zA-Z] ]] + parsed=timezone=Europe/Berlin + [[ timezone=Europe/Berlin =~ ^#[a-zA-Z] ]] ++ echo timezone=Europe/Berlin ++ cut -d= -f1 + param=timezone + [[ -v timezone ]] + [[ Europe/Berlin == *\ * ]] + echo timezone=Europe/Berlin + read -r line + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='locales="en_US.UTF-8 de_DE.UTF-8"' + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'locales="en_US.UTF-8 de_DE.UTF-8"' ++ cut -d= -f1 + param=locales + [[ -v locales ]] + [[ en_US.UTF-8 de_DE.UTF-8 == *\ * ]] + echo 'locales="en_US.UTF-8 de_DE.UTF-8"' + read -r line + [[ system_default_locale="en_US.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='system_default_locale="en_US.UTF-8"' + [[ system_default_locale="en_US.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'system_default_locale="en_US.UTF-8"' ++ cut -d= -f1 + param=system_default_locale + [[ -v system_default_locale ]] + [[ en_US.UTF-8 == *\ * ]] + echo system_default_locale=en_US.UTF-8 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # WiFi settings. An ethernet connection is recommended. =~ ^(#)?[a-zA-Z] ]] + echo '# WiFi settings. An ethernet connection is recommended.' + read -r line + [[ # If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi =~ ^(#)?[a-zA-Z] ]] + echo '# If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi' + read -r line + [[ # interface can be setup and used for the initial installation. =~ ^(#)?[a-zA-Z] ]] + echo '# interface can be setup and used for the initial installation.' + read -r line + [[ # Fill in your SSID and password below, leave empty or put comment in front to =~ ^(#)?[a-zA-Z] ]] + echo '# Fill in your SSID and password below, leave empty or put comment in front to' + read -r line + [[ # have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works. =~ ^(#)?[a-zA-Z] ]] + echo '# have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works.' + read -r line + [[ # ATTENTION: you need to escape these special characters: $, `, ", \, (newline) =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: you need to escape these special characters: $, `, ", \, (newline)' + read -r line + [[ # 'Escaping' means to put an additional \ in front of that character =~ ^(#)?[a-zA-Z] ]] + echo '# '\''Escaping'\'' means to put an additional \ in front of that character' + read -r line + [[ wifi_ssid="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_ssid=""' + [[ wifi_ssid="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_ssid=""' ++ cut -d= -f1 + param=wifi_ssid + [[ -v wifi_ssid ]] + [[ '' == *\ * ]] + echo wifi_ssid= + read -r line + [[ wifi_password="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_password=""' + [[ wifi_password="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_password=""' ++ cut -d= -f1 + param=wifi_password + [[ -v wifi_password ]] + [[ '' == *\ * ]] + echo wifi_password= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Wi-Fi setting. Select a two-letter country code suitable for your location =~ ^(#)?[a-zA-Z] ]] + echo '# Wi-Fi setting. Select a two-letter country code suitable for your location' + read -r line + [[ # E.g. US (default), DE, AU, NZ... =~ ^(#)?[a-zA-Z] ]] + echo '# E.g. US (default), DE, AU, NZ...' + read -r line + [[ # You may infringe on local legislature otherwise =~ ^(#)?[a-zA-Z] ]] + echo '# You may infringe on local legislature otherwise' + read -r line + [[ # See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab =~ ^(#)?[a-zA-Z] ]] + echo '# See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab' + read -r line + [[ wifi_country="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_country=""' + [[ wifi_country="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_country=""' ++ cut -d= -f1 + param=wifi_country + [[ -v wifi_country ]] + [[ '' == *\ * ]] + echo wifi_country= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Eventually disable all IPv6 e.g. on installation problems =~ ^(#)?[a-zA-Z] ]] + echo '# Eventually disable all IPv6 e.g. on installation problems' + read -r line + [[ # values: "enable", "disable" =~ ^(#)?[a-zA-Z] ]] + echo '# values: "enable", "disable"' + read -r line + [[ ipv6=enable =~ ^(#)?[a-zA-Z] ]] + parsed=ipv6=enable + [[ ipv6=enable =~ ^#[a-zA-Z] ]] ++ echo ipv6=enable ++ cut -d= -f1 + param=ipv6 + [[ -v ipv6 ]] + [[ enable == *\ * ]] + echo ipv6=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # repo and branch to clone from =~ ^(#)?[a-zA-Z] ]] + echo '# repo and branch to clone from' + read -r line + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^(#)?[a-zA-Z] ]] + parsed=repositoryurl=https://github.com/openhab/openhabian.git + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^#[a-zA-Z] ]] ++ echo repositoryurl=https://github.com/openhab/openhabian.git ++ cut -d= -f1 + param=repositoryurl + [[ -v repositoryurl ]] + [[ https://github.com/openhab/openhabian == *\ * ]] + echo repositoryurl=https://github.com/openhab/openhabian + read -r line + [[ clonebranch=openHAB3 =~ ^(#)?[a-zA-Z] ]] + parsed=clonebranch=openHAB3 + [[ clonebranch=openHAB3 =~ ^#[a-zA-Z] ]] ++ echo clonebranch=openHAB3 ++ cut -d= -f1 + param=clonebranch + [[ -v clonebranch ]] + [[ openHAB3 == *\ * ]] + echo clonebranch=openHAB3 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # initial openHAB configuration to import (URL or filename) =~ ^(#)?[a-zA-Z] ]] + echo '# initial openHAB configuration to import (URL or filename)' + read -r line + [[ # the file needs to be a zip archive created from openhab-cli backup =~ ^(#)?[a-zA-Z] ]] + echo '# the file needs to be a zip archive created from openhab-cli backup' + read -r line + [[ # initialconfig=/boot/initial.zip =~ ^(#)?[a-zA-Z] ]] + echo '# initialconfig=/boot/initial.zip' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # debug verbosity mode =~ ^(#)?[a-zA-Z] ]] + echo '# debug verbosity mode' + read -r line + [[ # off, on (verbose output in log) or maximum (show every command) =~ ^(#)?[a-zA-Z] ]] + echo '# off, on (verbose output in log) or maximum (show every command)' + read -r line + [[ debugmode=off =~ ^(#)?[a-zA-Z] ]] + parsed=debugmode=off + [[ debugmode=off =~ ^#[a-zA-Z] ]] ++ echo debugmode=off ++ cut -d= -f1 + param=debugmode + [[ -v debugmode ]] + [[ maximum == *\ * ]] + echo debugmode=maximum + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # the framebuffer on RPi is enabled by default =~ ^(#)?[a-zA-Z] ]] + echo '# the framebuffer on RPi is enabled by default' + read -r line + [[ framebuffer=enable =~ ^(#)?[a-zA-Z] ]] + parsed=framebuffer=enable + [[ framebuffer=enable =~ ^#[a-zA-Z] ]] ++ echo framebuffer=enable ++ cut -d= -f1 + param=framebuffer + [[ -v framebuffer ]] + [[ enable == *\ * ]] + echo framebuffer=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # fake hardware =~ ^(#)?[a-zA-Z] ]] + echo '# fake hardware' + read -r line + [[ # force treating your box as if it was a ... =~ ^(#)?[a-zA-Z] ]] + echo '# force treating your box as if it was a ...' + read -r line + [[ # pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86 =~ ^(#)?[a-zA-Z] ]] + echo '# pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86' + read -r line + [[ # hw= =~ ^(#)?[a-zA-Z] ]] + echo '# hw=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hardware architecture =~ ^(#)?[a-zA-Z] ]] + echo '# Hardware architecture' + read -r line + [[ # x86_64, amd64, armv6l, armv7l, aarch64, arm64 =~ ^(#)?[a-zA-Z] ]] + echo '# x86_64, amd64, armv6l, armv7l, aarch64, arm64' + read -r line + [[ # hwarch= =~ ^(#)?[a-zA-Z] ]] + echo '# hwarch=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # OS distribution/release =~ ^(#)?[a-zA-Z] ]] + echo '# OS distribution/release' + read -r line + [[ # Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal =~ ^(#)?[a-zA-Z] ]] + echo '# Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal' + read -r line + [[ # osrelease= =~ ^(#)?[a-zA-Z] ]] + echo '# osrelease=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Java version to install =~ ^(#)?[a-zA-Z] ]] + echo '# Java version to install' + read -r line + [[ java_opt=11 =~ ^(#)?[a-zA-Z] ]] + parsed=java_opt=11 + [[ java_opt=11 =~ ^#[a-zA-Z] ]] ++ echo java_opt=11 ++ cut -d= -f1 + param=java_opt + [[ -v java_opt ]] + [[ 11 == *\ * ]] + echo java_opt=11 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # install zram per default, set to "disable" to skip installation =~ ^(#)?[a-zA-Z] ]] + echo '# install zram per default, set to "disable" to skip installation' + read -r line + [[ zraminstall=enable =~ ^(#)?[a-zA-Z] ]] + parsed=zraminstall=enable + [[ zraminstall=enable =~ ^#[a-zA-Z] ]] ++ echo zraminstall=enable ++ cut -d= -f1 + param=zraminstall + [[ -v zraminstall ]] + [[ enable == *\ * ]] + echo zraminstall=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # start comitup hotspot if internet is not reachable =~ ^(#)?[a-zA-Z] ]] + echo '# start comitup hotspot if internet is not reachable' + read -r line + [[ hotspot=enable =~ ^(#)?[a-zA-Z] ]] + parsed=hotspot=enable + [[ hotspot=enable =~ ^#[a-zA-Z] ]] ++ echo hotspot=enable ++ cut -d= -f1 + param=hotspot + [[ -v hotspot ]] + [[ enable == *\ * ]] + echo hotspot=enable + read -r line + [[ hotspotpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hotspotpw=openhabian + [[ hotspotpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo hotspotpw=openhabian ++ cut -d= -f1 + param=hotspotpw + [[ -v hotspotpw ]] + [[ openhabian == *\ * ]] + echo hotspotpw=openhabian + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # external SD card device to backup and mirror the internal SD card to =~ ^(#)?[a-zA-Z] ]] + echo '# external SD card device to backup and mirror the internal SD card to' + read -r line + [[ # backupdrive=/dev/sda =~ ^(#)?[a-zA-Z] ]] + echo '# backupdrive=/dev/sda' + read -r line + [[ storageconfig=openhab-dir =~ ^(#)?[a-zA-Z] ]] + parsed=storageconfig=openhab-dir + [[ storageconfig=openhab-dir =~ ^#[a-zA-Z] ]] ++ echo storageconfig=openhab-dir ++ cut -d= -f1 + param=storageconfig + [[ -v storageconfig ]] + [[ openhab-dir == *\ * ]] + echo storageconfig=openhab-dir + read -r line + [[ storagedir=/storage =~ ^(#)?[a-zA-Z] ]] + parsed=storagedir=/storage + [[ storagedir=/storage =~ ^#[a-zA-Z] ]] ++ echo storagedir=/storage ++ cut -d= -f1 + param=storagedir + [[ -v storagedir ]] + [[ /storage == *\ * ]] + echo storagedir=/storage + read -r line + [[ storagetapes=15 =~ ^(#)?[a-zA-Z] ]] + parsed=storagetapes=15 + [[ storagetapes=15 =~ ^#[a-zA-Z] ]] ++ echo storagetapes=15 ++ cut -d= -f1 + param=storagetapes + [[ -v storagetapes ]] + [[ 15 == *\ * ]] + echo storagetapes=15 + read -r line + [[ storagecapacity=1024 =~ ^(#)?[a-zA-Z] ]] + parsed=storagecapacity=1024 + [[ storagecapacity=1024 =~ ^#[a-zA-Z] ]] ++ echo storagecapacity=1024 ++ cut -d= -f1 + param=storagecapacity + [[ -v storagecapacity ]] + [[ 1024 == *\ * ]] + echo storagecapacity=1024 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # mail relay settings =~ ^(#)?[a-zA-Z] ]] + echo '# mail relay settings' + read -r line + [[ # adminmail=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# adminmail=john.doe@foo.bar' + read -r line + [[ # relayuser=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# relayuser=john.doe@foo.bar' + read -r line + [[ # relaypass=secret =~ ^(#)?[a-zA-Z] ]] + echo '# relaypass=secret' + read -r line + [[ # smarthost=smtp.gmail.com =~ ^(#)?[a-zA-Z] ]] + echo '# smarthost=smtp.gmail.com' + read -r line + [[ # smartport=587 =~ ^(#)?[a-zA-Z] ]] + echo '# smartport=587' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Tailscale VPN =~ ^(#)?[a-zA-Z] ]] + echo '# Tailscale VPN' + read -r line + [[ # preauthkey=tskey-xxxxxxxxxxxxxxxxx =~ ^(#)?[a-zA-Z] ]] + echo '# preauthkey=tskey-xxxxxxxxxxxxxxxxx' + read -r line + [[ # tstags=tag:client =~ ^(#)?[a-zA-Z] ]] + echo '# tstags=tag:client' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Custom log files =~ ^(#)?[a-zA-Z] ]] + echo '# Custom log files' + read -r line + [[ # custom_log_files=("/var/log/foo.log" "/var/log/bar.log") =~ ^(#)?[a-zA-Z] ]] + echo '# custom_log_files=("/var/log/foo.log" "/var/log/bar.log")' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # vim: filetype=sh =~ ^(#)?[a-zA-Z] ]] + echo '# vim: filetype=sh' + read -r line + set_cpu_speed + is_raspios + [[ '' == \r\a\s\p\i\o\s ]] + is_raspbian + [[ '' == \r\a\s\p\b\i\a\n ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ Raspbian ]] + return 0 + return 0 + running_in_docker + [[ -n '' ]] + grep -qs 'docker\|lxc' /proc/1/cgroup + [[ -f /.dockerenv ]] + return 1 + echo 'GOVERNOR="ondemand"' + echo ondemand + config_ipv6 + local aptConf=/etc/apt/apt.conf.d/S90force-ipv4 + local sysctlConf=/etc/sysctl.d/99-sysctl.conf + [[ enable == \d\i\s\a\b\l\e ]] + [[ enable == \e\n\a\b\l\e ]] + grep -qs '^[[:space:]]*# Disable all IPv6 functionality' /etc/sysctl.d/99-sysctl.conf + [[ -n '' ]] + apt_update + PID_APT=5202 + whiptail_check + apt-get update ++ command -v whiptail + [[ -x /usr/bin/whiptail ]] + load_create_config + local 'questionText=\nWelcome to openHABian!\n\nPlease provide the name of your Linux user i.e. the account you normally log in with.\n\nTypical user names are '\''pi'\'' or '\''ubuntu'\''.' + local input + [[ -f /etc/openhabian.conf ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:59:31_CET [openHABian] Loading configuration file '\''/etc/openhabian.conf'\''... ' 2022-01-25_19:59:31_CET [openHABian] Loading configuration file '/etc/openhabian.conf'... ++ getent group openhabian + [[ ! -n openhabian:x:1000:openhabian,frontail ]] + id -u openhabian + source /etc/openhabian.conf ++ hostname=openhabian ++ username=openhabian ++ userpw=openhabian ++ adminkeyurl= ++ timezone=Europe/Berlin ++ locales='en_US.UTF-8 de_DE.UTF-8' ++ system_default_locale=en_US.UTF-8 ++ wifi_ssid= ++ wifi_password= ++ wifi_country= ++ ipv6=enable ++ repositoryurl=https://github.com/openhab/openhabian ++ clonebranch=openHAB3 ++ debugmode=maximum ++ framebuffer=enable ++ java_opt=11 ++ zraminstall=enable ++ hotspot=enable ++ hotspotpw=openhabian ++ storageconfig=openhab-dir ++ storagedir=/storage ++ storagetapes=15 ++ storagecapacity=1024 + echo OK OK + openhabian_console_check + [[ -z 1 ]] ++ tput cols + [[ 184 -ge 120 ]] + return 0 + openhabian_update_check + [[ -z 1 ]] + local branch + local introText + local unsupportedOSText + branch=openHAB3 + introText='Additions, improvements or fixes were added to the openHABian configuration tool. Would you like to update now and benefit from them? The update will not automatically apply changes to your system.\n\nUpdating is recommended.' + unsupportedOSText='You are running an old Linux release that is no longer officially supported.\nWe recommend upgrading to the most current stable release of your distribution (or current Long Term Support version for distributions that offer LTS).\nDo you really want to continue using openHABian on this system?' ++ timestamp ++ date +%F_%T_%Z ++ get_git_revision ++ local branch ++ local commitDate ++ local shorthash +++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD ++ branch=openHAB3 +++ git -C /opt/openhabian log --pretty=format:%aI -n 1 ++ commitDate=2022-01-24T16:28:12-07:00 +++ git -C /opt/openhabian log --pretty=format:%h -n 1 ++ shorthash=08bc4ff ++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' + echo '2022-01-25_19:59:31_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' 2022-01-25_19:59:31_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff) ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:59:31_CET [openHABian] Checking for changes in origin branch openHAB3... ' 2022-01-25_19:59:31_CET [openHABian] Checking for changes in origin branch openHAB3... + is_stretch + [[ '' == \s\t\r\e\t\c\h ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ stretch ]] + return 1 + is_xenial + [[ '' == \x\e\n\i\a\l ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ xenial ]] + return 1 + git -C /opt/openhabian config user.email openhabian@openHABian + git -C /opt/openhabian config user.name openhabian + git -C /opt/openhabian fetch --quiet origin ++ git -C /opt/openhabian rev-parse openHAB3 ++ git -C /opt/openhabian rev-parse '@{u}' + [[ 08bc4ff34e8b7b059c126b6b999039cef7b48d33 == 08bc4ff34e8b7b059c126b6b999039cef7b48d33 ]] + echo OK OK + openhabian_announcements + [[ -z 1 ]] + local altReadNews + local newsFile + local readNews + altReadNews=/tmp/NEWS.md + newsFile=/opt/openhabian/NEWS.md + readNews=/opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /tmp/NEWS.md ++ cat /opt/openhabian/NEWS.md + whiptail --title 'openHABian announcements' --yes-button 'Stop displaying' --no-button 'Keep displaying' --defaultno --scrolltext --yesno 'Hit tab to unselect buttons and scroll through the text using UP/DOWN or PGUP/PGDN. All announcements are stored in `/opt/openhabian/docs/CHANGELOG.md` for you to lookup. ## Major Java provider switch ## December 15, 2021 We have switched to supporting only the OpenJDK package provided by default from the APT repo for all new installations of openHABian. Existing installations will be unaffected, however you will no longer receive updates to your current Java install until you install Java from the new provider which you can do by running menu option 45. Experimental support for Java 17 has also been added along with this change. In the future once Adoptium (formerly AdoptOpenJDK) releases a Debian based package repository support for Adoptium Java installs will be added as well. ## Node-RED and openHAB 3 ## December 10, 2021 We have updated the package of the Node-RED addon for openHAB 3 to `node-red-contrib-openhab3` to better support openHAB 3 installations which use this addon. You can install it today using `openhabian-config` menu option 25, which will install / upgrade all necessary components for Node-RED operation. ## openHABian 1.7 ## December 1, 2021 We have upgraded our base operating system to Raspberry Pi OS Bullseye. As usual upgrades on supported systems will be unaffected, use the `openhabian-config` menu to apply any updates available to your system. We will not automatically update your current base system (i.e buster -> bullseye) - don'\''t fix what ain'\''t broke. Debian buster will be at least supported two more years. If you are eager to upgrade, read up on `dist-upgrade` or reinstall your system. Please note that if you choose to upgrade and not reinstall, you are on your own, don'\''t expect to get support from the developers of openHABian if something goes wrong. Noteworthy changes since last image release: * New base OS: Raspberry Pi OS Bullseye * Added support for Raspberry Pi Zero 2 W * Ability to update zram without reinstalling it * More robust Java install routine * Fixed Amanda install not prompting for email address to send reports to * General bug fixes Known bugs: * Homegear is currently broken on Bullseye (complain to their devs)' 27 84 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:59:32_CET [openHABian] Switching to branch openHAB3... ' 2022-01-25_19:59:32_CET [openHABian] Switching to branch openHAB3... + git -C /opt/openhabian checkout --quiet openHAB3 + echo OK OK + bashrc_copy ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:59:32_CET [openHABian] Adding slightly tuned bash configuration files to system... ' 2022-01-25_19:59:32_CET [openHABian] Adding slightly tuned bash configuration files to system... + cp /opt/openhabian/includes/generic/bash.bashrc /etc/bash.bashrc + cp /opt/openhabian/includes/generic/bashrc-root /root/.bashrc + cp /opt/openhabian/includes/generic/bash_profile /home/openhabian/.bash_profile + cp /opt/openhabian/includes/generic/bash_aliases /home/openhabian/.bash_aliases + chown openhabian:openhabian /home/openhabian/.bash_aliases /home/openhabian/.bash_history /home/openhabian/.bash_logout /home/openhabian/.bash_profile + echo OK OK + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='30 | System Settings' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 30 | System Settings == '' ]] + [[ 30 | System Settings == \0\0* ]] + [[ 30 | System Settings == \0\1* ]] + [[ 30 | System Settings == \0\2* ]] + [[ 30 | System Settings == \0\3* ]] + [[ 30 | System Settings == \0\4* ]] + [[ 30 | System Settings == \1\0* ]] + [[ 30 | System Settings == \2\0* ]] + [[ 30 | System Settings == \3\0* ]] +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' +++ hostname +++ grep '^[[:space:]]*LANG=' +++ sed 's|LANG=||g' +++ env +++ date +%H:%M ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'System Settings' 26 118 19 --cancel-button Back --ok-button Execute '31 | Change hostname' 'Change the name of this system, currently '\''openhabian'\''' '32 | Set system locale' 'Change system language, currently '\''de_DE.UTF-8'\''' '33 | Set system timezone' 'Change your timezone, execute if it'\''s not '\''19:59'\'' now' ' | Enable NTP' 'Enable time synchronization via systemd-timesyncd to NTP servers' ' | Disable NTP' 'Disable time synchronization via systemd-timesyncd to NTP servers' '34 | Change passwords' 'Change passwords for Samba, openHAB Console or the system user' '35 | Serial port' 'Prepare serial ports for peripherals like RaZberry, ZigBee adapters etc' '36 | Disable framebuffer' 'Disable framebuffer on RPi to minimize memory usage' ' | Enable framebuffer' 'Enable framebuffer (standard setting)' '37 | WiFi setup' 'Configure wireless network connection' ' | Disable WiFi' 'Disable wireless network connection' '38 | Use zram' 'Use compressed RAM/disk sync for active directories to avoid SD card corruption' ' | Update zram' 'Update a currently installed zram instance' ' | Uninstall zram' 'Don'\''t use compressed memory (back to standard Raspberry Pi OS filesystem layout)' '39 | Move root to USB' 'Move the system root from the SD card to a USB device (SSD or stick)' '3A | Setup Exim Mail Relay' 'Install Exim4 to relay mails via public email provider' '3B | Setup Tailscale VPN' 'Establish or join a WireGuard based VPN using the Tailscale service' ' | Remove Tailscale VPN' 'Remove the Tailscale VPN service' ' | Install WireGuard' 'Setup WireGuard to enable secure remote access to this openHABian system' ' | Remove WireGuard' 'Remove WireGuard VPN from this system' + choice2='38 | Use zram' + '[' 0 -eq 1 ']' + '[' 1 -eq 255 ']' + wait_for_apt_to_finish_update ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:59:37_CET [openHABian] Updating Linux package information... ' 2022-01-25_19:59:37_CET [openHABian] Updating Linux package information... + [[ -z 5202 ]] + tail --pid=5202 -f /dev/null + echo OK OK + case "$choice2" in + init_zram_mounts install + is_arm + is_armv6l + [[ '' == \a\r\m\v\6\l ]] + case "$(uname -m)" in ++ uname -m + return 1 + is_armv7l + [[ '' == \a\r\m\v\7\l ]] + case "$(uname -m)" in ++ uname -m + return 0 + return 0 + local 'introText=You are about to activate the zram feature.\nBe aware you do this at your own risk of data loss.\nPlease check out the "zram status" thread at https://community.openhab.org/t/zram-status/80996 before proceeding.' + local 'lowMemText=Your system has less than 1 GB of RAM. It is definitely NOT recommended to run zram (AND openHAB) on your box. If you proceed now you will do so at your own risk!' + local zramInstallLocation=/opt/zram + [[ install == \i\n\s\t\a\l\l ]] + [[ -f /etc/ztab ]] + [[ install == \u\n\i\n\s\t\a\l\l ]] + [[ -f /etc/ztab ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:59:40_CET [openHABian] Updating zram service... ' 2022-01-25_19:59:40_CET [openHABian] Updating zram service... + cond_redirect zram-config stop + [[ -n '' ]] + echo -e '\n\033[90;01m$ zram-config stop \033[39;49;00m' $ zram-config stop + zram-config stop Failed to kill zram-config.service. Exiting! + return 1 + echo 'FAILED (stop zram)' FAILED (stop zram) + return 1 + '[' 1 -ne 0 ']' + whiptail --msgbox 'There was an error or interruption during the execution of:\n "30 | System Settings"\n\nPlease try again. If the error persists, please read /opt/openhabian/docs/openhabian-DEBUG.md or https://github.com/openhab/openhabian/blob/main/docs/openhabian-DEBUG.md how to proceed.' 14 80 + return 0 + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice= + RET=1 + '[' 1 -eq 1 ']' + return 255 + system_check_default_password + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + local algo + local defaultPassword + local defaultUser + local generatedPassword + local introText + local originalPassword + local salt + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + id -u pi + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + defaultUser=openhabian + defaultPassword=openhabian ++ grep -w openhabian /etc/shadow ++ cut -d: -f2 + originalPassword='$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f2 ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' + algo=y + introText='The default password was detected on your system! That is a serious security concern. Bad guys or malicious programs in your subnet are able to gain root access!\n\nPlease set a strong password by typing the command '\''passwd openhabian'\''!' ++ cut '-d$' -f3 ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' + salt=j9T + export algo defaultPassword salt ++ perl -le 'print crypt("$ENV{defaultPassword}","\$$ENV{algo}\$$ENV{salt}\$")' + generatedPassword='$y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA' ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_19:59:43_CET [openHABian] Checking for default openHABian username:password combination... ' 2022-01-25_19:59:43_CET [openHABian] Checking for default openHABian username:password combination... ++ id -u openhabian + [[ -n 1000 ]] + [[ $y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA == \$\y\$\j\9\T\$\Q\R\t\E\2\O\.\Q\S\Y\H\l\o\E\Z\n\r\j\v\G\R\/\$\N\8\f\i\E\k\r\p\u\x\e\B\P\R\G\K\o\6\u\2\t\q\5\y\L\u\l\L\f\x\D\W\R\d\i\v\Q\r\/\y\k\g\0 ]] + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -e '2022-01-25_19:59:43_CET [openHABian] We hope you got what you came for! See you again soon ;)' 2022-01-25_19:59:43_CET [openHABian] We hope you got what you came for! See you again soon ;) + cd /opt/openhabian 2022-01-25_20:00:27_CET [openHABian] Checking for root privileges... OK + export UNATTENDED SILENT DEBUGMAX INTERACTIVE + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/auth.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/backup.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/config.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/ext-storage.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/find.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/habapp.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/helpers.bash ++ ESC='\033[' ++ COL_DEF='\033[39;49;00m' ++ COL_RED='\033[31;01m' ++ COL_GREEN='\033[32;01m' ++ COL_YELLOW='\033[33;01m' ++ COL_BLUE='\033[34;01m' ++ COL_MAGENTA='\033[35;01m' ++ COL_CYAN='\033[36;01m' ++ COL_LGRAY='\033[37;01m' ++ COL_DGRAY='\033[90;01m' ++ export COL_DEF COL_RED COL_GREEN COL_YELLOW COL_BLUE COL_MAGENTA COL_CYAN COL_LGRAY COL_DGRAY + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/influxdb+grafana.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/java-jre.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/menu.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/nodejs-apps.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhab.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/openhabian.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/packages.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/system.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/vpn.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/wifi.bash + for shfile in "${BASEDIR:-/opt/openhabian}"/functions/*.bash + source /opt/openhabian/functions/zram.bash ++ pwd + OLDWD=/opt/openhabian + cd /opt + update_openhabian_conf + local configFile=/etc/openhabian.conf + local referenceConfig=/opt/openhabian/build-image/openhabian.conf + cp /etc/openhabian.conf /etc/openhabian.conf.BAK + read -r line + [[ # Origin: openhabian.conf =~ ^(#)?[a-zA-Z] ]] + echo '# Origin: openhabian.conf' + read -r line + [[ # =~ ^(#)?[a-zA-Z] ]] + echo '#' + read -r line + [[ # Modify your openHABian settings =~ ^(#)?[a-zA-Z] ]] + echo '# Modify your openHABian settings' + read -r line + [[ # Handle with care, only touch if you need to! =~ ^(#)?[a-zA-Z] ]] + echo '# Handle with care, only touch if you need to!' + read -r line + [[ # This file will only be used on unattended initial install. =~ ^(#)?[a-zA-Z] ]] + echo '# This file will only be used on unattended initial install.' + read -r line + [[ # If you want to change anything after unattended install completed, use menu in openhabian-config. =~ ^(#)?[a-zA-Z] ]] + echo '# If you want to change anything after unattended install completed, use menu in openhabian-config.' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # ATTENTION: to disable an option a line MUST be of the format '# option=value' =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: to disable an option a line MUST be of the format '\''# option=value'\''' + read -r line + [[ # KEEP THE SPACE IT IS IMPORTANT !! =~ ^(#)?[a-zA-Z] ]] + echo '# KEEP THE SPACE IT IS IMPORTANT !!' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hostname to set this one to =~ ^(#)?[a-zA-Z] ]] + echo '# Hostname to set this one to' + read -r line + [[ hostname=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hostname=openhabian + [[ hostname=openhabian =~ ^#[a-zA-Z] ]] ++ echo hostname=openhabian ++ cut -d= -f1 + param=hostname + [[ -v hostname ]] + [[ openhabian == *\ * ]] + echo hostname=openhabian + read -r line + [[ # if it exists, the default user (with its working environment) will be renamed to this username given here ... =~ ^(#)?[a-zA-Z] ]] + echo '# if it exists, the default user (with its working environment) will be renamed to this username given here ...' + read -r line + [[ username=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=username=openhabian + [[ username=openhabian =~ ^#[a-zA-Z] ]] ++ echo username=openhabian ++ cut -d= -f1 + param=username + [[ -v username ]] + [[ openhabian == *\ * ]] + echo username=openhabian + read -r line + [[ # ... and given this password. The password will be removed from this file after completion for security reasons. =~ ^(#)?[a-zA-Z] ]] + echo '# ... and given this password. The password will be removed from this file after completion for security reasons.' + read -r line + [[ userpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=userpw=openhabian + [[ userpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo userpw=openhabian ++ cut -d= -f1 + param=userpw + [[ -v userpw ]] + [[ openhabian == *\ * ]] + echo userpw=openhabian + read -r line + [[ # set this to download a SSH key and authorize the owner to login as the admin user =~ ^(#)?[a-zA-Z] ]] + echo '# set this to download a SSH key and authorize the owner to login as the admin user' + read -r line + [[ adminkeyurl="" =~ ^(#)?[a-zA-Z] ]] + parsed='adminkeyurl=""' + [[ adminkeyurl="" =~ ^#[a-zA-Z] ]] ++ echo 'adminkeyurl=""' ++ cut -d= -f1 + param=adminkeyurl + [[ -v adminkeyurl ]] + [[ '' == *\ * ]] + echo adminkeyurl= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Language and timezone. See Debian documentation for valid values. =~ ^(#)?[a-zA-Z] ]] + echo '# Language and timezone. See Debian documentation for valid values.' + read -r line + [[ timezone=Europe/Berlin =~ ^(#)?[a-zA-Z] ]] + parsed=timezone=Europe/Berlin + [[ timezone=Europe/Berlin =~ ^#[a-zA-Z] ]] ++ echo timezone=Europe/Berlin ++ cut -d= -f1 + param=timezone + [[ -v timezone ]] + [[ Europe/Berlin == *\ * ]] + echo timezone=Europe/Berlin + read -r line + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='locales="en_US.UTF-8 de_DE.UTF-8"' + [[ locales="en_US.UTF-8 de_DE.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'locales="en_US.UTF-8 de_DE.UTF-8"' ++ cut -d= -f1 + param=locales + [[ -v locales ]] + [[ en_US.UTF-8 de_DE.UTF-8 == *\ * ]] + echo 'locales="en_US.UTF-8 de_DE.UTF-8"' + read -r line + [[ system_default_locale="en_US.UTF-8" =~ ^(#)?[a-zA-Z] ]] + parsed='system_default_locale="en_US.UTF-8"' + [[ system_default_locale="en_US.UTF-8" =~ ^#[a-zA-Z] ]] ++ echo 'system_default_locale="en_US.UTF-8"' ++ cut -d= -f1 + param=system_default_locale + [[ -v system_default_locale ]] + [[ en_US.UTF-8 == *\ * ]] + echo system_default_locale=en_US.UTF-8 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # WiFi settings. An ethernet connection is recommended. =~ ^(#)?[a-zA-Z] ]] + echo '# WiFi settings. An ethernet connection is recommended.' + read -r line + [[ # If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi =~ ^(#)?[a-zA-Z] ]] + echo '# If you have a RPi4, RPi3, RPi0W or a supported external WiFi dongle, the WiFi' + read -r line + [[ # interface can be setup and used for the initial installation. =~ ^(#)?[a-zA-Z] ]] + echo '# interface can be setup and used for the initial installation.' + read -r line + [[ # Fill in your SSID and password below, leave empty or put comment in front to =~ ^(#)?[a-zA-Z] ]] + echo '# Fill in your SSID and password below, leave empty or put comment in front to' + read -r line + [[ # have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works. =~ ^(#)?[a-zA-Z] ]] + echo '# have your WiFi remain unchanged/uninitialized. Make sure your Ethernet works.' + read -r line + [[ # ATTENTION: you need to escape these special characters: $, `, ", \, (newline) =~ ^(#)?[a-zA-Z] ]] + echo '# ATTENTION: you need to escape these special characters: $, `, ", \, (newline)' + read -r line + [[ # 'Escaping' means to put an additional \ in front of that character =~ ^(#)?[a-zA-Z] ]] + echo '# '\''Escaping'\'' means to put an additional \ in front of that character' + read -r line + [[ wifi_ssid="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_ssid=""' + [[ wifi_ssid="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_ssid=""' ++ cut -d= -f1 + param=wifi_ssid + [[ -v wifi_ssid ]] + [[ '' == *\ * ]] + echo wifi_ssid= + read -r line + [[ wifi_password="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_password=""' + [[ wifi_password="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_password=""' ++ cut -d= -f1 + param=wifi_password + [[ -v wifi_password ]] + [[ '' == *\ * ]] + echo wifi_password= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Wi-Fi setting. Select a two-letter country code suitable for your location =~ ^(#)?[a-zA-Z] ]] + echo '# Wi-Fi setting. Select a two-letter country code suitable for your location' + read -r line + [[ # E.g. US (default), DE, AU, NZ... =~ ^(#)?[a-zA-Z] ]] + echo '# E.g. US (default), DE, AU, NZ...' + read -r line + [[ # You may infringe on local legislature otherwise =~ ^(#)?[a-zA-Z] ]] + echo '# You may infringe on local legislature otherwise' + read -r line + [[ # See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab =~ ^(#)?[a-zA-Z] ]] + echo '# See https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2 or /usr/share/zoneinfo/zone.tab' + read -r line + [[ wifi_country="" =~ ^(#)?[a-zA-Z] ]] + parsed='wifi_country=""' + [[ wifi_country="" =~ ^#[a-zA-Z] ]] ++ echo 'wifi_country=""' ++ cut -d= -f1 + param=wifi_country + [[ -v wifi_country ]] + [[ '' == *\ * ]] + echo wifi_country= + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Eventually disable all IPv6 e.g. on installation problems =~ ^(#)?[a-zA-Z] ]] + echo '# Eventually disable all IPv6 e.g. on installation problems' + read -r line + [[ # values: "enable", "disable" =~ ^(#)?[a-zA-Z] ]] + echo '# values: "enable", "disable"' + read -r line + [[ ipv6=enable =~ ^(#)?[a-zA-Z] ]] + parsed=ipv6=enable + [[ ipv6=enable =~ ^#[a-zA-Z] ]] ++ echo ipv6=enable ++ cut -d= -f1 + param=ipv6 + [[ -v ipv6 ]] + [[ enable == *\ * ]] + echo ipv6=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # repo and branch to clone from =~ ^(#)?[a-zA-Z] ]] + echo '# repo and branch to clone from' + read -r line + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^(#)?[a-zA-Z] ]] + parsed=repositoryurl=https://github.com/openhab/openhabian.git + [[ repositoryurl=https://github.com/openhab/openhabian.git =~ ^#[a-zA-Z] ]] ++ echo repositoryurl=https://github.com/openhab/openhabian.git ++ cut -d= -f1 + param=repositoryurl + [[ -v repositoryurl ]] + [[ https://github.com/openhab/openhabian == *\ * ]] + echo repositoryurl=https://github.com/openhab/openhabian + read -r line + [[ clonebranch=openHAB3 =~ ^(#)?[a-zA-Z] ]] + parsed=clonebranch=openHAB3 + [[ clonebranch=openHAB3 =~ ^#[a-zA-Z] ]] ++ echo clonebranch=openHAB3 ++ cut -d= -f1 + param=clonebranch + [[ -v clonebranch ]] + [[ openHAB3 == *\ * ]] + echo clonebranch=openHAB3 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # initial openHAB configuration to import (URL or filename) =~ ^(#)?[a-zA-Z] ]] + echo '# initial openHAB configuration to import (URL or filename)' + read -r line + [[ # the file needs to be a zip archive created from openhab-cli backup =~ ^(#)?[a-zA-Z] ]] + echo '# the file needs to be a zip archive created from openhab-cli backup' + read -r line + [[ # initialconfig=/boot/initial.zip =~ ^(#)?[a-zA-Z] ]] + echo '# initialconfig=/boot/initial.zip' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # debug verbosity mode =~ ^(#)?[a-zA-Z] ]] + echo '# debug verbosity mode' + read -r line + [[ # off, on (verbose output in log) or maximum (show every command) =~ ^(#)?[a-zA-Z] ]] + echo '# off, on (verbose output in log) or maximum (show every command)' + read -r line + [[ debugmode=off =~ ^(#)?[a-zA-Z] ]] + parsed=debugmode=off + [[ debugmode=off =~ ^#[a-zA-Z] ]] ++ echo debugmode=off ++ cut -d= -f1 + param=debugmode + [[ -v debugmode ]] + [[ maximum == *\ * ]] + echo debugmode=maximum + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # the framebuffer on RPi is enabled by default =~ ^(#)?[a-zA-Z] ]] + echo '# the framebuffer on RPi is enabled by default' + read -r line + [[ framebuffer=enable =~ ^(#)?[a-zA-Z] ]] + parsed=framebuffer=enable + [[ framebuffer=enable =~ ^#[a-zA-Z] ]] ++ echo framebuffer=enable ++ cut -d= -f1 + param=framebuffer + [[ -v framebuffer ]] + [[ enable == *\ * ]] + echo framebuffer=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # fake hardware =~ ^(#)?[a-zA-Z] ]] + echo '# fake hardware' + read -r line + [[ # force treating your box as if it was a ... =~ ^(#)?[a-zA-Z] ]] + echo '# force treating your box as if it was a ...' + read -r line + [[ # pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86 =~ ^(#)?[a-zA-Z] ]] + echo '# pi4, pi4_8gb, cm4, pi400, pi3, cm3, pi3+, cm3+, pi2, pi1, cm1, pi0, pi0w, pi0w2, x86' + read -r line + [[ # hw= =~ ^(#)?[a-zA-Z] ]] + echo '# hw=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Hardware architecture =~ ^(#)?[a-zA-Z] ]] + echo '# Hardware architecture' + read -r line + [[ # x86_64, amd64, armv6l, armv7l, aarch64, arm64 =~ ^(#)?[a-zA-Z] ]] + echo '# x86_64, amd64, armv6l, armv7l, aarch64, arm64' + read -r line + [[ # hwarch= =~ ^(#)?[a-zA-Z] ]] + echo '# hwarch=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # OS distribution/release =~ ^(#)?[a-zA-Z] ]] + echo '# OS distribution/release' + read -r line + [[ # Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal =~ ^(#)?[a-zA-Z] ]] + echo '# Valid arguments: raspios, raspbian, debian, ubuntu, stretch, buster, bullseye, bionic, focal' + read -r line + [[ # osrelease= =~ ^(#)?[a-zA-Z] ]] + echo '# osrelease=' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Java version to install =~ ^(#)?[a-zA-Z] ]] + echo '# Java version to install' + read -r line + [[ java_opt=11 =~ ^(#)?[a-zA-Z] ]] + parsed=java_opt=11 + [[ java_opt=11 =~ ^#[a-zA-Z] ]] ++ echo java_opt=11 ++ cut -d= -f1 + param=java_opt + [[ -v java_opt ]] + [[ 11 == *\ * ]] + echo java_opt=11 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # install zram per default, set to "disable" to skip installation =~ ^(#)?[a-zA-Z] ]] + echo '# install zram per default, set to "disable" to skip installation' + read -r line + [[ zraminstall=enable =~ ^(#)?[a-zA-Z] ]] + parsed=zraminstall=enable + [[ zraminstall=enable =~ ^#[a-zA-Z] ]] ++ echo zraminstall=enable ++ cut -d= -f1 + param=zraminstall + [[ -v zraminstall ]] + [[ enable == *\ * ]] + echo zraminstall=enable + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # start comitup hotspot if internet is not reachable =~ ^(#)?[a-zA-Z] ]] + echo '# start comitup hotspot if internet is not reachable' + read -r line + [[ hotspot=enable =~ ^(#)?[a-zA-Z] ]] + parsed=hotspot=enable + [[ hotspot=enable =~ ^#[a-zA-Z] ]] ++ echo hotspot=enable ++ cut -d= -f1 + param=hotspot + [[ -v hotspot ]] + [[ enable == *\ * ]] + echo hotspot=enable + read -r line + [[ hotspotpw=openhabian =~ ^(#)?[a-zA-Z] ]] + parsed=hotspotpw=openhabian + [[ hotspotpw=openhabian =~ ^#[a-zA-Z] ]] ++ echo hotspotpw=openhabian ++ cut -d= -f1 + param=hotspotpw + [[ -v hotspotpw ]] + [[ openhabian == *\ * ]] + echo hotspotpw=openhabian + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # external SD card device to backup and mirror the internal SD card to =~ ^(#)?[a-zA-Z] ]] + echo '# external SD card device to backup and mirror the internal SD card to' + read -r line + [[ # backupdrive=/dev/sda =~ ^(#)?[a-zA-Z] ]] + echo '# backupdrive=/dev/sda' + read -r line + [[ storageconfig=openhab-dir =~ ^(#)?[a-zA-Z] ]] + parsed=storageconfig=openhab-dir + [[ storageconfig=openhab-dir =~ ^#[a-zA-Z] ]] ++ echo storageconfig=openhab-dir ++ cut -d= -f1 + param=storageconfig + [[ -v storageconfig ]] + [[ openhab-dir == *\ * ]] + echo storageconfig=openhab-dir + read -r line + [[ storagedir=/storage =~ ^(#)?[a-zA-Z] ]] + parsed=storagedir=/storage + [[ storagedir=/storage =~ ^#[a-zA-Z] ]] ++ echo storagedir=/storage ++ cut -d= -f1 + param=storagedir + [[ -v storagedir ]] + [[ /storage == *\ * ]] + echo storagedir=/storage + read -r line + [[ storagetapes=15 =~ ^(#)?[a-zA-Z] ]] + parsed=storagetapes=15 + [[ storagetapes=15 =~ ^#[a-zA-Z] ]] ++ echo storagetapes=15 ++ cut -d= -f1 + param=storagetapes + [[ -v storagetapes ]] + [[ 15 == *\ * ]] + echo storagetapes=15 + read -r line + [[ storagecapacity=1024 =~ ^(#)?[a-zA-Z] ]] + parsed=storagecapacity=1024 + [[ storagecapacity=1024 =~ ^#[a-zA-Z] ]] ++ echo storagecapacity=1024 ++ cut -d= -f1 + param=storagecapacity + [[ -v storagecapacity ]] + [[ 1024 == *\ * ]] + echo storagecapacity=1024 + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # mail relay settings =~ ^(#)?[a-zA-Z] ]] + echo '# mail relay settings' + read -r line + [[ # adminmail=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# adminmail=john.doe@foo.bar' + read -r line + [[ # relayuser=john.doe@foo.bar =~ ^(#)?[a-zA-Z] ]] + echo '# relayuser=john.doe@foo.bar' + read -r line + [[ # relaypass=secret =~ ^(#)?[a-zA-Z] ]] + echo '# relaypass=secret' + read -r line + [[ # smarthost=smtp.gmail.com =~ ^(#)?[a-zA-Z] ]] + echo '# smarthost=smtp.gmail.com' + read -r line + [[ # smartport=587 =~ ^(#)?[a-zA-Z] ]] + echo '# smartport=587' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Tailscale VPN =~ ^(#)?[a-zA-Z] ]] + echo '# Tailscale VPN' + read -r line + [[ # preauthkey=tskey-xxxxxxxxxxxxxxxxx =~ ^(#)?[a-zA-Z] ]] + echo '# preauthkey=tskey-xxxxxxxxxxxxxxxxx' + read -r line + [[ # tstags=tag:client =~ ^(#)?[a-zA-Z] ]] + echo '# tstags=tag:client' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # Custom log files =~ ^(#)?[a-zA-Z] ]] + echo '# Custom log files' + read -r line + [[ # custom_log_files=("/var/log/foo.log" "/var/log/bar.log") =~ ^(#)?[a-zA-Z] ]] + echo '# custom_log_files=("/var/log/foo.log" "/var/log/bar.log")' + read -r line + [[ '' =~ ^(#)?[a-zA-Z] ]] + echo '' + read -r line + [[ # vim: filetype=sh =~ ^(#)?[a-zA-Z] ]] + echo '# vim: filetype=sh' + read -r line + set_cpu_speed + is_raspios + [[ '' == \r\a\s\p\i\o\s ]] + is_raspbian + [[ '' == \r\a\s\p\b\i\a\n ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ Raspbian ]] + return 0 + return 0 + running_in_docker + [[ -n '' ]] + grep -qs 'docker\|lxc' /proc/1/cgroup + [[ -f /.dockerenv ]] + return 1 + echo 'GOVERNOR="ondemand"' + echo ondemand + config_ipv6 + local aptConf=/etc/apt/apt.conf.d/S90force-ipv4 + local sysctlConf=/etc/sysctl.d/99-sysctl.conf + [[ enable == \d\i\s\a\b\l\e ]] + [[ enable == \e\n\a\b\l\e ]] + grep -qs '^[[:space:]]*# Disable all IPv6 functionality' /etc/sysctl.d/99-sysctl.conf + [[ -n '' ]] + apt_update + PID_APT=5957 + whiptail_check + apt-get update ++ command -v whiptail + [[ -x /usr/bin/whiptail ]] + load_create_config + local 'questionText=\nWelcome to openHABian!\n\nPlease provide the name of your Linux user i.e. the account you normally log in with.\n\nTypical user names are '\''pi'\'' or '\''ubuntu'\''.' + local input + [[ -f /etc/openhabian.conf ]] ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_20:00:27_CET [openHABian] Loading configuration file '\''/etc/openhabian.conf'\''... ' 2022-01-25_20:00:27_CET [openHABian] Loading configuration file '/etc/openhabian.conf'... ++ getent group openhabian + [[ ! -n openhabian:x:1000:openhabian,frontail ]] + id -u openhabian + source /etc/openhabian.conf ++ hostname=openhabian ++ username=openhabian ++ userpw=openhabian ++ adminkeyurl= ++ timezone=Europe/Berlin ++ locales='en_US.UTF-8 de_DE.UTF-8' ++ system_default_locale=en_US.UTF-8 ++ wifi_ssid= ++ wifi_password= ++ wifi_country= ++ ipv6=enable ++ repositoryurl=https://github.com/openhab/openhabian ++ clonebranch=openHAB3 ++ debugmode=maximum ++ framebuffer=enable ++ java_opt=11 ++ zraminstall=enable ++ hotspot=enable ++ hotspotpw=openhabian ++ storageconfig=openhab-dir ++ storagedir=/storage ++ storagetapes=15 ++ storagecapacity=1024 + echo OK OK + openhabian_console_check + [[ -z 1 ]] ++ tput cols + [[ 184 -ge 120 ]] + return 0 + openhabian_update_check + [[ -z 1 ]] + local branch + local introText + local unsupportedOSText + branch=openHAB3 + introText='Additions, improvements or fixes were added to the openHABian configuration tool. Would you like to update now and benefit from them? The update will not automatically apply changes to your system.\n\nUpdating is recommended.' + unsupportedOSText='You are running an old Linux release that is no longer officially supported.\nWe recommend upgrading to the most current stable release of your distribution (or current Long Term Support version for distributions that offer LTS).\nDo you really want to continue using openHABian on this system?' ++ timestamp ++ date +%F_%T_%Z ++ get_git_revision ++ local branch ++ local commitDate ++ local shorthash +++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD ++ branch=openHAB3 +++ git -C /opt/openhabian log --pretty=format:%aI -n 1 ++ commitDate=2022-01-24T16:28:12-07:00 +++ git -C /opt/openhabian log --pretty=format:%h -n 1 ++ shorthash=08bc4ff ++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' + echo '2022-01-25_20:00:27_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' 2022-01-25_20:00:27_CET [openHABian] openHABian configuration tool version: [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff) ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_20:00:27_CET [openHABian] Checking for changes in origin branch openHAB3... ' 2022-01-25_20:00:27_CET [openHABian] Checking for changes in origin branch openHAB3... + is_stretch + [[ '' == \s\t\r\e\t\c\h ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ stretch ]] + return 1 + is_xenial + [[ '' == \x\e\n\i\a\l ]] ++ cat /etc/os-release + [[ PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)" NAME="Raspbian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs" =~ xenial ]] + return 1 + git -C /opt/openhabian config user.email openhabian@openHABian + git -C /opt/openhabian config user.name openhabian + git -C /opt/openhabian fetch --quiet origin ++ git -C /opt/openhabian rev-parse openHAB3 ++ git -C /opt/openhabian rev-parse '@{u}' + [[ 08bc4ff34e8b7b059c126b6b999039cef7b48d33 == 08bc4ff34e8b7b059c126b6b999039cef7b48d33 ]] + echo OK OK + openhabian_announcements + [[ -z 1 ]] + local altReadNews + local newsFile + local readNews + altReadNews=/tmp/NEWS.md + newsFile=/opt/openhabian/NEWS.md + readNews=/opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /opt/openhabian/docs/NEWS.md + cmp --silent /opt/openhabian/NEWS.md /tmp/NEWS.md ++ cat /opt/openhabian/NEWS.md + whiptail --title 'openHABian announcements' --yes-button 'Stop displaying' --no-button 'Keep displaying' --defaultno --scrolltext --yesno 'Hit tab to unselect buttons and scroll through the text using UP/DOWN or PGUP/PGDN. All announcements are stored in `/opt/openhabian/docs/CHANGELOG.md` for you to lookup. ## Major Java provider switch ## December 15, 2021 We have switched to supporting only the OpenJDK package provided by default from the APT repo for all new installations of openHABian. Existing installations will be unaffected, however you will no longer receive updates to your current Java install until you install Java from the new provider which you can do by running menu option 45. Experimental support for Java 17 has also been added along with this change. In the future once Adoptium (formerly AdoptOpenJDK) releases a Debian based package repository support for Adoptium Java installs will be added as well. ## Node-RED and openHAB 3 ## December 10, 2021 We have updated the package of the Node-RED addon for openHAB 3 to `node-red-contrib-openhab3` to better support openHAB 3 installations which use this addon. You can install it today using `openhabian-config` menu option 25, which will install / upgrade all necessary components for Node-RED operation. ## openHABian 1.7 ## December 1, 2021 We have upgraded our base operating system to Raspberry Pi OS Bullseye. As usual upgrades on supported systems will be unaffected, use the `openhabian-config` menu to apply any updates available to your system. We will not automatically update your current base system (i.e buster -> bullseye) - don'\''t fix what ain'\''t broke. Debian buster will be at least supported two more years. If you are eager to upgrade, read up on `dist-upgrade` or reinstall your system. Please note that if you choose to upgrade and not reinstall, you are on your own, don'\''t expect to get support from the developers of openHABian if something goes wrong. Noteworthy changes since last image release: * New base OS: Raspberry Pi OS Bullseye * Added support for Raspberry Pi Zero 2 W * Ability to update zram without reinstalling it * More robust Java install routine * Fixed Amanda install not prompting for email address to send reports to * General bug fixes Known bugs: * Homegear is currently broken on Bullseye (complain to their devs)' 27 84 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_20:00:29_CET [openHABian] Switching to branch openHAB3... ' 2022-01-25_20:00:29_CET [openHABian] Switching to branch openHAB3... + git -C /opt/openhabian checkout --quiet openHAB3 + echo OK OK + bashrc_copy ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_20:00:29_CET [openHABian] Adding slightly tuned bash configuration files to system... ' 2022-01-25_20:00:29_CET [openHABian] Adding slightly tuned bash configuration files to system... + cp /opt/openhabian/includes/generic/bash.bashrc /etc/bash.bashrc + cp /opt/openhabian/includes/generic/bashrc-root /root/.bashrc + cp /opt/openhabian/includes/generic/bash_profile /home/openhabian/.bash_profile + cp /opt/openhabian/includes/generic/bash_aliases /home/openhabian/.bash_aliases + chown openhabian:openhabian /home/openhabian/.bash_aliases /home/openhabian/.bash_history /home/openhabian/.bash_logout /home/openhabian/.bash_profile + echo OK OK + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='01 | Select Branch' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 01 | Select Branch == '' ]] + [[ 01 | Select Branch == \0\0* ]] + [[ 01 | Select Branch == \0\1* ]] + openhabian_update + local branch + local current + local introText + local key + local main=OFF + local openHAB3=OFF + local own=no + local selection + local shorthashAfter + local shorthashBefore + local stable=OFF ++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD + current=openHAB3 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_20:00:31_CET [openHABian] Updating myself... ' 2022-01-25_20:00:31_CET [openHABian] Updating myself... + [[ 0 == 1 ]] + [[ -n 1 ]] + [[ openHAB3 == \s\t\a\b\l\e ]] + [[ openHAB3 == \m\a\i\n ]] + [[ openHAB3 == \o\p\e\n\H\A\B\3 ]] + introText='You are currently using the "openHAB3" openHABian environment version.\n\nThe openHABian version to contain the very latest code for openHAB 3 is called "main".\nThis is providing you with the latest (openHAB3!) features but less people have tested it so it is a little more likely that you run into errors.\nYou can step back a little and switch to use the stable version now called "openHAB3".\nYou can switch at any time by selecting this menu option again or by setting the '\''clonebranch='\'' parameter in '\''/etc/openhabian.conf'\''.\n' + [[ openHAB3 == \s\t\a\b\l\e ]] + [[ openHAB3 == \o\p\e\n\H\A\B\3 ]] + openHAB3=ON + [[ no == \n\o ]] ++ whiptail --title 'openHABian version' --radiolist 'You are currently using the "openHAB3" openHABian environment version.\n\nThe openHABian version to contain the very latest code for openHAB 3 is called "main".\nThis is providing you with the latest (openHAB3!) features but less people have tested it so it is a little more likely that you run into errors.\nYou can step back a little and switch to use the stable version now called "openHAB3".\nYou can switch at any time by selecting this menu option again or by setting the '\''clonebranch='\'' parameter in '\''/etc/openhabian.conf'\''.\n' 19 90 3 openHAB3 'recommended standard version of openHABian (openHAB 3)' ON main 'very latest version of openHABian (openHAB 3)' OFF stable 'old version of openHABian (openHAB 2)' OFF + selection=openHAB3 + read -r -t 1 -n 1 key + [[ -n '' ]] + branch=openHAB3 + sed -i 's|^clonebranch=.*$|clonebranch=openHAB3|g' /etc/openhabian.conf ++ git -C /opt/openhabian log --pretty=format:%h -n 1 + shorthashBefore=08bc4ff + mv /opt/openhabian/docs/NEWS.md /tmp/NEWS.md mv: der Aufruf von stat für '/opt/openhabian/docs/NEWS.md' ist nicht möglich: Datei oder Verzeichnis nicht gefunden + cond_redirect update_git_repo /opt/openhabian openHAB3 + [[ -n '' ]] + echo -e '\n\033[90;01m$ update_git_repo /opt/openhabian openHAB3 \033[39;49;00m' $ update_git_repo /opt/openhabian openHAB3 + update_git_repo /opt/openhabian openHAB3 + local branch + local path + branch=openHAB3 + path=/opt/openhabian ++ timestamp ++ date +%F_%T_%Z ++ basename /opt/openhabian + echo -n '2022-01-25_20:00:34_CET [openHABian] Updating openhabian, openHAB3 branch from git... ' 2022-01-25_20:00:34_CET [openHABian] Updating openhabian, openHAB3 branch from git... + cond_redirect git -C /opt/openhabian fetch origin + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/openhabian fetch origin \033[39;49;00m' $ git -C /opt/openhabian fetch origin + git -C /opt/openhabian fetch origin + return 0 + cond_redirect git -C /opt/openhabian fetch --tags --force --prune + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/openhabian fetch --tags --force --prune \033[39;49;00m' $ git -C /opt/openhabian fetch --tags --force --prune + git -C /opt/openhabian fetch --tags --force --prune + return 0 + cond_redirect git -C /opt/openhabian reset --hard origin/openHAB3 + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/openhabian reset --hard origin/openHAB3 \033[39;49;00m' $ git -C /opt/openhabian reset --hard origin/openHAB3 + git -C /opt/openhabian reset --hard origin/openHAB3 HEAD ist jetzt bei 08bc4ff Fix Java install + return 0 + cond_redirect git -C /opt/openhabian clean --force -x -d + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/openhabian clean --force -x -d \033[39;49;00m' $ git -C /opt/openhabian clean --force -x -d + git -C /opt/openhabian clean --force -x -d + return 0 + cond_redirect git -C /opt/openhabian checkout openHAB3 + [[ -n '' ]] + echo -e '\n\033[90;01m$ git -C /opt/openhabian checkout openHAB3 \033[39;49;00m' $ git -C /opt/openhabian checkout openHAB3 + git -C /opt/openhabian checkout openHAB3 Bereits auf 'openHAB3' Ihr Branch ist auf demselben Stand wie 'origin/openHAB3'. + return 0 + echo OK OK + return 0 ++ git -C /opt/openhabian log --pretty=format:%h -n 1 + shorthashAfter=08bc4ff + [[ 08bc4ff == \0\8\b\c\4\f\f ]] + echo 'OK - No remote changes detected. You are up to date!' OK - No remote changes detected. You are up to date! + return 0 + '[' 0 -ne 0 ']' + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice='01 | Select Branch' + RET=0 + '[' 0 -eq 1 ']' + '[' 0 -eq 255 ']' + [[ 01 | Select Branch == '' ]] + [[ 01 | Select Branch == \0\0* ]] + [[ 01 | Select Branch == \0\1* ]] + openhabian_update + local branch + local current + local introText + local key + local main=OFF + local openHAB3=OFF + local own=no + local selection + local shorthashAfter + local shorthashBefore + local stable=OFF ++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD + current=openHAB3 ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_20:00:42_CET [openHABian] Updating myself... ' 2022-01-25_20:00:42_CET [openHABian] Updating myself... + [[ 0 == 1 ]] + [[ -n 1 ]] + [[ openHAB3 == \s\t\a\b\l\e ]] + [[ openHAB3 == \m\a\i\n ]] + [[ openHAB3 == \o\p\e\n\H\A\B\3 ]] + introText='You are currently using the "openHAB3" openHABian environment version.\n\nThe openHABian version to contain the very latest code for openHAB 3 is called "main".\nThis is providing you with the latest (openHAB3!) features but less people have tested it so it is a little more likely that you run into errors.\nYou can step back a little and switch to use the stable version now called "openHAB3".\nYou can switch at any time by selecting this menu option again or by setting the '\''clonebranch='\'' parameter in '\''/etc/openhabian.conf'\''.\n' + [[ openHAB3 == \s\t\a\b\l\e ]] + [[ openHAB3 == \o\p\e\n\H\A\B\3 ]] + openHAB3=ON + [[ no == \n\o ]] ++ whiptail --title 'openHABian version' --radiolist 'You are currently using the "openHAB3" openHABian environment version.\n\nThe openHABian version to contain the very latest code for openHAB 3 is called "main".\nThis is providing you with the latest (openHAB3!) features but less people have tested it so it is a little more likely that you run into errors.\nYou can step back a little and switch to use the stable version now called "openHAB3".\nYou can switch at any time by selecting this menu option again or by setting the '\''clonebranch='\'' parameter in '\''/etc/openhabian.conf'\''.\n' 19 90 3 openHAB3 'recommended standard version of openHABian (openHAB 3)' ON main 'very latest version of openHABian (openHAB 3)' OFF stable 'old version of openHABian (openHAB 2)' OFF + selection= + return 0 + '[' 0 -ne 0 ']' + true + show_main_menu + local choice + local version +++ get_git_revision +++ local branch +++ local commitDate +++ local shorthash ++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD +++ branch=openHAB3 ++++ git -C /opt/openhabian log --pretty=format:%aI -n 1 +++ commitDate=2022-01-24T16:28:12-07:00 ++++ git -C /opt/openhabian log --pretty=format:%h -n 1 +++ shorthash=08bc4ff +++ echo '[openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' ++ whiptail --title 'openHABian Configuration Tool — [openHAB3]{2022-01-24T16:28:12-07:00}(08bc4ff)' --menu 'Setup Options' 19 116 12 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and this tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' 'Update all installed software packages (incl. openHAB) to their latest version' '03 | Install openHAB' 'Install or upgrade to openHAB 3' '04 | Import config' 'Import an openHAB 3 configuration from file or URL' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basic openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Settings' 'A range of system and hardware related configuration steps ►' '40 | openHAB Related' 'Switch the installed openHAB version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►' + choice= + RET=1 + '[' 1 -eq 1 ']' + return 255 + system_check_default_password + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + local algo + local defaultPassword + local defaultUser + local generatedPassword + local introText + local originalPassword + local salt + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + id -u pi + is_pi + is_pifour + [[ '' == \p\i\4 ]] + grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo + return 0 + return 0 + defaultUser=openhabian + defaultPassword=openhabian ++ grep -w openhabian /etc/shadow ++ cut -d: -f2 + originalPassword='$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f2 + algo=y + introText='The default password was detected on your system! That is a serious security concern. Bad guys or malicious programs in your subnet are able to gain root access!\n\nPlease set a strong password by typing the command '\''passwd openhabian'\''!' ++ echo '$y$j9T$QRtE2O.QSYHloEZnrjvGR/$N8fiEkrpuxeBPRGKo6u2tq5yLulLfxDWRdivQr/ykg0' ++ cut '-d$' -f3 + salt=j9T + export algo defaultPassword salt ++ perl -le 'print crypt("$ENV{defaultPassword}","\$$ENV{algo}\$$ENV{salt}\$")' + generatedPassword='$y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA' ++ timestamp ++ date +%F_%T_%Z + echo -n '2022-01-25_20:00:47_CET [openHABian] Checking for default openHABian username:password combination... ' 2022-01-25_20:00:47_CET [openHABian] Checking for default openHABian username:password combination... ++ id -u openhabian + [[ -n 1000 ]] + [[ $y$j9T$$1DJdHt2WNxWqFR3sUxwYKh.KdyI9MF4X/A9710MJGjA == \$\y\$\j\9\T\$\Q\R\t\E\2\O\.\Q\S\Y\H\l\o\E\Z\n\r\j\v\G\R\/\$\N\8\f\i\E\k\r\p\u\x\e\B\P\R\G\K\o\6\u\2\t\q\5\y\L\u\l\L\f\x\D\W\R\d\i\v\Q\r\/\y\k\g\0 ]] + echo OK OK ++ timestamp ++ date +%F_%T_%Z + echo -e '2022-01-25_20:00:47_CET [openHABian] We hope you got what you came for! See you again soon ;)' 2022-01-25_20:00:47_CET [openHABian] We hope you got what you came for! See you again soon ;) + cd /opt/openhabian