主要内容

Polyspace Access ETL 和 Web Server 服务没有启动

问题

您启动了 Polyspace® Access™ 服务,但片刻之后,ETLWeb Server 服务停止了。当您尝试连接到 Polyspace Access 时,可能会在 Web 浏览器中看到 HTTP 403 错误消息。

可能的原因:Hyper-V 网络配置无法解析本地主机名

在 Windows® 上,如果您在虚拟机 (VM) 中安装了 Polyspace Access,则该虚拟机由 Hyper-V 管理。根据您的网络配置,Hyper-V 可能无法解析本地主机名。Polyspace Access ETLPolyspace Access Web Server 服务无法连接到您使用这些主机名指定的主机。

要测试 Hyper-V 是否能在连接到 Internet 的计算机上解析主机名 myHostname,请从命令行输入以下命令:

docker run --rm -it alpine ping myHostname
如果 Hyper-V 无法解析该主机名,则您会收到一条错误消息。

解决方案

停止并重新启动 admin-docker-agent 二进制文件,但不要使用 --hostname 选项。

  • 如果您位于受信任的网络中,或者您不想使用 HTTPS 协议,请执行以下操作:

    1. 从命令行输入以下命令:

      docker stop admin
      
      admin-docker-agent --restart-gateway

    2. Cluster Admin Web 界面中点击 Restart Apps

  • 如果您想使用 HTTPS 协议,请生成带有主题备用名称 (SAN) 的证书,其中包含运行这些服务的集群操作节点的 IP 地址。

    1. 将下面的配置文件复制到文本编辑器,并以 openssl.cnf 名称将其保存到您的计算机。

       配置文件

      hostName 是托管 Polyspace Access 的服务器的主机名。fullyQualifiedDomainName 是对应的完全限定域名。nodeIPAddress 是运行 admin-docker-agent 二进制文件的节点的 IP 地址。

      您无需编辑 openssl.cnf [ req_distinguished_name ] 部分中其他字段的值。更新这些字段的值不会影响配置。

    2. Cluster Dashboard 中点击 Configure NodesHostname 字段中列出的 IP 地址对应于 openssl.cnf 文件中的 nodeIPAddress。如果列出了多个节点,请在 openssl.cnf[ alt_names ] 部分中为每个 IP 地址额外添加一行。例如:

      [ alt_names ]
      DNS.1 = hostName
      DNS.2 = fullyQualifiedDomainName
      IP.1 = nodeIPAddress
      IP.2 = additionalNodeIPAddress

    3. 使用您的 openssl.cnf 配置文件生成证书签名请求 (CSR)。在命令行中输入:

      openssl req -new -out myReqest.csr -newkey rsa:4096 \
      -keyout myKey.key -nodes -config openssl.cnf
      此命令会输出私钥文件 myKey.key 和文件 myRequest.csr

    4. 生成签名证书:

      • 如果使用您的组织的 证书认证中心,请将 myRequest.csr 提交给该证书认证中心。证书认证中心使用该文件生成签名的服务器端证书。例如,server_cert.cer

      • 如果您使用自签名证书,请从命令行输入以下命令:

        openssl x509 -req -days 365 -in myRequest.csr -signkey myKey.key \
        -out self-cert.pem -extensions v3_req -extfile openssl.cnf
        此命令输出自签名证书 self-cert.pem

    5. 停止并使用以下命令重新启动 admin-docker-agent 二进制文件:

      Windows PowerShell
      ./admin-docker-agent --restart-gateway `
      --ssl-cert-file certFile1 `
      --ssl-key-file keyFile `
      --ssl-ca-file  trustedStoreFile
      Linux®
      ./admin-docker-agent --restart-gateway \
      --ssl-cert-file certFile1 \
      --ssl-key-file keyFile \
      --ssl-ca-file  trustedStoreFile

      certFile1 是在步骤 4 中获得的文件的完整路径。keyFile 是您在步骤 3 中生成的文件。trustedStoreFile 是您在步骤 4 中生成的文件(如果您使用自签名证书)。否则,它就是您用于配置 HTTPS 的信任存储文件。参阅为 Polyspace Access 选择 HTTP 或 HTTPS 配置,保存您的更改。

    6. Cluster Admin Web 界面中点击 Restart Apps