bmartin5692 / bumper

A standalone and self-hosted implementation of the central server used by Ecovacs vacuum robots.
GNU General Public License v3.0
286 stars 48 forks source link

MQTT connection failed: #90

Open B0F1B0 opened 4 years ago

B0F1B0 commented 4 years ago

Describe the bug After i start bumper on my Linux Debian X86, i get a few Warnings and an Error regarding MQTT functionality, and neither the vacuum nor my mobile are able to connect. A ping from my Laptop shows that the DNS-Forwarding works as expected.

i also tried to start with/without sudo, i also tried with --listen --announce which was suggested in this isseu #https://github.com/bmartin5692/bumper/issues/64

To Reproduce Steps to reproduce the behavior:

  1. i Downloaded bumper then i run pipenv install to install dependencies --> everything work well

after i start Bumper with sudo pipenv run python -m bumper

  1. See error

sudo pipenv run python -m bumper [2020-01-06 07:32:02,212] :: INFO :: bumper :: Starting Bumper [2020-01-06 07:32:02,248] :: INFO :: mqttserver :: Starting MQTT Server at 127.0.1.1:8883 [2020-01-06 07:32:02,252] :: INFO :: xmppserver :: Starting XMPP Server at 127.0.1.1:5223 [2020-01-06 07:32:02,253] :: WARNING :: hbmqtt.client :: MQTT connection failed: ConnectionRefusedError(111, "Connect call failed ('127.0.1.1', 8883)") [2020-01-06 07:32:02,253] :: WARNING :: hbmqtt.client :: Connection failed: ConnectException(ConnectionRefusedError(111, "Connect call failed ('127.0.1.1', 8883)")) [2020-01-06 07:32:02,254] :: INFO :: hbmqtt.broker :: Listener 'tls1' bind to 127.0.1.1:8883 (max_connections=-1) [2020-01-06 07:32:03,267] :: INFO :: hbmqtt.broker :: Listener 'tls1': 1 connections acquired [2020-01-06 07:32:03,267] :: INFO :: hbmqtt.broker :: Connection from 127.0.0.1:37232 on listener 'tls1' [2020-01-06 07:32:03,268] :: INFO :: mqttserver :: Bumper Authentication Success - Helperbot: helperbot@bumper/helperbot

Desktop (please complete the following information):

Vacuum (please complete the following information):

DEBUG

