In the event a remote storage session upload fails, Teleport will continue to retry uploading the session recording. In the case of Google Cloud Storage (GCS), an upload failure could be the result of a session having already exist at the remote storage target. This ultimately results in a continuous loop of attempting to upload the session.
What happened:
Teleport is in a continuous upload loop.
What you expected to happen:
In the event that a session object already exists on GCS, we should try to compare a hash of the object to ensure the local object is an exact copy on the remote storage target. If so, the local object may be deleted. If not, perhaps create a UUID conflict path on the remote storage and upload the object there?
How to reproduce it (as minimally and precisely as possible):
Configure a Teleport Cluster w/ GCS for session storage.
Start a session, but do not end the session.
Grab the session ID and create a blank object in your GCS bucket with the same session ID.
Complete the Teleport session.
Monitor the Teleport Auth server logs for the error.
Environment
Teleport version (use teleport version): 4.3.6
Where are you running Teleport? (e.g. AWS, GCP, Dedicated Hardware): GCP
Description
In the event a remote storage session upload fails, Teleport will continue to retry uploading the session recording. In the case of Google Cloud Storage (GCS), an upload failure could be the result of a session having already exist at the remote storage target. This ultimately results in a continuous loop of attempting to upload the session.
What happened:
Teleport is in a continuous upload loop.
What you expected to happen:
In the event that a session object already exists on GCS, we should try to compare a hash of the object to ensure the local object is an exact copy on the remote storage target. If so, the local object may be deleted. If not, perhaps create a UUID conflict path on the remote storage and upload the object there?
How to reproduce it (as minimally and precisely as possible):
Environment
Teleport version (use
teleport version
): 4.3.6Where are you running Teleport? (e.g. AWS, GCP, Dedicated Hardware): GCP
Relevant Debug Logs If Applicable
Here is an example stack trace: