详解nginx使用ssl模块配置支持HTTPS访问

2019-10-17 17:31:47刘景俊

出现这种情况的解决方案参考错误一的第二种情况的解决方案即可。

错误三:

Stoping nginx... nginx: [emerg] BIO_new_file("/usr/local/nginx/conf/cert/214291778530222.pem") failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/usr/local/nginx/conf/cert/214291778530222.pem','r') error:2006D080:BIO routines:BIO_new_file:no such file) failed. Use force-quit

解决方案:

这可能是证书路径存放的位置不正确导致的,而且只要写绝对路径,就会报错,无论windows还是linux。

将证书文件放到nginx.conf所在的目录下即可。

以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持易采站长站。