Skip to main content
SnapCenter software
简体中文版经机器翻译而成,仅供参考。如与英语版出现任何冲突,应以英语版为准。

在 Linux 主机上配置双向 SSL 通信

您应该配置双向 SSL 通信以保护 Linux 主机上的SnapCenter服务器与插件之间的相互通信。

开始之前
  • 您应该已经为 Linux 主机配置了 CA 证书。

  • 您必须在所有插件主机和SnapCenter服务器上启用双向 SSL 通信。

步骤
  1. certificate.pem 复制到 /etc/pki/ca-trust/source/anchors/

  2. 将证书添加到 Linux 主机的信任列表中。

    • cp root-ca.pem /etc/pki/ca-trust/source/anchors/

    • cp certificate.pem /etc/pki/ca-trust/source/anchors/

    • update-ca-trust extract

  3. 验证证书是否已添加到信任列表。 trust list | grep "<CN of your certificate>"

  4. 更新SnapCenter nginx 文件中的 ssl_certificatessl_certificate_key 并重新启动。

    • vim /etc/nginx/conf.d/snapcenter.conf

    • systemctl restart nginx

  5. 刷新SnapCenter服务器 GUI 链接。

  6. 更新位于 _ /<安装路径>/ NetApp /snapcenter/SnapManagerWeb_ 的 * SnapManager .Web.UI.dll.config* 和位于 /<安装路径>/ NetApp/snapcenter/SMCoreSMCoreServiceHost.dll.config 中的以下注册表项的值。

    • <add key="SERVICE_CERTIFICATE_PATH" value="<证书.pfx 的路径>" />

    • <添加键=“SERVICE_CERTIFICATE_PASSWORD”值=“<密码>”/>

  7. 重新启动以下服务。

    • systemctl restart smcore.service

    • systemctl restart snapmanagerweb.service

  8. 验证证书是否已附加到SnapManager Web 端口。 openssl s_client -connect localhost:8146 -brief

  9. 验证证书是否已附加到 smcore 端口。 openssl s_client -connect localhost:8145 -brief

  10. 管理 SPL 密钥库和别名的密码。

    1. 检索分配给 SPL 属性文件中的 SPL_KEYSTORE_PASS 键的 SPL 密钥库默认密码。

    2. 更改密钥库密码。 keytool -storepasswd -keystore keystore.jks

    3. 更改所有私钥条目别名的密码。 keytool -keypasswd -alias "<alias_name>" -keystore keystore.jks

    4. spl.properties 中的密钥 SPL_KEYSTORE_PASS 更新相同的密码。

    5. 重新启动服务。

  11. 在插件 Linux 主机上,在 SPL 插件的密钥库中添加根证书和中间证书。

    • keytool -import -trustcacerts -alias <any preferred alias name> -file <path of root-ca.pem> -keystore <path of keystore.jks mentioned in spl.properties file>

    • keytool -importkeystore -srckeystore <path of certificate.pfx> -srcstoretype pkcs12 -destkeystore <path of keystore.jks mentioned in spl.properties file> -deststoretype JKS

      1. 检查 keystore.jks 中的条目。 keytool -list -v -keystore <path to keystore.jks>

      2. 如果需要,重命名任何别名。 keytool -changealias -alias "old-alias" -destalias "new-alias" -keypass keypass -keystore </path/to/keystore> -storepass storepas

  12. 使用存储在 keystore.jks 中的 certificate.pfx 的别名更新 spl.properties 文件中的 SPL_CERTIFICATE_ALIAS 的值,然后重新启动 SPL 服务: systemctl restart spl

  13. 验证证书是否已附加到 smcore 端口。 openssl s_client -connect localhost:8145 -brief