简体   繁体   English

在raspi 3上安装opencv时发生SSLError

[英]SSLError while installing opencv on raspi 3

I was trying to install OpenCV on my raspberry pi 3 and was following the tutorial: https://www.learnopencv.com/install-opencv-4-on-raspberry-pi/ 我试图在树莓派3上安装OpenCV,并遵循了以下教程: https : //www.learnopencv.com/install-opencv-4-on-raspberry-pi/

Everything was going well until the command: 一切正常,直到执行以下命令:

sudo -H pip3 install -U pip numpy

After I executed the above command I got the following error(last part of the error): 执行上述命令后,出现以下错误(错误的最后一部分):

request.exceptions.SSLError: ("bad handshake: Error([('SSL routines', 'tls_process_server_certificate','certificate verify failed')],)",) request.exceptions.SSLError :(“错误的握手:错误([(“ SSL例程”,“ tls_process_server_certificate”,“证书验证失败”)])),),)

I have been searching for a solution for 2-3 days now. 我一直在寻找2-3天的解决方案。 Any help would be very well appreciated. 任何帮助将不胜感激。

Ok, my problem is solved. 好,我的问题解决了。 In my case, my raspberry pi 3's date and time settings were incorrect and therefore SSL certificate error was coming. 就我而言,我的树莓派3的日期和时间设置不正确,因此SSL证书错误即将到来。

I changed the date using the command (Time in 24hr format): 我使用以下命令更改了日期(时间为24小时格式):

sudo date -s "Day Mon date hh:mm:ss Timezone Year"

eg for IST use timezone= UTC+5:30 例如,对于IST,使用时区= UTC + 5:30

sudo date -s "Thu Aug 9 21:31:26 UTC+5:30 2019"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM