【Function App】记录一次 "OSError: Could not find a suitable TLS CA certificate bundle" 错误

zidea

关注

阅读 31

04-10 21:00

问题描述

运行在Azure中的Function App,最近出现偶发的证书加载错误。

 

错误信息:We get an error in function app. Exception: OSError: Could not find a suitable TLS CA certificate bundle, invalid path: /home/site/wwwroot/.python_packages/lib/site-packages/certifi/cacert.pem
This issue happened by chance. This appears to be a platform issue with Function Apps running on Linux OS via dedicated App Service plan SKUs. Refer to Link: https://learn.microsoft.com/en-us/answers/questions/1192437/azure-function-error-could-not-find-a-suitable-tls

 

想知道是什么情况会导致这个错误呢?

 

问题解答

查看了错误信息中的链接文档,从中其实最关键的一句话就是:

In rare scenarios, this mounting process can be disrupted intermittently by the underlying OS and other components in the platform, which might ultimately result in the error above about missing content/certs, etc.

在极少数情况下,此挂载过程可能会被平台中的底层作系统和其他组件间歇性中断,这最终可能导致上述有关缺少内容/证书等的错误。

但是,在当前遇见的情况中,最后通过查看Function App的CPU和Memory,发现它们的占用率都达到了100%,所以在加载文件的过程中,就非常高概率出现load file failed。导致错误: Could not find a suitable TLS CA certificate bundle, invalid path: /home/site/wwwroot/.python_packages/lib/site-packages/certifi/cacert.pem 错误。

 

当在复杂的环境中面临问题,格物之道需:浊而静之徐清,安以动之徐生。 云中,恰是如此!

精彩评论(0)

0 0 举报