SSLError: SSL validation failed for https:/s3/endpoints/invocations EOF occurred in violation of protocol (_ssl.c:2396) in sagemaker

0

I trained a deep neural network using sagemaker and deployed the endpoint successfully. But, when trying to get the predictions on test data, i am getting "SSLError: SSL validation failed for https://runtime.s3.amazonaws.com/endpoints/[endpointName]/invocations EOF occurred in violation of protocol (_ssl.c:2396)"

i am able to get predictions up to 10 records, afterwards i am getting this error.please help me.

from sagemaker.tensorflow import TensorFlowPredictor
predictor = TensorFlowPredictor(endpoint_name)

# invoke model endpoint to make inference
pred = predictor.predict(input_vals)
    
# store predictions
y_pred.extend([i[0] for i in pred['predictions']])
1 回答
0

Do you have an S3 interface endpoint in your VPC? Traffic to "s3.amazonaws.com" will be requested through the endpoint, but it will reply with the region-specific URL e.g: https://my-bucket.s3.us-west-2.amazonaws.com

The certificate of the server(S3) will be issued to X.s3.amazonaws.com, but the URL is different, since it has the region name included.

This will cause the client to not trust on the site, throwing that error. You can either: try to ignore the SSL check on your system modify the URL with the region-specific one replace the S3 interface endpoint by S3 Gateway endpoint

已回答 1 年前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则