IMDHMIControls LibraryShop main store

Troubleshooting

Why an OPC UA server certificate mismatch stops the server at startup

SCADA and data logging Published 6 min read By IMDHMI controls team

Short answer

An OPC UA server that stops itself at startup with a domain-not-in-certificate message is failing its own identity check: the address in its endpoint configuration, for example 192.168.0.117, does not appear among the Subject Alternative Name entries of its application certificate. Run the installer's Repair on the intended host to regenerate the certificate, or host the server on a PC whose certificate already matches and point the analysis client at that host.

On this page
  1. The check the server performs at launch
  2. Why the configured address is missing from the certificate
  3. Run Repair from the product setup
  4. Install the server on a PC whose certificate matches
  5. Worked identity check
  6. Decision for each case
  7. Questions asked

When EcoStruxure OPC UA Server Expert version 2.0 closes itself at launch with a message that the configured domain, here the address 192.168.0.117, does not appear in the certificate, the server is failing its own identity check before any client connects: the address in its endpoint configuration is not among the Subject Alternative Name entries of its application certificate. Regenerate the certificate on the intended host with the Repair function of the product's setup program, or install the server on a PC whose certificate already matches its own address. In the installation that produced this error, a plant with a Modicon M580 PLC and two Citect SCADA PCs, the server started without error on a SCADA PC and the analysis client on the third PC then connected to it with no further changes.

The check the server performs at launch #

OPC UA Part 6, section 6.2.2 of the OPC Unified Architecture mappings, requires the application instance certificate to carry, in its Subject Alternative Name extension, the DNS names and IP addresses of the hosts through which clients reach the application, together with an ApplicationUri that names the application itself. The subject field format comes from IETF RFC 5280. Before it listens, the server compares the host identity in its configured endpoint URL against those entries; if the configured identity is absent it stops, because it would otherwise be offering a secured endpoint it cannot prove is its own. The startup message calls the address a domain, but the value is an IPv4 address, and an IP address and a DNS name are two different identity forms: reaching the same PC through either one does not make them interchangeable during this comparison.

This is a server-side identity failure, not the same problem as trusting an OPC UA client certificate on a B&R PLC, where the server is healthy and the client's certificate is the open question.

Why the configured address is missing from the certificate #

The certificate is generated once, when the server is first installed or configured, and it records the identities the host had at that moment. The endpoint address is a setting that can be edited afterwards. The two drift apart in four common ways:

  • The host's IPv4 address changed after certificate generation, for example after a move from static addressing or from one subnet to another.
  • The computer was renamed, so a DNS-name entry in the certificate no longer matches the host.
  • The configuration was copied from another PC, bringing that PC's endpoint address with it.
  • A certificate belonging to a different application or machine was selected in the configuration tool.

Before changing anything, read the active network adapter's address on the intended server PC and compare it with the address named in the startup message, then record the configured host, the endpoint URL and the selected certificate in the OPC configuration tool, and export the configuration with the tool's own backup facility.

Run Repair from the product setup #

The message itself names the documented fix: perform Repair using the setup of EcoStruxure OPC UA Server Expert. Work through it in this order:

  1. Export the current server configuration from the OPC configuration tool and note the configured host address, endpoint and selected certificate.
  2. Schedule a maintenance window, identify the clients that will reconnect afterwards, and close the server as the installer requires.
  3. Run the setup program for the installed release, version 2.0 here, with the privileges its documentation requires, and confirm setup recognizes the existing installation.
  4. Choose Repair and follow the documented prompts. If your installation offers no Repair, obtain the version-specific procedure from the vendor's official support channel rather than deleting certificate stores or application files by hand.
  5. Reopen the configuration tool and confirm the selected certificate's Subject Alternative Name now contains the intended address, and that the configuration still references that certificate.
  6. Start the server and confirm the mismatch message is gone before commissioning any client.

Repair replaces the certificate, so every client that trusted the previous one must trust the new file; verify the replacement's identity and fingerprint before accepting it. That step is a separate, client-side task, and why certificate trust fails between an S7-1200 and a panel walks through the mechanics of that class of failure.

Install the server on a PC whose certificate matches #

When the intended host cannot be repaired promptly, install the server on a machine whose own certificate already agrees with its address. In the plant that hit this error, the server installed on one of the Citect SCADA PCs started with no error message, and the OPC UA client on the third PC reached it without any change on the client side. Treat this as a production change: the server then shares the SCADA PC's resources and restarts with it, so have the change approved before adding the service there.

