FHEM Server ohne Internet

Begonnen von moonsorrox, 27 August 2019, 12:05:23

Vorheriges Thema - Nächstes Thema

MadMax-FHEM

Welche Module nutzt du, die evtl. Internet brauchen/zugreifen?

Evtl. eines was (noch) nicht non-blocking ist...
...Internet weg -> blockiert -> nix geht mehr...

Aber auch schon bei non-blocking Implementierung kann es bei der "Namensauflösung" zum Blockieren kommen...
...daher ja das Attribut dnsServer!

Dadurch wird auch die "Namensauflösung" non-blocking...

Aber: wenn du Module verwendest, die non-blocking Internetzugriffe implementiert haben bleibt das Problem nat. trotzdem...

Gruß, Joachim
FHEM PI3B+ Bullseye: HM-CFG-USB, 40x HM, ZWave-USB, 13x ZWave, EnOcean-PI, 15x EnOcean, HUE/deCONZ, CO2, ESP-Multisensor, Shelly, alexa-fhem, ...
FHEM PI2 Buster: HM-CFG-USB, 25x HM, ZWave-USB, 4x ZWave, EnOcean-PI, 3x EnOcean, Shelly, ha-bridge, ...
FHEM PI3 Buster (Test)

Otto123

sehr seltsam.
Wenn Du anstatt 8083 deine vollständige url eingibst? Also wie sonst im Browser?

Der Befehl list in deiner normalen Weboberfläche funktioniert?

Was Du noch probieren kannst: Mit diesen drei Zeilen in der FHEM Kommandozeile startest Du eine zweite FHEM Instanz.
"wget -qO fhem2.cfg https://svn.fhem.de/fhem/trunk/fhem/fhem.cfg"
"sed -i -e 's/\/fhem/\/fhem2/;;s/\/eventTypes/\/eventTypes2/;;s/8083/8093/;;$aattr initialUsbCheck disable 1' fhem2.cfg"
"perl /opt/fhem/fhem.pl /opt/fhem/fhem2.cfg"


Diese sollte danach mit Port 8093 erreichbar sein. Dann kannst Du Internet abziehen und testen. In diesem FHEM ist außer dem Web nichts definiert.
Geht das - wüsste man es liegt nicht am Host sondern an irgendetwas in Deiner Konfig im FHEM.
Viele Grüße aus Leipzig  ⇉  nächster Stammtisch an der Lindennaundorfer Mühle
RaspberryPi B B+ B2 B3 B3+ ZeroW,HMLAN,HMUART,Homematic,Fritz!Box 7590,WRT3200ACS-OpenWrt,Sonos,VU+,Arduino nano,ESP8266,MQTT,Zigbee,deconz

amenomade

Ist es FHEM, der auf dem Port 8083 lauscht oder irgendwelcher Proxy oder Zwischenkomponent?
sudo netstat -tulp | grep 8083
Pi 3B, Alexa, CUL868+Selbstbau 1/2λ-Dipol-Antenne, USB Optolink / Vitotronic, Debmatic und HM / HmIP Komponenten, Rademacher Duofern Jalousien, Fritz!Dect Thermostaten, Proteus

Wuppi68

was sagt überhaupt das FHEM Logfile?
wurde FHEM schon neu gestartet?
wurde der Server schon neu gestartet?
Abnormalien im /var/log/syslog ?
Abnormalien im output von dmesg ?
Läuft fhem vielleicht doppelt? (das ist meine Glaskugel)
FHEM unter Proxmox als VM

moonsorrox

so da bin ich wieder leider nur kurz.
Ich beantworte mal die Fragen:

Zitat von: MadMax-FHEM am 27 August 2019, 15:16:12
Welche Module nutzt du, die evtl. Internet brauchen/zugreifen?
das müßte ich der Reihe nach raus suchen. Momentan was ich weiß sind die Tankstellen
Eine macht grad Probleme
2019.08.27 17:32:32 3: Famila: Read response to update didn't match any Reading
2019.08.27 17:29:47 3: CUL_HM set KU_Rollladen statusRequest
2019.08.27 17:29:37 3: CUL_HM set KU_Rollladen pct 100
2019.08.27 17:02:32 3: Famila: Read response to update didn't match any Reading
2019.08.27 17:02:25 3: CUL_HM set KU_Rollladen pct 100
2019.08.27 16:59:26 3: CUL_HM set KU_Rollladen statusRequest
2019.08.27 16:57:24 3: CUL_HM set KU_Rollladen pct 100
2019.08.27 16:32:32 3: Famila: Read response to update didn't match any Reading


Zitat von: Otto123 am 27 August 2019, 15:22:00
sehr seltsam.
Wenn Du anstatt 8083 deine vollständige url eingibst? Also wie sonst im Browser?
finde ich auch...!
Ich gabe ja die komplette Adresse ein, oder was meinst du..?


Zitat von: amenomade am 27 August 2019, 16:52:02
Ist es FHEM, der auf dem Port 8083 lauscht oder irgendwelcher Proxy oder Zwischenkomponent?
sudo netstat -tulp | grep 8083

Ausgabe
root@FHEM-Server:~# netstat -tulp | grep 8083
tcp        0      0 *:8083                  *:*                     LISTEN      4015/perl


Zitat von: Wuppi68 am 27 August 2019, 17:14:14
was sagt überhaupt das FHEM Logfile?
wurde FHEM schon neu gestartet?
wurde der Server schon neu gestartet?
Abnormalien im /var/log/syslog ?
Abnormalien im output von dmesg ?
Läuft fhem vielleicht doppelt? (das ist meine Glaskugel)

das Logfile sagt darüber gar nichts, ich sehe nichts was damit zutun haben könnte.
Ja Server wurde schon mehrfach Neu gestartet, mache ich eigentlich immer als Erstes

Die einzigen Fehler bei der Augabe von dmesg sind diese

[    0.000000] No AGP bridge found
[    0.000000] ACPI Error: Gpe0Block - 32-bit FADT register is too long (32 bytes, 256 bits) to convert to GAS struct - 255 bits max, truncating (20131115/tbfadt-202)
[    0.000000] No NUMA configuration found
[    0.575866] Scanning for low memory corruption every 60 seconds
init: Failed to spawn mosquitto main process: unable to execute: No such file or directory
[    2.141826] ieee80211 phy0: Selected rate control algorithm 'iwl-mvm-rs'
[    2.239131] init: Failed to spawn mosquitto main process: unable to execute: No such file or directory
[    2.286025] init: failsafe main process (625) killed by TERM signal
[    2.308752] init: Failed to obtain startpar-bridge instance: Unknown parameter: INSTANCE


mosquitto nutze ich aber nicht mehr, sollte ich evtl. mal deinstallieren.
Ich nutze den MQTT2 Server. evtl. gibt es damit Probleme