sudo pipenv run python -m bumper --debug [2020-01-06 07:49:16,231] :: INFO :: bumper :: init :: start :: 194 :: Starting Bumper [2020-01-06 07:49:16,233] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugins :: 61 :: Loading plugins for namespace hbmqtt.broker.plugins [2020-01-06 07:49:16,233] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 69 :: Loading plugin bumper = bumper.mqttserver:BumperMQTTServer_Plugin [2020-01-06 07:49:16,233] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 71 :: Initializing plugin bumper = bumper.mqttserver:BumperMQTTServer_Plugin [2020-01-06 07:49:16,233] :: DEBUG :: hbmqtt.broker.plugins.bumper :: mqttserver :: _read_password_file :: 318 :: Reading user database from /home/b0f1b0/Downloads/git/bumper/data/passwd [2020-01-06 07:49:16,233] :: DEBUG :: hbmqtt.broker.plugins.bumper :: mqttserver :: _read_password_file :: 326 :: 0 user(s) read from file /home/b0f1b0/Downloads/git/bumper/data/passwd [2020-01-06 07:49:16,234] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugins :: 65 :: Plugin bumper ready [2020-01-06 07:49:16,238] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 69 :: Loading plugin auth_anonymous = hbmqtt.plugins.authentication:AnonymousAuthPlugin [2020-01-06 07:49:16,269] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 71 :: Initializing plugin auth_anonymous = hbmqtt.plugins.authentication:AnonymousAuthPlugin [2020-01-06 07:49:16,269] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugins :: 65 :: Plugin auth_anonymous ready [2020-01-06 07:49:16,270] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 69 :: Loading plugin auth_file = hbmqtt.plugins.authentication:FileAuthPlugin [2020-01-06 07:49:16,270] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 71 :: Initializing plugin auth_file = hbmqtt.plugins.authentication:FileAuthPlugin [2020-01-06 07:49:16,271] :: DEBUG :: hbmqtt.broker.plugins.auth_file :: authentication :: _read_password_file :: 63 :: Reading user database from /home/b0f1b0/Downloads/git/bumper/data/passwd [2020-01-06 07:49:16,271] :: DEBUG :: hbmqtt.broker.plugins.auth_file :: authentication :: _read_password_file :: 71 :: 0 user(s) read from file /home/b0f1b0/Downloads/git/bumper/data/passwd [2020-01-06 07:49:16,271] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugins :: 65 :: Plugin auth_file ready [2020-01-06 07:49:16,271] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 69 :: Loading plugin broker_sys = hbmqtt.plugins.sys.broker:BrokerSysPlugin [2020-01-06 07:49:16,273] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 71 :: Initializing plugin broker_sys = hbmqtt.plugins.sys.broker:BrokerSysPlugin [2020-01-06 07:49:16,273] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugins :: 65 :: Plugin broker_sys ready [2020-01-06 07:49:16,273] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 69 :: Loading plugin packet_logger_plugin = hbmqtt.plugins.logging:PacketLoggerPlugin [2020-01-06 07:49:16,274] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 71 :: Initializing plugin packet_logger_plugin = hbmqtt.plugins.logging:PacketLoggerPlugin [2020-01-06 07:49:16,275] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugins :: 65 :: Plugin packet_logger_plugin ready [2020-01-06 07:49:16,275] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 69 :: Loading plugin topic_taboo = hbmqtt.plugins.topic_checking:TopicTabooPlugin [2020-01-06 07:49:16,275] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugin :: 71 :: Initializing plugin topic_taboo = hbmqtt.plugins.topic_checking:TopicTabooPlugin [2020-01-06 07:49:16,276] :: DEBUG :: hbmqtt.broker.plugins :: manager :: _load_plugins :: 65 :: Plugin topic_taboo ready [2020-01-06 07:49:16,282] :: INFO :: mqttserver :: mqttserver :: broker_coro :: 152 :: Starting MQTT Server at 127.0.1.1:8883 [2020-01-06 07:49:16,283] :: DEBUG :: hbmqtt.broker :: broker :: start :: 218 :: Broker starting [2020-01-06 07:49:16,285] :: DEBUG :: hbmqtt.broker :: broker :: start :: 231 :: Listener configuration 'default' is not bound [2020-01-06 07:49:16,290] :: DEBUG :: hbmqtt.client.plugins :: manager :: _load_plugins :: 61 :: Loading plugins for namespace hbmqtt.client.plugins [2020-01-06 07:49:16,290] :: DEBUG :: hbmqtt.client.plugins :: manager :: _load_plugin :: 69 :: Loading plugin packet_logger_plugin = hbmqtt.plugins.logging:PacketLoggerPlugin [2020-01-06 07:49:16,291] :: DEBUG :: hbmqtt.client.plugins :: manager :: _load_plugin :: 71 :: Initializing plugin packet_logger_plugin = hbmqtt.plugins.logging:PacketLoggerPlugin [2020-01-06 07:49:16,292] :: DEBUG :: hbmqtt.client.plugins :: manager :: _load_plugins :: 65 :: Plugin packet_logger_plugin ready [2020-01-06 07:49:16,292] :: DEBUG :: hbmqtt.client :: client :: connect :: 140 :: Connect to: mqtts://127.0.1.1:8883/ [2020-01-06 07:49:16,298] :: INFO :: xmppserver :: xmppserver :: start_async_server :: 30 :: Starting XMPP Server at 127.0.1.1:5223 [2020-01-06 07:49:16,300] :: WARNING :: hbmqtt.client :: client :: _connect_coro :: 426 :: MQTT connection failed: ConnectionRefusedError(111, "Connect call failed ('127.0.1.1', 8883)") [2020-01-06 07:49:16,300] :: WARNING :: hbmqtt.client :: client :: connect :: 145 :: Connection failed: ConnectException(ConnectionRefusedError(111, "Connect call failed ('127.0.1.1', 8883)")) [2020-01-06 07:49:16,301] :: DEBUG :: hbmqtt.client :: client :: reconnect :: 193 :: Reconnecting with session parameters: Session(clientId=helperbot@bumper/helperbot, state=disconnected) [2020-01-06 07:49:16,301] :: INFO :: hbmqtt.broker :: broker :: start :: 285 :: Listener 'tls1' bind to 127.0.1.1:8883 (max_connections=-1) [2020-01-06 07:49:16,302] :: DEBUG :: hbmqtt.broker :: broker :: start :: 293 :: Broker started [2020-01-06 07:49:16,302] :: DEBUG :: hbmqtt.broker :: broker :: retain_message :: 602 :: Retaining message on topic $SYS/broker/version [2020-01-06 07:49:16,303] :: DEBUG :: hbmqtt.broker.plugins.broker_sys :: broker :: on_broker_post_start :: 75 :: $SYS disabled [2020-01-06 07:49:17,302] :: DEBUG :: hbmqtt.client :: client :: reconnect :: 200 :: Reconnect attempt 1 ... [2020-01-06 07:49:17,327] :: DEBUG :: hbmqtt.client.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_sent :: 44 :: helperbot@bumper/helperbot -out-> ConnectPacket(ts=2020-01-06 07:49:17.322015, fixed=MQTTFixedHeader(length=38, flags=0x0), variable=ConnectVariableHeader(proto_name=MQTT, proto_level=4, flags=0x2, keepalive=9), payload=ConnectVariableHeader(client_id=helperbot@bumper/helperbot, will_topic=None, will_message=None, username=None, password=None)) [2020-01-06 07:49:17,327] :: INFO :: hbmqtt.broker :: broker :: acquire_connection :: 90 :: Listener 'tls1': 1 connections acquired [2020-01-06 07:49:17,327] :: INFO :: hbmqtt.broker :: broker :: client_connected :: 354 :: Connection from 127.0.0.1:37420 on listener 'tls1' [2020-01-06 07:49:17,330] :: DEBUG :: hbmqtt.broker :: broker :: delete_session :: 783 :: Delete session : session helperbot@bumper/helperbot doesn't exist [2020-01-06 07:49:17,330] :: DEBUG :: hbmqtt.broker :: broker :: client_connected :: 389 :: Keep-alive timeout=11 [2020-01-06 07:49:17,332] :: DEBUG :: hbmqtt.broker.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_received :: 36 :: <-in-- ConnectPacket(ts=2020-01-06 07:49:17.328265, fixed=MQTTFixedHeader(length=38, flags=0x0), variable=ConnectVariableHeader(proto_name=MQTT, proto_level=4, flags=0x2, keepalive=9), payload=ConnectVariableHeader(client_id=helperbot@bumper/helperbot, will_topic=None, will_message=None, username=None, password=None)) [2020-01-06 07:49:17,333] :: INFO :: mqttserver :: mqttserver :: authenticate :: 267 :: Bumper Authentication Success - Helperbot: helperbot@bumper/helperbot [2020-01-06 07:49:17,333] :: DEBUG :: hbmqtt.broker :: broker :: authenticate :: 560 :: 'bumper' plugin result: True [2020-01-06 07:49:17,335] :: DEBUG :: hbmqtt.broker :: broker :: client_connected :: 413 :: helperbot@bumper/helperbot Start messages handling [2020-01-06 07:49:17,336] :: DEBUG :: hbmqtt.broker.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_sent :: 44 :: helperbot@bumper/helperbot -out-> ConnackPacket(ts=2020-01-06 07:49:17.334237, fixed=MQTTFixedHeader(length=2, flags=0x0), variable=ConnackVariableHeader(session_parent=0x0, return_code=0x0), payload=None) [2020-01-06 07:49:17,337] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: _reader_loop :: 357 :: helperbot@bumper/helperbot Starting reader coro [2020-01-06 07:49:17,339] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: start :: 111 :: Handler tasks started [2020-01-06 07:49:17,340] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: _retry_deliveries :: 150 :: Begin messages delivery retries [2020-01-06 07:49:17,340] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: _retry_deliveries :: 158 :: End messages delivery retries [2020-01-06 07:49:17,340] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: start :: 113 :: Handler ready [2020-01-06 07:49:17,340] :: DEBUG :: hbmqtt.broker :: broker :: client_connected :: 415 :: Retained messages queue size: 0 [2020-01-06 07:49:17,340] :: DEBUG :: hbmqtt.broker :: broker :: publish_session_retained_messages :: 741 :: Publishing 0 messages retained for session (client id=helperbot@bumper/helperbot) [2020-01-06 07:49:17,344] :: DEBUG :: hbmqtt.client.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_received :: 34 :: helperbot@bumper/helperbot <-in-- ConnackPacket(ts=2020-01-06 07:49:17.339020, fixed=MQTTFixedHeader(length=2, flags=0x0), variable=ConnackVariableHeader(session_parent=0x0, return_code=0x0), payload=None) [2020-01-06 07:49:17,344] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: _reader_loop :: 357 :: helperbot@bumper/helperbot Starting reader coro [2020-01-06 07:49:17,345] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: mqtt_deliver_next_message :: 459 :: 0 message(s) available for delivery [2020-01-06 07:49:17,346] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: start :: 111 :: Handler tasks started [2020-01-06 07:49:17,346] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: _retry_deliveries :: 150 :: Begin messages delivery retries [2020-01-06 07:49:17,346] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: _retry_deliveries :: 158 :: End messages delivery retries [2020-01-06 07:49:17,346] :: DEBUG :: hbmqtt.mqtt.protocol.handler :: handler :: start :: 113 :: Handler ready [2020-01-06 07:49:17,346] :: DEBUG :: hbmqtt.client :: client :: _connect_coro :: 415 :: connected to 127.0.1.1:8883 [2020-01-06 07:49:17,347] :: DEBUG :: hbmqtt.client :: client :: handle_connection_close :: 440 :: Watch broker disconnection [2020-01-06 07:49:17,347] :: DEBUG :: hbmqtt.client.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_sent :: 44 :: helperbot@bumper/helperbot -out-> SubscribePacket(ts=2020-01-06 07:49:17.347125, fixed=MQTTFixedHeader(length=77, flags=0x2), variable=PacketIdVariableHeader(packet_id=1), payload=SubscribePayload(topics=[('iot/p2p/+/+/+/+/helperbot/bumper/helperbot/+/+/+', 0), ('iot/p2p/+', 0), ('iot/atr/+', 0)])) [2020-01-06 07:49:17,349] :: DEBUG :: hbmqtt.broker.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_received :: 34 :: helperbot@bumper/helperbot <-in-- SubscribePacket(ts=2020-01-06 07:49:17.348581, fixed=MQTTFixedHeader(length=77, flags=0x2), variable=PacketIdVariableHeader(packet_id=1), payload=SubscribePayload(topics=[('iot/p2p/+/+/+/+/helperbot/bumper/helperbot/+/+/+', 0), ('iot/p2p/+', 0), ('iot/atr/+', 0)])) [2020-01-06 07:49:17,350] :: DEBUG :: hbmqtt.broker :: broker :: client_connected :: 465 :: helperbot@bumper/helperbot handling subscription [2020-01-06 07:49:17,352] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'bumper' plugin result: None [2020-01-06 07:49:17,352] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'auth_anonymous' plugin result: None [2020-01-06 07:49:17,352] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'auth_file' plugin result: None [2020-01-06 07:49:17,352] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'broker_sys' plugin result: None [2020-01-06 07:49:17,352] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'packet_logger_plugin' plugin result: None [2020-01-06 07:49:17,352] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'topic_taboo' plugin result: True [2020-01-06 07:49:17,354] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'bumper' plugin result: None [2020-01-06 07:49:17,354] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'auth_anonymous' plugin result: None [2020-01-06 07:49:17,354] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'auth_file' plugin result: None [2020-01-06 07:49:17,355] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'broker_sys' plugin result: None [2020-01-06 07:49:17,355] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'packet_logger_plugin' plugin result: None [2020-01-06 07:49:17,355] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'topic_taboo' plugin result: True [2020-01-06 07:49:17,356] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'bumper' plugin result: None [2020-01-06 07:49:17,357] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'auth_anonymous' plugin result: None [2020-01-06 07:49:17,357] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'auth_file' plugin result: None [2020-01-06 07:49:17,357] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'broker_sys' plugin result: None [2020-01-06 07:49:17,357] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'packet_logger_plugin' plugin result: None [2020-01-06 07:49:17,357] :: DEBUG :: hbmqtt.broker :: broker :: topic_filtering :: 595 :: 'topic_taboo' plugin result: True [2020-01-06 07:49:17,358] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 756 :: Begin broadcasting messages retained due to subscription on 'iot/p2p/+/+/+/+/helperbot/bumper/helperbot/+/+/+' from (client id=helperbot@bumper/helperbot) [2020-01-06 07:49:17,358] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 760 :: matching : $SYS/broker/version iot/p2p/+/+/+/+/helperbot/bumper/helperbot/+/+/+ [2020-01-06 07:49:17,359] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 770 :: End broadcasting messages retained due to subscription on 'iot/p2p/+/+/+/+/helperbot/bumper/helperbot/+/+/+' from (client id=helperbot@bumper/helperbot) [2020-01-06 07:49:17,359] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 756 :: Begin broadcasting messages retained due to subscription on 'iot/p2p/+' from (client id=helperbot@bumper/helperbot) [2020-01-06 07:49:17,359] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 760 :: matching : $SYS/broker/version iot/p2p/+ [2020-01-06 07:49:17,359] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 770 :: End broadcasting messages retained due to subscription on 'iot/p2p/+' from (client id=helperbot@bumper/helperbot) [2020-01-06 07:49:17,359] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 756 :: Begin broadcasting messages retained due to subscription on 'iot/atr/+' from (client id=helperbot@bumper/helperbot) [2020-01-06 07:49:17,359] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 760 :: matching : $SYS/broker/version iot/atr/+ [2020-01-06 07:49:17,359] :: DEBUG :: hbmqtt.broker :: broker :: publish_retained_messages_for_subscription :: 770 :: End broadcasting messages retained due to subscription on 'iot/atr/+' from (client id=helperbot@bumper/helperbot) [2020-01-06 07:49:17,360] :: DEBUG :: hbmqtt.broker :: broker :: client_connected :: 481 :: {'iot/p2p/+/+/+/+/helperbot/bumper/helperbot/+/+/+': [(Session(clientId=helperbot@bumper/helperbot, state=connected), 0)], 'iot/p2p/+': [(Session(clientId=helperbot@bumper/helperbot, state=connected), 0)], 'iot/atr/+': [(Session(clientId=helperbot@bumper/helperbot, state=connected), 0)]} [2020-01-06 07:49:17,360] :: DEBUG :: hbmqtt.broker.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_sent :: 44 :: helperbot@bumper/helperbot -out-> SubackPacket(ts=2020-01-06 07:49:17.357647, fixed=MQTTFixedHeader(length=5, flags=0x0), variable=PacketIdVariableHeader(packet_id=1), payload=SubackPayload(return_codes=[0, 0, 0])) [2020-01-06 07:49:17,362] :: DEBUG :: hbmqtt.client.plugins.packet_logger_plugin :: logging :: on_mqtt_packet_received :: 34 :: helperbot@bumper/helperbot <-in-- SubackPacket(ts=2020-01-06 07:49:17.361396, fixed=MQTTFixedHeader(length=5, flags=0x0), variable=PacketIdVariableHeader(packet_id=1), payload=SubackPayload(return_codes=[0, 0, 0])) [2020-01-06 07:49:17,403] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (portal_api_appsvr) [2020-01-06 07:49:17,404] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (portal_api_dimr) [2020-01-06 07:49:17,404] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (portal_api_iot) [2020-01-06 07:49:17,404] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (portal_api_lg) [2020-01-06 07:49:17,404] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (portal_api_neng) [2020-01-06 07:49:17,404] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (portal_api_pim) [2020-01-06 07:49:17,405] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (portal_api_users) [2020-01-06 07:49:17,405] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v1_global_auth) [2020-01-06 07:49:17,405] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v1_private_ad) [2020-01-06 07:49:17,409] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v1_private_campaign) [2020-01-06 07:49:17,411] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v1_private_common) [2020-01-06 07:49:17,414] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v1_private_message) [2020-01-06 07:49:17,416] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v1_private_shop) [2020-01-06 07:49:17,417] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v1_private_user) [2020-01-06 07:49:17,421] :: DEBUG :: root :: confserver :: confserver_app :: 94 :: Adding confserver sub_api (v2_privateuser) <PlainResource 'base' > <DynamicResource 'remove-bot' /bot/remove/{did}> <DynamicResource 'remove-client' /client/remove/{resource}> <DynamicResource 'restart-service' /restart{service}> <PlainResource /lookup.do> <PrefixedSubAppResource /v1 -> <Application 0x7fc8d0dbeb00>> <PrefixedSubAppResource /v2 -> <Application 0x7fc8d0da9630>> <PrefixedSubAppResource /api -> <Application 0x7fc8d0da99b0>>

