FHEM auf Synology NAS unter DSM 6.0

Begonnen von Merlin2000, 26 März 2016, 07:59:14

Vorheriges Thema - Nächstes Thema

nsu1200c

Moin,
danke für Eure Hinweise, denke es war ein Prob mit meinen versch. Perl Installationen und USB Kernels, jetzt alle runter und nur Package Perl und Martin sein Perl mit den USB Kernels und schon läuft der CUL wieder.

Allerdings ist USB Kernel Modul im Paketzentrum immernoch angehalten, es läuft aber alles.


Gruss

Thomas

Synology DS214play
Raspberry Pi 3 / CUL / Homematic Kram

ergerd

Hallo zusammen,

seit dem Update auf DSM 6 scheint PRESENCE (lan_ping) nicht mehr zu funktionieren.
Offensichtlich kann nur root einen ping durchführen.
Kann das jemand bestätigen? Gibt es einen workaround?

Grüße
Rainer
FHEM auf RasPi 4, CUNO, ZigBee, 1Wire2WLAN, DS2423, C-Control II, Buderus KM200, LaCrosseGateway, PCA301, ConBee II, LuftdatenInfo, OneWireGW, Div. ESPs u. Shellys

guhu

@egerd: kein Problem bei mir, läuft aber auch alles mit root ;)

Die Station läuft bei mir nur im lokalen Netz, da interessiert mich das nicht. Und ohne root hast Du eigentlich immer mal wieder Probleme. Die Zeit für die Lösungssuche möchte ich mir sparen.
FHEM 5.9 auf Synology DS918+ (in Docker), HM-CFG-USB2 mit hmlan, HM-CC-RT-DN, HM-SEC-SC-2, nanoCUL,a-culfw,deCONZ,Brennenstuhl-Steckdosen,-FB
Module:ENIGMA2,SONOS,FRITZBOX,FB_CALLLIST,WDT_TIMER,VCONTROL300,WITHINGS

westpaket

#18
Hallo Zusammen,
ich musste aus welchen Gründen auch immer, meine Installation neu aufsetzen, nachdem der Wechsel zu DSM 6.0 problemlos mehrere Wochen lief.
Mit den Paketen von Martin erstmal nicht so schwierig (Danke!).

Aber irgendwas stimmt mit dem HM LAN USB nicht. Es gibt hier sekündliche Disconnects:

2016.05.23 09:00:55 3: CUL_HM set Alarmgeber getConfig
2016.05.23 09:00:55 1: 127.0.0.1:1234 disconnected, waiting to reappear (CUL_HM)
2016.05.23 09:00:55 1: HMLAN_Parse: CUL_HM new condition disconnected
2016.05.23 09:00:55 1: 127.0.0.1:1234 reappeared (CUL_HM)
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:AF11034
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:C
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+227C22,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+26D1DE,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+1F48B4,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+203144,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+285A0C,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+26D242,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+1A763B,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+37476E,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+2A380C,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+1DF17E,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+2A18D1,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+2A3818,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+2522ED,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:+26D1F3,00,00,00
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:Y01,00,
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:Y02,00,
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:Y03,00,
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM I:T1ED56727,04,00,00000000
2016.05.23 09:00:55 1: HMLAN_Parse: CUL_HM new condition init
2016.05.23 09:00:55 5: HMLAN_Send:  CUL_HM S:SDC6AA08E stat:  00 t:00000000 d:01 r:DC6AA08E m:99 8112 F11034 000000
2016.05.23 09:00:56 1: 127.0.0.1:1234 disconnected, waiting to reappear (CUL_HM)
2016.05.23 09:00:56 1: HMLAN_Parse: CUL_HM new condition disconnected
2016.05.23 09:00:56 1: 127.0.0.1:1234 reappeared (CUL_HM)


Auch habe ich die USB Kernels von Jadahl probiert, selbes Bild hier.
Die von Martin bleiben bei mir auch gestoppt.

Kann mir damit jemand weiterhelfen ?

PS: auch der normale CUL scheint das Problem zu haben:

2016.05.23 22:18:33 3: Opening CUL_2 device /dev/ttyACM2
2016.05.23 22:18:33 3: Setting CUL_2 serial parameters to 9600,8,N,1
2016.05.23 22:18:33 3: CUL_2 device opened
2016.05.23 22:18:33 3: CUL_2: Possible commands: BbCFiAZEGMKUYRTVWXefmltux
2016.05.23 22:18:33 2: Setting CUL fhtid from 1034 to 1234


Vielen Dank




Diggewuff

Welche Perl Distribution wird momentan unter DSM 6 auf einer Intel basierten Synology DS713+ empfohlen? Reicht die von Synology selbst? Kann ich diese um fehlende module erweitern?

guhu