So ich hoffe ich habe alles soweit beantwortet, muss auch scho wieder weg  :-[
Intel-NUC i5: FHEM-Server 6.1 :: Perl v5.18.2

Homematic: HM-USB-CFG2,HM-CFG-LAN Adapter, HM-LC-BL1-FM, HM-LC-Sw1PBU-FM, HM-LC-Sw1-PI-2, HM-WDS10-TH-O, HM-CC-TC, HM-LC-SW2-FM

Otto123

ZitatIch gabe ja die komplette Adresse ein, oder was meinst du..?
wie sieht die aus?
Ich meinte:
bash fhemcl.sh <komplette Adresse so wie im Browser mit http oder https und user password davor, also wie im Browser> list WEB

Und nochmal: geht Dein list Befehl im Browser/in der normalen FHEM Oberfläche? Oder ist da was verboten oder wie auch immer?
Viele Grüße aus Leipzig  ⇉  nächster Stammtisch an der Lindennaundorfer Mühle
RaspberryPi B B+ B2 B3 B3+ ZeroW,HMLAN,HMUART,Homematic,Fritz!Box 7590,WRT3200ACS-OpenWrt,Sonos,VU+,Arduino nano,ESP8266,MQTT,Zigbee,deconz

moonsorrox

Zitat von: Otto123 am 27 August 2019, 19:44:42
Ich meinte:
bash fhemcl.sh <komplette Adresse so wie im Browser mit http oder https und user password davor, also wie im Browser> list WEB

Und nochmal: geht Dein list Befehl im Browser/in der normalen FHEM Oberfläche? Oder ist da was verboten oder wie auch immer?

hallo Otto ja der list befehl funktioniert, soll ich die Ausgabe davon posten.?

diesen Befehl von oben soll ich so mal in putty eingeben.?
fhem ist der User und dann mein passwort
bash fhemcl.sh fhem passwort http://10.0.0.50 list WEB
Intel-NUC i5: FHEM-Server 6.1 :: Perl v5.18.2

Homematic: HM-USB-CFG2,HM-CFG-LAN Adapter, HM-LC-BL1-FM, HM-LC-Sw1PBU-FM, HM-LC-Sw1-PI-2, HM-WDS10-TH-O, HM-CC-TC, HM-LC-SW2-FM

amenomade

#37
Ne
http(s)://<Username>:<Password>@<hostName oder IP>:<portNummer>
Also
bash fhemcl.sh http://fhem:passwort@10.0.0.50:8083 list WEB
Pi 3B, Alexa, CUL868+Selbstbau 1/2λ-Dipol-Antenne, USB Optolink / Vitotronic, Debmatic und HM / HmIP Komponenten, Rademacher Duofern Jalousien, Fritz!Dect Thermostaten, Proteus

moonsorrox

Zitat von: amenomade am 28 August 2019, 13:03:57
Ne
http(s)://<Username>:<Password>@<hostName oder IP>:<portNummer>
Also
bash fhemcl.sh http://fhem:passwort@10.0.0.50:8083 list WEB
das kommt als Ausgabe:

         TABLE OF CONTENTS
          About
          Changes
          Scope
          Config files



                This is the default welcome page used to test the correct
                operation of the Apache2 server after installation on Ubuntu systems.
                It is based on the equivalent page on Debian, from which the Ubuntu Apache
                packaging is derived.
                If you can read this page, it means that the Apache HTTP server installed at
                this site is working properly. You should replace this file (located at
                /var/www/html/index.html) before continuing to operate your HTTP server.




                If you are a normal user of this web site and don't know what this page is
                about, this probably means that the site is currently unavailable due to
                maintenance.
                If the problem persists, please contact the site's administrator.



                Ubuntu's Apache2 default configuration is different from the
                upstream default configuration, and split into several files optimized for
                interaction with Ubuntu tools. The configuration system is
                fully documented in
                /usr/share/doc/apache2/README.Debian.gz. Refer to this for the full
                documentation. Documentation for the web server itself can be
                found by accessing the manual if the apache2-doc
                package was installed on this server.



                The configuration layout for an Apache2 web server installation on Ubuntu systems is as follows:


/etc/apache2/
|-- apache2.conf
|       `--  ports.conf
|-- mods-enabled
|       |-- *.load
|       `-- *.conf
|-- conf-enabled
|       `-- *.conf
|-- sites-enabled
|       `-- *.conf


                           apache2.conf is the main configuration
                           file. It puts the pieces together by including all remaining configuration
                           files when starting up the web server.



                           ports.conf is always included from the
                           main configuration file. It is used to determine the listening ports for
                           incoming connections, and this file can be customized anytime.



                           Configuration files in the mods-enabled/,
                           conf-enabled/ and sites-enabled/ directories contain
                           particular configuration snippets which manage modules, global configuration
                           fragments, or virtual host configurations, respectively.



                           They are activated by symlinking available
                           configuration files from their respective
                           *-available/ counterparts. These should be managed
                           by using our helpers

                                a2enmod,
                                a2dismod,


                                a2ensite,
                                a2dissite,

                                and

                                a2enconf,
                                a2disconf
                           . See their respective man pages for detailed information.



                           The binary is called apache2. Due to the use of
                           environment variables, in the default configuration, apache2 needs to be
                           started/stopped with /etc/init.d/apache2 or apache2ctl.
                           Calling /usr/bin/apache2 directly will not work with the
                           default configuration.



                By default, Ubuntu does not allow access through the web browser to
                any file apart of those located in /var/www,
                public_html
                directories (when enabled) and /usr/share (for web
                applications). If your site is using a web document root
                located elsewhere (such as in /srv) you may need to whitelist your
                document root directory in /etc/apache2/apache2.conf.


                The default Ubuntu document root is /var/www/html. You
                can make your own virtual hosts under /var/www. This is different
                to previous releases which provides better security out of the box.


                Please use the ubuntu-bug tool to report bugs in the
                Apache2 package with Ubuntu. However, check <a
                href="https://bugs.launchpad.net/ubuntu/+source/apache2">existing
                bug reports before reporting a new bug.


                Please report bugs specific to modules (such as PHP and others)
                to respective packages, not to the web server itself.

          TABLE OF CONTENTS
          About
          Changes
          Scope
          Config files



                This is the default welcome page used to test the correct
                operation of the Apache2 server after installation on Ubuntu systems.
                It is based on the equivalent page on Debian, from which the Ubuntu Apache
                packaging is derived.
                If you can read this page, it means that the Apache HTTP server installed at
                this site is working properly. You should replace this file (located at
                /var/www/html/index.html) before continuing to operate your HTTP server.




                If you are a normal user of this web site and don't know what this page is
                about, this probably means that the site is currently unavailable due to
                maintenance.
                If the problem persists, please contact the site's administrator.



                Ubuntu's Apache2 default configuration is different from the
                upstream default configuration, and split into several files optimized for
                interaction with Ubuntu tools. The configuration system is
                fully documented in
                /usr/share/doc/apache2/README.Debian.gz. Refer to this for the full
                documentation. Documentation for the web server itself can be
                found by accessing the manual if the apache2-doc
                package was installed on this server.



                The configuration layout for an Apache2 web server installation on Ubuntu systems is as follows:


/etc/apache2/
|-- apache2.conf
|       `--  ports.conf
|-- mods-enabled
|       |-- *.load
|       `-- *.conf
|-- conf-enabled
|       `-- *.conf
|-- sites-enabled
|       `-- *.conf


                           apache2.conf is the main configuration
                           file. It puts the pieces together by including all remaining configuration
                           files when starting up the web server.



                           ports.conf is always included from the
                           main configuration file. It is used to determine the listening ports for
                           incoming connections, and this file can be customized anytime.



                           Configuration files in the mods-enabled/,
                           conf-enabled/ and sites-enabled/ directories contain
                           particular configuration snippets which manage modules, global configuration
                           fragments, or virtual host configurations, respectively.



                           They are activated by symlinking available
                           configuration files from their respective
                           *-available/ counterparts. These should be managed
                           by using our helpers

                                a2enmod,
                                a2dismod,


                                a2ensite,
                                a2dissite,

                                and

                                a2enconf,
                                a2disconf
                           . See their respective man pages for detailed information.



                           The binary is called apache2. Due to the use of
                           environment variables, in the default configuration, apache2 needs to be
                           started/stopped with /etc/init.d/apache2 or apache2ctl.
                           Calling /usr/bin/apache2 directly will not work with the
                           default configuration.



                By default, Ubuntu does not allow access through the web browser to
                any file apart of those located in /var/www,
                public_html
                directories (when enabled) and /usr/share (for web
                applications). If your site is using a web document root
                located elsewhere (such as in /srv) you may need to whitelist your
                document root directory in /etc/apache2/apache2.conf.


                The default Ubuntu document root is /var/www/html. You
                can make your own virtual hosts under /var/www. This is different
                to previous releases which provides better security out of the box.


                Please use the ubuntu-bug tool to report bugs in the
                Apache2 package with Ubuntu. However, check <a
                href="https://bugs.launchpad.net/ubuntu/+source/apache2">existing
                bug reports before reporting a new bug.


                Please report bugs specific to modules (such as PHP and others)
                to respective packages, not to the web server itself.

root@FHEM-Server:~#
Intel-NUC i5: FHEM-Server 6.1 :: Perl v5.18.2

Homematic: HM-USB-CFG2,HM-CFG-LAN Adapter, HM-LC-BL1-FM, HM-LC-Sw1PBU-FM, HM-LC-Sw1-PI-2, HM-WDS10-TH-O, HM-CC-TC, HM-LC-SW2-FM

moonsorrox

Zitat von: Otto123 am 27 August 2019, 15:22:00

Was Du noch probieren kannst: Mit diesen drei Zeilen in der FHEM Kommandozeile startest Du eine zweite FHEM Instanz.
"wget -qO fhem2.cfg https://svn.fhem.de/fhem/trunk/fhem/fhem.cfg"
"sed -i -e 's/\/fhem/\/fhem2/;;s/\/eventTypes/\/eventTypes2/;;s/8083/8093/;;$aattr initialUsbCheck disable 1' fhem2.cfg"
"perl /opt/fhem/fhem.pl /opt/fhem/fhem2.cfg"


Diese sollte danach mit Port 8093 erreichbar sein. Dann kannst Du Internet abziehen und testen. In diesem FHEM ist außer dem Web nichts definiert.
Geht das - wüsste man es liegt nicht am Host sondern an irgendetwas in Deiner Konfig im FHEM.
das eingeben in der Fhem Kommandozeile scheitert bei mir an dem ersten Befehl schon
da kommt folgendes  "Unknown command wget, try help."
Intel-NUC i5: FHEM-Server 6.1 :: Perl v5.18.2

Homematic: HM-USB-CFG2,HM-CFG-LAN Adapter, HM-LC-BL1-FM, HM-LC-Sw1PBU-FM, HM-LC-Sw1-PI-2, HM-WDS10-TH-O, HM-CC-TC, HM-LC-SW2-FM

amenomade

#40
Also... es sieht so aus, wie ob meine obere Vermutung stimmte...

Das ist nicht fhem, der antwortet, sondern Apache.
Das plus die Art und Weise wie dein Apache Server konfiguriert ist, könnte erklären, warum ohne Internet kein Zugriff auf Fhem möglich ist...

Hast Du Apache installiert? Wofür? Und wie ist es konfiguriert? Kannst Du ohne Internet und auch mit gestoppten Apache probieren?
Pi 3B, Alexa, CUL868+Selbstbau 1/2λ-Dipol-Antenne, USB Optolink / Vitotronic, Debmatic und HM / HmIP Komponenten, Rademacher Duofern Jalousien, Fritz!Dect Thermostaten, Proteus

moonsorrox

ja ich hatte das mal vor längerer zeit installiert, aber genau weiß ich nicht wann.
Gemacht habe ich das weil ich mal Letsencryt Zertifikat nutzen wollte das habe ich dann aber nicht mehr genutzt.
Ich brauche den Apache da nicht drauf, ist bei mir aber in Vergessenheit geraten. Ich denke ich werde den jetzt mal versuchen zu deinstllieren, am liebsten Rückstandslos...

Weißt du wie ich das genau schaffe..? mit apt-get remove apache2 ist das glaube ich nicht getan
Intel-NUC i5: FHEM-Server 6.1 :: Perl v5.18.2

Homematic: HM-USB-CFG2,HM-CFG-LAN Adapter, HM-LC-BL1-FM, HM-LC-Sw1PBU-FM, HM-LC-Sw1-PI-2, HM-WDS10-TH-O, HM-CC-TC, HM-LC-SW2-FM

Christoph Morrison

Zeig mal bitte den Output von ip a auf FHEM-Server.

Und bitte den Output von apache2ctl -S auf FHEM-Server.

moonsorrox

apache habe ich schon runter geschmissen, dass war wohl der Übeltäter.
Habe das INternetkabel am Router abgezogen und nun komme ich auch wieder auf mein Fhem ohne Internet  ;)