bmartin5692 commented 4 years ago

It definitely looks like you need to use --listen and --announce. Set these to the IP of the server you are using. From the portion of logs provided it looks like it starts on 127.0.0.1, which is why the bot/app won't work.

Grab the latest from master (from the logs I can tell it isn't the latest) and then try using the above (listen/announce) with debug. If it doesn't work send in the full logs as a zip if you can.

B0F1B0 commented 4 years ago

here my steps, but also the same error: -->this time my android app connected to the server -->but there is a "error" in the log output

<iq type="error" id="E8ImF-13"><error type="cancel" code="501"><feature-not-implemented xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"/></error></iq>

this is what i did:

git clone https://github.com/bmartin5692/bumper.git cd bumper sudo pipenv install

Installing dependencies from Pipfile.lock (2ba937)…

sudo pipenv run python -m bumper --listen 192.168.100.222 --announce 192.168.100.222

Creating certificates -------- Create_Certs -------- -------- Starting Certificate Creation -------- Options: Output Directory: /home/b0f1b0/Downloads/git/bumper/certs Input SAN List: /home/b0f1b0/Downloads/git/bumper/create_certs/Bumper_SAN.txt -------- Creating CA Cert -------- 2020/01/06 17:46:56 ca.crt created at /home/b0f1b0/Downloads/git/bumper/certs/ca.crt 2020/01/06 17:46:56 ca.key created at /home/b0f1b0/Downloads/git/bumper/certs/ca.key -------- Creating Server Cert -------- 2020/01/06 17:46:56 bumper.crt created at /home/b0f1b0/Downloads/git/bumper/certs/bumper.crt 2020/01/06 17:46:56 bumper.key created at /home/b0f1b0/Downloads/git/bumper/certs/bumper.key -------- Certificate Creation Complete -------- Certificates created

[2020-01-06 18:11:21,694] :: INFO :: mqttserver :: Starting MQTT Server at 192.168.100.222:8883 [2020-01-06 18:11:21,699] :: INFO :: xmppserver :: Starting XMPP Server at 192.168.100.222:5223 [2020-01-06 18:11:21,700] :: WARNING :: hbmqtt.client :: MQTT connection failed: ConnectionRefusedError(111, "Connect call failed ('192.168.100.222', 8883)") [2020-01-06 18:11:21,700] :: WARNING :: hbmqtt.client :: Connection failed: ConnectException(ConnectionRefusedError(111, "Connect call failed ('192.168.100.222', 8883)")) [2020-01-06 18:11:21,701] :: INFO :: hbmqtt.broker :: Listener 'tls1' bind to 192.168.100.222:8883 (max_connections=-1) [2020-01-06 18:11:22,714] :: INFO :: hbmqtt.broker :: Listener 'tls1': 1 connections acquired [2020-01-06 18:11:22,714] :: INFO :: hbmqtt.broker :: Connection from 192.168.100.222:39426 on listener 'tls1' [2020-01-06 18:11:22,715] :: INFO :: mqttserver :: Bumper Authentication Success - Helperbot: helperbot@bumper/helperbot [2020-01-06 18:11:36,724] :: INFO :: xmppserver :: client authenticated XXXXREMOVEDXXXXX

could u pls tell me how can i send u the log as zip? is there some information in the log which should i "remove"?

my ecovacs app sends some "information" to the bumper but my robot will not connect (is shown offline in the app)

bmartin5692 commented 4 years ago

I don't really see anything in the sample log above that indicates anything wrong. Make sure you run with --debug so we get full debug messages. After starting bumper ensure you turn off the bot completely then turn it back on so it connects via the DNS you have in place and not a cache of the official servers IPs. You can also check the status page for details (http://192.168.100.222:8007) of connections once started.

There isn't really anything in the logs to be removed, perhaps easiest would be zipping (the entire logs folders) then sending direct to me via gitter (https://gitter.im/ecovacs-bumper) .

aharter commented 4 years ago

Creating certificates -------- Create_Certs -------- -------- Starting Certificate Creation -------- Options: Output Directory: /home/b0f1b0/Downloads/git/bumper/certs Input SAN List: /home/b0f1b0/Downloads/git/bumper/create_certs/Bumper_SAN.txt -------- Creating CA Cert -------- 2020/01/06 17:46:56 ca.crt created at /home/b0f1b0/Downloads/git/bumper/certs/ca.crt 2020/01/06 17:46:56 ca.key created at /home/b0f1b0/Downloads/git/bumper/certs/ca.key -------- Creating Server Cert -------- 2020/01/06 17:46:56 bumper.crt created at /home/b0f1b0/Downloads/git/bumper/certs/bumper.crt 2020/01/06 17:46:56 bumper.key created at /home/b0f1b0/Downloads/git/bumper/certs/bumper.key -------- Certificate Creation Complete -------- Certificates created

This part of the (second) log mentions creation new certificates. This could indicate issues with your overall certificate setup (e.g. your phone has the wrong root certificate, thus refusing to connect)

B0F1B0 commented 4 years ago

@aharter

thanks for your help, but i know if i see "creating certificates" i have to copy the new cert to my phone.