Bonjour,
Je migre ma question sur le nouveau forum
Suite au tuto Installation sécurisée de Jeedom avec Docker | by Renaud Cerrato | Medium, j’ai bien tenté de le suivre, mais comme dans pas mal de sujet, j’obtiens un message d’erreur lorsque j’essaye d’activer le daemon rfxcom (Timeout waiting status).
Voici ma config, les tests effectués.
1/ Utilisation d’un portable sous ubuntu 18.04
2/ MAJ de mon rfxtrx433e avec le dernier firmware 1025
3/ Connexion du rfxcom
4/ Lancement des containers dockers (mariadb / jeedom) - en mode host ou bridge (j’obtiens le même résultat) - installation from scratch à chaque fois en supprimant les volumes
5/ Configuration du réseau jeedom comme indiqué dans le tuto
6/ Installation du plugin jeedom (activation, installation des dépendances, acttivation du daemon)
Ces différents tests ont été effectués avec 3 câbles USB différents. A chaque fois le même résultat. Lors du lancement daemon, il y a le voyant rouge du rfxcom qui s’allume, puis s’éteint après quelques dizaines de secondes.
Lorsque je me mets en mode host et que je lance la commande netstat -anp | grep 55000, lors du lancement du daemon, je vois bien apparaître le port et je peux même faire un telnet dessus. Mais rien à faire, j’ai toujours le même résultat.
Merci d’avance de votre aide!
[2019-12-01 17:16:46][INFO] : Lancement démon rfxcomd : /usr/bin/python /var/www/html/plugins/rfxcom/resources/rfxcomd/rfxcomd.py --device /dev/ttyUSB0 --loglevel debug --socketport 55000 --serialrate 38400 --protocol 12,13,18,20,21,22,23 --callback http://127.0.0.1:80/plugins/rfxcom/core/php/jeeRfxcom.php --apikey xxx --cycle 0.3 --pid /tmp/jeedom/rfxcom/deamon.pid
[2019-12-01 16:16:46][INFO] : Start rfxcomd
[2019-12-01 16:16:46][INFO] : Log level : debug
[2019-12-01 16:16:46][INFO] : Socket port : 55000
[2019-12-01 16:16:46][INFO] : Socket host : 127.0.0.1
[2019-12-01 16:16:46][INFO] : PID file : /tmp/jeedom/rfxcom/deamon.pid
[2019-12-01 16:16:46][INFO] : Device : /dev/ttyUSB0
[2019-12-01 16:16:46][INFO] : Apikey : xxx
[2019-12-01 16:16:46][INFO] : Callback : http://127.0.0.1:80/plugins/rfxcom/core/php/jeeRfxcom.php
[2019-12-01 16:16:46][INFO] : Cycle : 0.3
[2019-12-01 16:16:46][INFO] : Serial rate : 38400
[2019-12-01 16:16:46][INFO] : Serial timeout : 9
[2019-12-01 16:16:46][INFO] : Protocol : 12,13,18,20,21,22,23
[2019-12-01 16:16:46][INFO] : Find device : /dev/ttyUSB0
[2019-12-01 16:16:46][DEBUG] : Writing PID 12807 to /tmp/jeedom/rfxcom/deamon.pid
[2019-12-01 16:16:46][DEBUG] : Init request module v2.12.4
[2019-12-01 16:16:46][DEBUG] : Starting new HTTP connection (1): 127.0.0.1
[2019-12-01 16:16:46][DEBUG] : http://127.0.0.1:80 "GET /plugins/rfxcom/core/php/jeeRfxcom.php?apikey=xxx HTTP/1.1" 200 0
[2019-12-01 16:16:46][DEBUG] : Init serial module v3.2.1
[2019-12-01 16:16:46][DEBUG] : Start listening...
[2019-12-01 16:16:46][DEBUG] : Socket interface started
[2019-12-01 16:16:46][DEBUG] : LoopNetServer Thread started
[2019-12-01 16:16:46][DEBUG] : Listening on: [127.0.0.1:55000]
[2019-12-01 16:16:46][DEBUG] : Open serial port on device: /dev/ttyUSB0, rate 38400, timeout : 9
[2019-12-01 16:16:46][DEBUG] : Open Serialport
[2019-12-01 16:16:46][DEBUG] : flushOutput serial port
[2019-12-01 16:16:46][DEBUG] : flushInput serial port
[2019-12-01 16:16:46][DEBUG] : flushOutput serial port
[2019-12-01 16:16:46][DEBUG] : flushInput serial port
[2019-12-01 16:16:46][DEBUG] : Read Socket Thread Launched
[2019-12-01 16:16:46][DEBUG] : Read Device Thread Launched
[2019-12-01 16:16:47][DEBUG] : Send rfxcomd_reset
[2019-12-01 16:16:47][DEBUG] : Write data to serial port : 0D 00 00 00 00 00 00 00 00 00 00 00 00 00
[2019-12-01 16:16:47][DEBUG] : Sleep 1 sec
[2019-12-01 16:16:48][DEBUG] : flushInput serial port
[2019-12-01 16:16:48][DEBUG] : Send get status test
[2019-12-01 16:16:48][DEBUG] : Write data to serial port : 0D 00 00 01 02 00 00 00 00 00 00 00 00 00
[2019-12-01 17:16:49][INFO] : Démon RFXcom lancé
[2019-12-01 16:17:15][ERROR] : Timeout waiting status
[2019-12-01 16:17:15][DEBUG] : Shutdown
[2019-12-01 16:17:15][DEBUG] : Removing PID file /tmp/jeedom/rfxcom/deamon.pid
[2019-12-01 16:17:16][DEBUG] : LoopNetServer Thread stopped
[2019-12-01 16:17:16][DEBUG] : Close serial port
[2019-12-01 16:17:16][DEBUG] : Serial port closed
[2019-12-01 16:17:16][DEBUG] : Exit 0
Voici pour les commandes
$ ls -l /dev/serial/by-id | grep RFX
lrwxrwxrwx 1 root root 13 déc. 1 17:16 usb-RFXCOM_RFXtrx433_A1Y06XTB-if00-port0 -> ../../ttyUSB0
$ docker run --name jeedom-mysql -v /opt/jeedom/mysql:/var/lib/mysql -e MYSQL_ROOT_PASSWORD=jeedom -e MYSQL_USER=jeedom -e MYSQL_PASSWORD=jeedom --detach --publish 3306:3306 --restart always mariadb:10.1
$ docker create --net bridge --link jeedom-mysql --name jeedom-server -v /opt/jeedom/html:/var/www/html -e ROOT_PASSWORD=jeedom --device /dev/serial/by-id/usb-RFXCOM_RFXtrx433_A1Y06XTB-if00-port0:/dev/ttyUSB0 --publish 9080:80 --publish 9022:22 --restart always jeedom/jeedom:master
$ docker start jeedom-server && docker logs -f jeedom-server