Ich hab alles von entware,  läuft.
FHEM 5.9 auf Synology DS918+ (in Docker), HM-CFG-USB2 mit hmlan, HM-CC-RT-DN, HM-SEC-SC-2, nanoCUL,a-culfw,deCONZ,Brennenstuhl-Steckdosen,-FB
Module:ENIGMA2,SONOS,FRITZBOX,FB_CALLLIST,WDT_TIMER,VCONTROL300,WITHINGS

justme1968

für die intel basierten modelle empfehle ich active perl.

gruss
  andre
hue, tradfri, alexa-fhem, homebridge-fhem, LightScene, readingsGroup, ...

https://github.com/sponsors/justme-1968

Diggewuff

#22
Ist Active Perl im fall von DSM updates sehr wartungsintensiv (links und Pfade neu setzen) oder gibt es mittlerweile einen weg zu einer stabilen installation?
Gibt es irgendwo hier im Forum eine gute Anleitung wie ich Active Perl installiere?

Edit: Wo liegt der Unterschied zwischen entware und optware, und für einen newbie wie mich: "wie komme ich an eine Perl installation mit allen in Fhem verwendeten Modulen, alles von entware?"

justme1968

ich hatte mit active perl noch bei keinem update probleme. ich habe ein mal den absoluten pfad zur perl installation ins fhem start script eingetragen. dann muss nichts mehr angefasst werden. active perl hat eine riesige menge an perl modulen, es gibt das ppm tool zum nachinstallierten und cpan funktioniert auch.

active perl ist einfach für ein 'normales' intel linux. ohne irgendwelche dsm abhängigkeiten. und es ist die multithreaded version. z.b. für sonos wichtig.

gruss
  andre
hue, tradfri, alexa-fhem, homebridge-fhem, LightScene, readingsGroup, ...

https://github.com/sponsors/justme-1968

Diggewuff

Ich habe es jetzt hinbekommen Active Perl in version 5.22 zu installieren, musste allerdings um Martin Fischers Fhem SPK zu installieren trotzdem noch das Synology Perl installieren.
sudo ./install.sh
Password:
Checking package...done

Welcome to ActivePerl

    ActivePerl is ActiveState's quality-assured binary build of
    Perl.  In order to install ActivePerl you need to agree to
    the ActivePerl is covered by the ActiveState Community License..

Did you read the LICENSE.txt file? [no] yes
Do you agree to the ActivePerl is covered by the ActiveState Community License.? [no] yes

    This installer can install ActivePerl in any location of your
    choice. You do not need root privileges.  However, please make sure
    that you have write access to this location.

Enter top level directory for install? [/opt/ActivePerl-5.22]

    The ActivePerl documentation is available in HTML format.  If installed
    it will be available from file:///opt/ActivePerl-5.22/html/index.html.
    If not installed you will still be able to read all the basic perl and
    module documentation using the man or perldoc utilities.

Install HTML documentation [yes]
Ok.

    The typical ActivePerl software installation requires 200 megabytes.
    Please make sure enough free space is available before continuing.

Proceed? [yes]
Ok.

Installing ActivePerl...
Copying files to /opt/ActivePerl-5.22...done
Relocating...done (233 files relocated)
Generating HTML documentation...
done
Syncing perl PPM database with .packlists...

done

ActivePerl has been successfully installed at /opt/ActivePerl-5.22.

Please modify your startup environment by adding:

   /opt/ActivePerl-5.22/site/bin:/opt/ActivePerl-5.22/bin to PATH
   /opt/ActivePerl-5.22/site/man:/opt/ActivePerl-5.22/man to MANPATH

For general questions or comments about ActivePerl, please
contact us at <support@activestate.com>.

Thank you for using ActivePerl!

Wie genau bringe ich Fhem jetzt bei das Active perl zu nutzen, wo liegt das Start script und welche zeilen passe ich an?

justme1968

du trägst in /usr/local/FHEM/app/scripts/fhem.sh am anfang PERL=/opt/ActivePerl-5.22 sein statt der PERL zeile die dort steht.

das syno perl solltest du wieder deiinstallieren. das sogt potentiell für verwirrung.

gruss
andre
hue, tradfri, alexa-fhem, homebridge-fhem, LightScene, readingsGroup, ...

https://github.com/sponsors/justme-1968

Diggewuff

Das habe ich schon probiert. Ich bekomme dann vom Packetzentrum allerdings die Mitteilung das dass Packet FHEM davon abhängig ist und das ich zuerst FHEM deinstallieren soll. Hast du ne Idee wie sich diese Meldung umgehen lässt?
Ps: ich habe noch einen Config file Editor und Webmin installiert die auch Perl nutzen kann ich irgendwie dafür sorgen das diese auch Active Perl nutzen?

justme1968

wegen der paket abhängigkeit musst du marin fragen.

das einfachste ist wenn der pfad zum activeperl binary in $PATH auftaucht. so weit wie möglich  am anfang. so wie es bei der installation auch steht:
ZitatPlease modify your startup environment by adding:

   /opt/ActivePerl-5.22/site/bin:/opt/ActivePerl-5.22/bin to PATH
   /opt/ActivePerl-5.22/site/man:/opt/ActivePerl-5.22/man to MANPATH


