CPAN statt apt-get install -> Fhem hängt

Begonnen von Ajuba, 04 Januar 2019, 20:31:48

Vorheriges Thema - Nächstes Thema

andies

ja, genau. Also sudo und dann wollte ich updaten und das war es dann.
FHEM 6.1 auf RaspPi3 (Raspbian:  6.1.21-v8+; Perl: v5.32.1)
SIGNALduino (433 MHz) und HM-UART (868 MHz), Sonoff, Blitzwolf, Somfy RTS, CAME-Gartentor, Volkszähler, Keyence-Sensor, Homematic-Sensoren und -thermostat, Ferraris-Zähler für Wasseruhr, Openlink-Nachbau Viessmann

Otto123

Bist Du sicher?
- wenn ich sudo cpan starte dann kommt anschließend bei der Installation:
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
und nicht /home/pi/  :o wie in deiner Fehlermeldung!

Gruß Otto
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

andies

Ich habe das gleich nochmal probiert - jetzt erscheint auch '/root/ usw'. Seitdem steht allerdings der Cursor und das Gerät ist nicht erreichbar
cpan[1]> install CPAN
Fetching with LWP:
http://www.cpan.org/authors/01mailrc.txt.gz
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Fetching with LWP:
http://www.cpan.org/modules/02packages.details.txt.gz
Reading '/root/.cpan/sources/modules/02packages.details.txt.gz'
  Database was generated on Sun, 28 Jun 2020 16:17:02 GMT
.............
  New CPAN.pm version (v2.28) available.
  [Currently running version is v2.20]
  You might want to try
    install CPAN
    reload cpan
  to both upgrade CPAN.pm and run the new version without leaving
  the current session.

.................................................

Da ist irgendwo der Wurm drin. Ich tendiere zu kompletter Neuinstallation.

<edit> Load 22.
FHEM 6.1 auf RaspPi3 (Raspbian:  6.1.21-v8+; Perl: v5.32.1)
SIGNALduino (433 MHz) und HM-UART (868 MHz), Sonoff, Blitzwolf, Somfy RTS, CAME-Gartentor, Volkszähler, Keyence-Sensor, Homematic-Sensoren und -thermostat, Ferraris-Zähler für Wasseruhr, Openlink-Nachbau Viessmann

Otto123

Also meine Meinung: cpan ist ne Zicke!
Ich habe festgestellt: wenn man die Zeile per Copy&Paste einfügt: macht er irgendwas - "sinnloses".
Wenn ich den Befehl eintippe (CPAN groß) dann installiert er wirklich - sieht in etwa so aus.
cpan[2]> install CPAN
Running install for module 'CPAN'
Checksum for /root/.cpan/sources/authors/id/A/AN/ANDK/CPAN-2.28.tar.gz ok
Scanning cache /root/.cpan/build for sizes
............................................................................DONE
'YAML' not installed, will not store persistent state
Argument "1.4417_001" isn't numeric in numeric ge (>=) at /usr/local/share/perl/5.24.1/CPAN/Distribution.pm line 651.
Configuring A/AN/ANDK/CPAN-2.28.tar.gz with Makefile.PL
Importing PAUSE public key into your GnuPG keychain... done!
(You may wish to trust it locally with 'gpg --lsign-key 450F89EC')
.....

Danach geht reload und CPAN ist aktuell. Aber ob das Dein Problem wirklich löst?
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

andies

Absolute Zicke. Ich habe die Großschreibung genommen. Nee, da ist irgendwas unten faul, ich werfe das alles raus. (Man muss die Großschreibung nehmen, weil Perl ja zwischen cpan und CPAN unterscheidet.)
FHEM 6.1 auf RaspPi3 (Raspbian:  6.1.21-v8+; Perl: v5.32.1)
SIGNALduino (433 MHz) und HM-UART (868 MHz), Sonoff, Blitzwolf, Somfy RTS, CAME-Gartentor, Volkszähler, Keyence-Sensor, Homematic-Sensoren und -thermostat, Ferraris-Zähler für Wasseruhr, Openlink-Nachbau Viessmann

Otto123

Zitat von: andies am 28 Juni 2020, 20:01:33
... weil Perl ja zwischen cpan und CPAN unterscheidet.)
ja klar, deswegen schreibt man erst install CPAN und dann reload cpan  :o ;D

egal, wenn es dauerhaft nicht geht - ich weiß keinen Weg es mikrochirurgisch zu heilen :)
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

Wernieman

Hast DU gesehen, das er ein CPAN-Update bei Dir anbietet?
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

andies

Ja, habe ich - das problem ist eher Load 22 und die ewige Ladezeit. Da ist etwas faul.

Das hat natürlich eine Ursache, die ich im Forum geflissentlich verschweige: Ich hatte ein update schon mal abgebrochen, weil das eine halbe Stunde dauerte. Ich nehme an, da hat er sich Covid-19 eingefangen, jetzt hustet er vor sich hin.
FHEM 6.1 auf RaspPi3 (Raspbian:  6.1.21-v8+; Perl: v5.32.1)
SIGNALduino (433 MHz) und HM-UART (868 MHz), Sonoff, Blitzwolf, Somfy RTS, CAME-Gartentor, Volkszähler, Keyence-Sensor, Homematic-Sensoren und -thermostat, Ferraris-Zähler für Wasseruhr, Openlink-Nachbau Viessmann

Wernieman

<Scherz>
SOFORT STILLEGEN .... Nicht das Du noch 14 Tage in Quarantäne musst ....
</Scherz>

Aber mal ernsthaft: Welcher Prozess erzeugt bei Dir die Load? Was sagt denn CPU/Speicher etc. zu dem Zeitpunkt?
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

amenomade

Wie im anderen Thread geschrieben (danke Wernieman für den Hinweis dort)  könntest Du mit cpanm (cpanminus) probieren, der viel weniger Ressourcen braucht.

Zitatcpanm uses much less memory. This makes it a better choice for environments where RAM is limited, such as shared hosting servers, where regular cpan might die before completing installation task, due to attempting to use more than available memory.
According to cpanm's (1.7044) documentation "When running, it requires only 10MB of RAM"
Quelle
Pi 3B, Alexa, CUL868+Selbstbau 1/2λ-Dipol-Antenne, USB Optolink / Vitotronic, Debmatic und HM / HmIP Komponenten, Rademacher Duofern Jalousien, Fritz!Dect Thermostaten, Proteus

andies

Natürlich erzeugt Perl den Load, komischerweise 20% CPU. Also, wir machen mal Schluss hier mit dem Rätselraten, ich mache das System platt und gut ist. Trotzdem danke für die Hilfe (ich hatte eigentlich vor, cpan neu zu installieren, weiss aber absolut nicht, wie das geht). Ich habe das System erst gestern aufgesetzt, ist also nicht so viel Mehrarbeit.
FHEM 6.1 auf RaspPi3 (Raspbian:  6.1.21-v8+; Perl: v5.32.1)
SIGNALduino (433 MHz) und HM-UART (868 MHz), Sonoff, Blitzwolf, Somfy RTS, CAME-Gartentor, Volkszähler, Keyence-Sensor, Homematic-Sensoren und -thermostat, Ferraris-Zähler für Wasseruhr, Openlink-Nachbau Viessmann

Wernieman

Load <> CPU

Load bedeutet nur, das Prozesse auf IO warten. Das kann Festplatte aber auch Netzwerk sein.

Als Anekdote:
Habe mal beruflich mch auf einem Server mit Load=10.000 Bewegt und der lief flüssig ... das enstprechende PHP-Prozesse auf Ihre Datenbank warteten (Die weg war), war dem Server egal. Dagegen war ein anderer Server mit Load=2 tot .....
https://de.wikipedia.org/wiki/Load
Deshalb nochmals die Frage: Was erzeugt den Load? Auf die CPU zu gucken hilft nicht viel (s.o.)
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

andies

#27
Ich nehme an zwei fehlende Perl-Pakete in FHEM:
Linux raspfhem 4.19.118+ #1311 Mon Apr 27 14:16:15 BST 2020 armv6l

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sun Jun 28 18:58:16 2020 from 192.168.2.16

