zoukankan      html  css  js  c++  java
  • kubernetes二进制部署时ca认证排错记录

    在用二进制部署kubernetes v1.8.3时,遭遇两个ca认证的问题,特记录如下.


    1 IP SANs问题

     x509: cannot validate certificate for <worker_node_ip> because it doesn't contain any IP SANs
    
    

    网上搜到的解决办法如下:

            修改 /etc/pki/tls/openssl.cnf 配置,在该文件中找到 [ v3_ca ] ,在它下面添加如下内容:

                    [ v3_ca ] # Extensions for a typical CA
                        subjectAltName = IP:123.56.157.144    修改对应IP信息

      ipsans是 x509新加入的协议

    因为笔者不是用的openssl工具制作的ca证书,用的easyrsa3,通过查看easyrsa的文档,解决方法如下:




    2  x509: certificate signed by unknown authority (possibly because of "crypto/rsa: verification error

    出现这个错误的原因,是因为自签名的证书未得到操作系统认可,ca不在操作系统认可的ca列表里,解决办法如下:



    最终kubeconfig如下




    参考:  https://www.qiansw.com/add-the-ca-root-certificate-to-the-operating-system-for-trust.html

  • 相关阅读:
    MySQL "show users"
    MySQL
    A MySQL 'create table' syntax example
    MySQL backup
    MySQL show status
    Tomcat, pathinfo, and servlets
    Servlet forward example
    Servlet redirect example
    Java servlet example
    How to forward from one JSP to another JSP
  • 原文地址:https://www.cnblogs.com/360linux/p/13062102.html
Copyright © 2011-2022 走看看