gruss
  andre
hue, tradfri, alexa-fhem, homebridge-fhem, LightScene, readingsGroup, ...

https://github.com/sponsors/justme-1968

Diggewuff

#28
Vielen Dank erstmal zwischendurch für deine ausführliche Hilfe.

Da ergiebit sich für mich natürlich wieder die Frage an welcher stelle ich das Startup Environment anpassen kann?

Edit: im Verzeichnis /usr/local/FHEM/app/ existiert bei mir kein Ordner scripts. unter dem Pfad /volume1/@appstore/fhem/opt/contrib/Synology/scripts/ liegt allerdings eine Datei fhem.sh die ich jetzt entsprechen angepasst habe.

#!/bin/sh
#
#
HOME='/var/packages/FHEM/target'
PERL=/opt/ActivePerl-5.22
KMOD=/var/packages/usb-driver-kernel
PATH=$HOME:$PERL:$PATH
export PATH

fhem_BIN=${HOME}/fhem.pl
test -x ${fhem_BIN} || { echo "${fhem_BIN} not installed";
if [ "$1" = "stop" ]; then exit 0;
else exit 5; fi; }

# Check for existence of needed config file and read it
fhem_CONFIG=${HOME}/fhem.cfg
test -r ${fhem_CONFIG} || { echo "${fhem_CONFIG} not existing";
if [ "$1" = "stop" ]; then exit 0;
else exit 6; fi; }

fhem_LOG=/var/log/fhem-`date +"%Y-%m"`.log

perl_BIN=`which perl`

#
case "$1" in
start)
echo "Starting fhem "
if [ -d "${KMOD}" ]; then
if [ ! -f "${KMOD}/enabled" ]; then
${KMOD}/scripts/start-stop-status start
touch ${KMOD}/enabled && chmod 775 ${KMOD}/enabled
fi
fi

${perl_BIN} $fhem_BIN $fhem_CONFIG
;;
stop)
echo "Shutting down fhem "
${perl_BIN} $fhem_BIN 7072 shutdown
;;
restart)
$0 stop
$0 start
;;
status)
echo -n "Checking for service fhem "
ps|grep fhem.pl
;;
log)
test -r $fhem_LOG || { echo "$fhem_LOG not existing"; exit 0; }
echo $fhem_LOG
;;
*)
echo "Usage: $0 {start|stop|status|restart|log}"
exit 1
;;
esac
exit 0



fheminfo liefert allerdings:
Fhem info:
  Release  : 5.7
  OS       : linux
  Arch     : x86_64-linux
  Perl     : v5.18.4
  uniqueID : fbdaebdd667e54012fe3cea06b40d98d
  upTime   : 00:09:34

Defined modules:
  FHEMWEB    : 3
  FileLog    : 1
  autocreate : 1
  eventTypes : 1
  notify     : 1
  telnet     : 1

Transmitting this information during an update: no
You can change this via the global attribute sendStatistics


was darauf schließen lässt das immer noch die synology perl version verwendet wird.

in  /volume1/@appstore/fhem/bin/ liegt noch eine weitere fhem.sh mit folgendem Inhalt:
#!/bin/sh
#
#
HOME=/usr/local/fhem/opt
PATH=$HOME:$PATH
export PATH
cd ${HOME}                                                     

fhem_BIN=${HOME}/fhem.pl
test -x ${fhem_BIN} || { echo "${fhem_BIN} not installed";
if [ "$1" = "stop" ]; then exit 0;
else exit 5; fi; }

# Check for existence of needed config file and read it
fhem_CONFIG=${HOME}/fhem.cfg
test -r ${fhem_CONFIG} || { echo "${fhem_CONFIG} not existing";
if [ "$1" = "stop" ]; then exit 0;
else exit 6; fi; }

fhem_LOG=${HOME}/log/fhem-`date +"%Y-%m"`.log

#
case "$1" in
start)
echo "Starting fhem "
$fhem_BIN $fhem_CONFIG
;;
stop)
echo "Shutting down fhem "
$fhem_BIN 7072 shutdown
;;
restart)
$0 stop
$0 start
;;
status)
echo -n "Checking for service fhem "
ps|grep fhem.pl
;;
log)
test -r $fhem_LOG || { echo "$fhem_LOG not existing"; exit 0; }
echo $fhem_LOG
;;
*)
echo "Usage: $0 {start|stop|status|restart|log}"
exit 1
;;
esac
exit 0




dort wüsste ich allerdings nicht welche weile ich anpassen könnte um auf /opt/ActivePerl-5.22 zu verweisen.

Weitere fhem.sh gibt es nicht!

Was tun?

Diggewuff

#29
Ich habe zu dem Thema mal einen eigenen Thread auf gemacht.
https://forum.fhem.de/index.php/topic,53991.msg456139.html#msg456139