If you are specifying a dedicated host instead, a computer that sits in the cabinet next to the controller and serves OPC UA — an industrial mini PC sized for that role — keeps the analysis traffic off the SCADA machines entirely.

Worked identity check #

Take the case values as example numbers. The server is configured for the endpoint opc.tcp://192.168.0.117:4840 on the third PC, where 4840 is the IANA-registered default OPC UA port and the server configuration can set another. The certificate on that PC was generated when it held the example address 192.168.0.50, so its Subject Alternative Name carries two host entries:

Subject Alternative Name entry Value
DNS name (example) DESKTOP-7K2
IP address, the address at generation time 192.168.0.50

Compare the configured identity 192.168.0.117 against each entry. The DNS entry is not an address form, so no match; the IP entry 192.168.0.50 differs from 192.168.0.117, so no match. Matches found: 0 of the 1 required — the configured domain fails the check and the server stops. A client later performs the same comparison in reverse against the certificate the server presents, so a certificate that passes the server's own launch check also passes address-form validation on the client side.

Decision for each case #

  • Immediate recovery: install the server on a PC whose certificate matches its own address — the SCADA PC in this plant — and point the analysis client at that host. That arrangement produced a running server and a working remote client on the first attempt.
  • If the server must run on its own host: run Repair from the version 2.0 setup on that host, verify the new Subject Alternative Name contains the address you configure, then restart and commission clients.
  • Spend nothing on PLC settings, firewall rules or repeated client-side certificate acceptance for this message: all of those live after the startup check, and a server with a certificate mismatch never reaches them.

Questions asked

Can I fix the mismatch by editing the certificate file directly?

No. The Subject Alternative Name sits inside the signed certificate, so a hand edit breaks the signature and the private key binding, and the server still fails. Use the Repair function of the product setup, which regenerates the certificate for the host it runs on. Do not disable certificate validation anywhere to get past this message: the server stops itself before any client is involved.

Should the certificate contain the IP address or the DNS hostname?

Either identity form is valid, but the address the server is configured to use must appear exactly as one Subject Alternative Name entry. A DNS name and an IP address are separate entries: if some clients reach the PC by name and others by address, both forms belong in the certificate. After a Repair, confirm the new certificate carries the same form your endpoint URL uses.

Why did the server start on the SCADA PC with no changes at all?

The installer generated that PC's certificate with the SCADA PC's own host identities in the Subject Alternative Name, so the configured endpoint matched and the startup check passed. Copying a configuration between PCs copies the endpoint setting but not a matching certificate, which is exactly the situation that produces the domain-not-in-certificate message on a new host.

The server now stays running but the client still cannot connect. What next?

The identity mismatch is solved; the remaining fault is downstream. Work through three layers in order: whether the client trusts the new server certificate, whether the endpoint address and port are reachable over the network, and whether the server can read the PLC data it exposes. The startup message will not return unless the certificate is replaced again.

Keep reading

  • Troubleshooting

    Why OPC UA certificate trust fails between an S7-1200 and a panel

    OPC UA trust is directional: the S7-1200 server must trust the panel's client certificate, and the panel must trust the CPU's server certificate, and neither the no-certificate run nor the UA Expert session exercised either panel trust entry. Export the panel's client certificate from Unified Certificate Manager into the CPU's trust list, import the CPU's server certificate into the panel as trusted, then retest with the same security policy.

    SCADA and data logging

  • How-to

    Connect an S7-1500 to SCADA over OPC UA from TIA Portal

    The S7-1500 has a built-in OPC UA server from firmware V2.0, deactivated by default. Enable it in the CPU device properties in TIA Portal, select the installed server license, copy the endpoint URL, and download. Paste the opc.tcp address into any OPC UA SCADA client, trust the certificates on both sides, then browse the PLC variables and map them to SCADA tags.

    SCADA and data logging

  • How-to

    Connecting a CODESYS HMI on Windows to an S7-1500 PLC

    Yes, it works. Use OPC UA with the S7-1500 as server and the CODESYS HMI as client when the PC only supervises; use a CODESYS Control Win runtime with target visualization over a PROFINET controller/device link when the PC must also run logic. The PROFINET path adds one single-device license on top of the runtime; the OPC UA path adds none.

    SCADA and data logging