top - 21:53:29 up  8:08,  4 users,  load average: 1,24, 1,10, 1,35
Tasks: 108 total,   2 running, 106 sleeping,   0 stopped,   0 zombie
%Cpu(s): 97,4 us,  2,6 sy,  0,0 ni,  0,0 id,  0,0 wa,  0,0 hi,  0,0 si,  0,0 st
MiB Mem :    432,4 total,     58,3 free,    166,2 used,    207,9 buff/cache
MiB Swap:    100,0 total,      1,3 free,     98,7 used.    211,0 avail Mem

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU 
678 fhem      20   0  137200  85460   6676 R  97,1  19,3 260:12.88 perl
5501 pi        20   0   10304   3096   2576 R   1,6   0,7   0:00.34 top                                                                                                     7 root      20   0       0      0      0 S   0,3   0,0   0:30.84 ksoftirqd/0                                                                                          5471 root      20   0       0      0      0 I   0,3   0,0   0:00.34 kworker/0:1-events                                                                                      1 root      20   0   33728   4768   3724 S   0,0   1,1   0:56.60 systemd                                                                                                 2 root      20   0       0      0      0 S   0,0   0,0   0:16.90 kthreadd                                                                                                6 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 mm_percpu_wq                                                                                            8 root      20   0       0      0      0 S   0,0   0,0   0:00.01 kdevtmpfs                                                                                               9 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 netns                                                                                                  11 root      20   0       0      0      0 S   0,0   0,0   0:00.04 khungtaskd                                                                                             12 root      20   0       0      0      0 S   0,0   0,0   0:00.06 oom_reaper                                                                                             13 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 writeback                                                                                              14 root      20   0       0      0      0 S   0,0   0,0   0:00.00 kcompactd0                                                                                             15 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 crypto                                                                                                 16 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 kblockd                                                                                                17 root      rt   0       0      0      0 S   0,0   0,0   0:00.00 watchdogd                                                                                              18 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 rpciod                                                                                                 19 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 kworker/u3:0                                                                                           20 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 xprtiod                                                                                                23 root      20   0       0      0      0 S   0,0   0,0  69:28.16 kswapd0                                                                                                24 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 nfsiod                                                                                                 35 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 kthrotld                                                                                               36 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 iscsi_eh                                                                                               37 root       0 -20       0      0      0 I   0,0   0,0   0:00.00 dwc_otg                                                                                             
FHEM 6.1 auf RaspPi3 (Raspbian:  6.1.21-v8+; Perl: v5.32.1)
SIGNALduino (433 MHz) und HM-UART (868 MHz), Sonoff, Blitzwolf, Somfy RTS, CAME-Gartentor, Volkszähler, Keyence-Sensor, Homematic-Sensoren und -thermostat, Ferraris-Zähler für Wasseruhr, Openlink-Nachbau Viessmann

Wernieman

Interessanter als eine top-Ausgabe:
ps aux --sort=-pcpu | head -n10
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

andies

USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
fhem       678 53.6 18.9 135612 83964 ?        S    13:45 263:55 /usr/bin/perl fhem.pl fhem.cfg
root        23 14.0  0.0      0     0 ?        S    13:44  69:28 [kswapd0]
mysql      462  0.8  5.2 718588 23192 ?        Ssl  13:45   4:19 /usr/sbin/mysqld
pi        5544  0.5  0.8   8464  3628 pts/1    Ss   21:55   0:00 -bash
systemd+   182  0.4  0.5  22396  2524 ?        Ssl  13:45   1:58 /lib/systemd/systemd-timesyncd
root       238  0.4  0.2   7960   996 ?        Ss   13:45   2:07 /usr/sbin/cron -f
pi         785  0.3  2.5 144116 11204 ?        Sl   13:45   1:49 lxpanel --profile LXDE-pi
root      5531  0.3  1.4  12220  6264 ?        Ss   21:54   0:00 sshd: pi [priv]
FHEM 6.1 auf RaspPi3 (Raspbian:  6.1.21-v8+; Perl: v5.32.1)
SIGNALduino (433 MHz) und HM-UART (868 MHz), Sonoff, Blitzwolf, Somfy RTS, CAME-Gartentor, Volkszähler, Keyence-Sensor, Homematic-Sensoren und -thermostat, Ferraris-Zähler für Wasseruhr, Openlink-Nachbau Viessmann