Ausgabe von ip a:
root@FHEM-Server:~# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether b8:ae:ed:77:ba:d2 brd ff:ff:ff:ff:ff:ff
    inet 10.0.0.50/24 brd 10.0.0.255 scope global eth0
       valid_lft forever preferred_lft forever
    inet6 2a02:560:422e:4400:baae:edff:fe77:bad2/64 scope global dynamic
       valid_lft 7045sec preferred_lft 3445sec
    inet6 fd00::baae:edff:fe77:bad2/64 scope global deprecated dynamic
       valid_lft 6468sec preferred_lft 0sec
    inet6 2a02:560:42c2:eb00:baae:edff:fe77:bad2/64 scope global deprecated dynamic
       valid_lft 6413sec preferred_lft 0sec
    inet6 fe80::baae:edff:fe77:bad2/64 scope link
       valid_lft forever preferred_lft forever
3: wlan0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 34:13:e8:40:92:a0 brd ff:ff:ff:ff:ff:ff

Intel-NUC i5: FHEM-Server 6.1 :: Perl v5.18.2

Homematic: HM-USB-CFG2,HM-CFG-LAN Adapter, HM-LC-BL1-FM, HM-LC-Sw1PBU-FM, HM-LC-Sw1-PI-2, HM-WDS10-TH-O, HM-CC-TC, HM-LC-SW2-FM

Otto123

#44
Zitat von: moonsorrox am 28 August 2019, 13:36:02
das eingeben in der Fhem Kommandozeile scheitert bei mir an dem ersten Befehl schon
da kommt folgendes  "Unknown command wget, try help."
Ist ja jetzt quasi geklärt, aber der interessiert mich noch:
Du hast den Befehl so wie ich es geschrieben habe kopiert und "eingeworfen"? Also mit den "Anführungstrichen" vorn unten hinten?
Aber selbst wenn das funktioniert hätte, wärst Du ja dann wieder wahrscheinlich an deinem lokal installierten Apache gescheitert. Das Du uns den jetzt 3 Seiten Posts verschwiegen hast  ::)
Viele Grüße aus Leipzig  ⇉  nächster Stammtisch an der Lindennaundorfer Mühle
RaspberryPi B B+ B2 B3 B3+ ZeroW,HMLAN,HMUART,Homematic,Fritz!Box 7590,WRT3200ACS-OpenWrt,Sonos,VU+,Arduino nano,ESP8266,MQTT,Zigbee,deconz