Skip to content

Startup fails if nodes.json cannot be fetched #15

Description

@1977er

barfs traceback and dies.

Dez 30 23:06:14 harvester systemd[1]: Started The KeepItUp Worker pings and sends notification mails.
Dez 30 23:06:16 harvester python[585]: ping_worker.py, 451 nodes loaded.
Dez 30 23:06:16 harvester python[585]: Traceback (most recent call last):
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/connection.py", line 170, in _new_conn
Dez 30 23:06:16 harvester python[585]:     (self._dns_host, self.port), self.timeout, **extra_kw
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/util/connection.py", line 96, in create_connection
Dez 30 23:06:16 harvester python[585]:     raise err
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/util/connection.py", line 86, in create_connection
Dez 30 23:06:16 harvester python[585]:     sock.connect(sa)
Dez 30 23:06:16 harvester python[585]: ConnectionRefusedError: [Errno 111] Connection refused
Dez 30 23:06:16 harvester python[585]: During handling of the above exception, another exception occurred:
Dez 30 23:06:16 harvester python[585]: Traceback (most recent call last):
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/connectionpool.py", line 706, in urlopen
Dez 30 23:06:16 harvester python[585]:     chunked=chunked,
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/connectionpool.py", line 382, in _make_request
Dez 30 23:06:16 harvester python[585]:     self._validate_conn(conn)
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn
Dez 30 23:06:16 harvester python[585]:     conn.connect()
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/connection.py", line 353, in connect
Dez 30 23:06:16 harvester python[585]:     conn = self._new_conn()
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/connection.py", line 182, in _new_conn
Dez 30 23:06:16 harvester python[585]:     self, "Failed to establish a new connection: %s" % e
Dez 30 23:06:16 harvester python[585]: urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x7f73b3c938d0>: Failed to establish a new connection:
Dez 30 23:06:16 harvester python[585]: During handling of the above exception, another exception occurred:
Dez 30 23:06:16 harvester python[585]: Traceback (most recent call last):
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/requests/adapters.py", line 449, in send
Dez 30 23:06:16 harvester python[585]:     timeout=timeout
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/connectionpool.py", line 756, in urlopen
Dez 30 23:06:16 harvester python[585]:     method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2]
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/urllib3/util/retry.py", line 573, in increment
Dez 30 23:06:16 harvester python[585]:     raise MaxRetryError(_pool, url, error or ResponseError(cause))
Dez 30 23:06:16 harvester python[585]: urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='harvester.ffh.zone', port=443): Max retries exceeded with url: /api/nodes.json
Dez 30 23:06:16 harvester python[585]: During handling of the above exception, another exception occurred:
Dez 30 23:06:16 harvester python[585]: Traceback (most recent call last):
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/ping_worker.py", line 19, in <module>
Dez 30 23:06:16 harvester python[585]:     nodes_json_cache.update()
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/main.py", line 144, in update
Dez 30 23:06:16 harvester python[585]:     res = requests.get(NODES_JSON_URL)
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/requests/api.py", line 76, in get
Dez 30 23:06:16 harvester python[585]:     return request('get', url, params=params, **kwargs)
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/requests/api.py", line 61, in request
Dez 30 23:06:16 harvester python[585]:     return session.request(method=method, url=url, **kwargs)
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/requests/sessions.py", line 542, in request
Dez 30 23:06:16 harvester python[585]:     resp = self.send(prep, **send_kwargs)
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/requests/sessions.py", line 655, in send
Dez 30 23:06:16 harvester python[585]:     r = adapter.send(request, **kwargs)
Dez 30 23:06:16 harvester python[585]:   File "/opt/keepitup/venv/lib/python3.7/site-packages/requests/adapters.py", line 516, in send
Dez 30 23:06:16 harvester python[585]:     raise ConnectionError(e, request=request)
Dez 30 23:06:16 harvester python[585]: requests.exceptions.ConnectionError: HTTPSConnectionPool(host='harvester.ffh.zone', port=443): Max retries exceeded with url: /api/nodes.js

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions