cluster creation failure due to heat-agent failing to contact keystone OR heat
The heat-agent completes the deployment and the tries to notify heat.
The error in the heat-agent logs is:
Exception in thread Thread-2:
Traceback (most recent call last):
File "/usr/lib64/python3.8/threading.py", line 932, in _bootstrap_inner
self.run()
File "/usr/lib64/python3.8/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/var/lib/heat-config/hooks/script", line 83, in consumer
fd.write(line)
ValueError: I/O operation on closed file.
[2022-08-23 08:11:41,236] (heat-config) [DEBUG] Running heat-config-notify /var/lib/heat-config/deployed/41d53429-3119-49c9-9063-0aa668cbb167.json < /var/lib/heat-config/deployed/41d53429-3119-49c9-9063-0aa668cbb167.notify.json
[2022-08-23 08:11:42,675] (heat-config) [INFO] b''
[2022-08-23 08:11:42,677] (heat-config) [ERROR] Error running heat-config-notify. [1]
[2022-08-23 08:11:42,677] (heat-config) [ERROR] b'Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/urllib3/response.py", line 437, in _error_catcher
yield
File "/usr/local/lib/python3.8/site-packages/urllib3/response.py", line 519, in read
data = self._fp.read(amt) if not fp_closed else b""
File "/usr/lib64/python3.8/http/client.py", line 454, in read
n = self.readinto(b)
File "/usr/lib64/python3.8/http/client.py", line 498, in readinto
n = self.fp.readinto(b)
File "/usr/lib64/python3.8/socket.py", line 669, in readinto
return self._sock.recv_into(b)
File "/usr/lib64/python3.8/ssl.py", line 1241, in recv_into
return self.read(nbytes, buffer)
File "/usr/lib64/python3.8/ssl.py", line 1099, in read
return self._sslobj.read(len, buffer)
ConnectionResetError: [Errno 104] Connection reset by peer
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/requests/models.py", line 751, in generate
for chunk in self.raw.stream(chunk_size, decode_content=True):
File "/usr/local/lib/python3.8/site-packages/urllib3/response.py", line 576, in stream
data = self.read(amt=amt, decode_content=decode_content)
File "/usr/local/lib/python3.8/site-packages/urllib3/response.py", line 541, in read
raise IncompleteRead(self._fp_bytes_read, self.length_remaining)
File "/usr/lib64/python3.8/contextlib.py", line 131, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/local/lib/python3.8/site-packages/urllib3/response.py", line 455, in _error_catcher
raise ProtocolError("Connection broken: %r" % e, e)
urllib3.exceptions.ProtocolError: ("Connection broken: ConnectionResetError(104, \'Connection reset by peer\')", ConnectionResetError(104, \'Connection reset by peer\'))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/keystoneclient/v3/client.py", line 343, in get_raw_token_from_identity_service
return plugin.get_auth_ref(self.session)
File "/usr/local/lib/python3.8/site-packages/keystoneclient/auth/identity/v3/base.py", line 188, in get_auth_ref
resp = session.post(token_url, json=body, headers=headers,
File "/usr/local/lib/python3.8/site-packages/keystoneclient/session.py", line 543, in post
return self.request(url, \'POST\', **kwargs)
File "/usr/local/lib/python3.8/site-packages/keystoneclient/session.py", line 428, in request
resp = send(**kwargs)
File "/usr/local/lib/python3.8/site-packages/keystoneclient/session.py", line 462, in _send_request
resp = self.session.request(method, url, **kwargs)
File "/usr/local/lib/python3.8/site-packages/keystoneclient/httpclient.py", line 96, in request
return requests.request(*args, **kwargs)
File "/usr/local/lib/python3.8/site-packages/requests/api.py", line 61, in request
return session.request(method=method, url=url, **kwargs)
File "/usr/local/lib/python3.8/site-packages/requests/sessions.py", line 530, in request
resp = self.send(prep, **send_kwargs)
File "/usr/local/lib/python3.8/site-packages/requests/sessions.py", line 683, in send
r.content
File "/usr/local/lib/python3.8/site-packages/requests/models.py", line 829, in content
self._content = b\'\'.join(self.iter_content(CONTENT_CHUNK_SIZE)) or b\'\'
File "/usr/local/lib/python3.8/site-packages/requests/models.py", line 754, in generate
raise ChunkedEncodingError(e)
requests.exceptions.ChunkedEncodingError: ("Connection broken: ConnectionResetError(104, \'Connection reset by peer\')", ConnectionResetError(104, \'Connection reset by peer\'))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/bin/heat-config-notify", line 165, in <module>
sys.exit(main(sys.argv, sys.stdin))
File "/usr/bin/heat-config-notify", line 144, in main
ks = ksclient.Client(
File "/usr/local/lib/python3.8/site-packages/keystoneclient/v3/client.py", line 267, in __init__
self.authenticate()
File "/usr/local/lib/python3.8/site-packages/keystoneclient/httpclient.py", line 583, in authenticate
resp = self.get_raw_token_from_identity_service(**kwargs)
File "/usr/local/lib/python3.8/site-packages/keystoneclient/v3/client.py", line 352, in get_raw_token_from_identity_service
raise exceptions.AuthorizationFailure(
keystoneauth1.exceptions.auth.AuthorizationFailure: Authorization failed: ("Connection broken: ConnectionResetError(104, \'Connection reset by peer\')", ConnectionResetError(104, \'Connection reset by peer\'))
'
Edited by Spyridon Trigazis