Connection to OPC lost, trying reconnect

Questions regarding installing, running and configuring UaGateway.

Moderator: uagateway

Post Reply
aboe
Jr. Member
Jr. Member
Posts: 2
Joined: 06 Feb 2018, 11:07

Connection to OPC lost, trying reconnect

Post by aboe »

Hi all,

we are trying to install uaGateway on a local pc with an underlying OPC Server. The software was installed with admin privileges but runs under the user operator, who has no admin privileges.
When I'm trying to connect to the underlying OPC, I get the Error: Lost connection, trying reconnect.

Is there a chance to debug this? Does the Launching User of uaGateway needs admin privileges?

Thanks.
André

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: Connection to OPC lost, trying reconnect

Post by Support Team »

Hello Andre,

on local installations still some OPC Servers do not let the UaGateway connect.
First, in most cases this is caused by a wrong DCOM setting of the underlying OPC Server. Check out the DCOM configuration of the underlying OPC Server, the "Identity" should be set to "This user" (instead of "the launching user"). The reason is that the underlying Server should always start up with the same credentials of a dedicated user, but not switching identity depending on who actually started it. Of course "This user" should be either identical to the UaGateway launching credentials or at least be member of the Group "UaGatewayUsers".

Secondly, and even more dramatic, is the fact that in Windows 10 the Security Initialization (CoInitializeSecurity) was broken with Windows 10 update (KB4056892). If you have such operating system and this update was installed, you must contact Microsoft for patch or new update that fixes the issue. There is no other workaround.
Best regards
Unified Automation Support Team

azheem
Jr. Member
Jr. Member
Posts: 2
Joined: 22 Feb 2024, 05:13

Re: Connection to OPC lost, trying reconnect

Post by azheem »

Hello, we are trying to connect a UA Gateway to an Alstom Centralog OPC DA Server. We are using UA Gateway v1.5.14-495 and the system is running on Windows Server 2003. We are having the same problem of getting the server status Lost connection, trying to reconnect.

While at the same time, we tried using OPC Explorer application to connect to the OPC Server and it worked.

We have tried your suggestion to change the DCOM configuration for the OPC Server so that the Identity is equalized with the UA Gateway user, but that has not solved our problem. Do you have any other suggestions?

Thanks. Azhim

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: Connection to OPC lost, trying reconnect

Post by Support Team »

Hi,

the UaGateway is not tested with any DCOM connection (no valid use case). See documentation here:
https://documentation.unified-automation.com/uagateway/1.5.15/html/limitations.html#limitations_only_local_dcom_connections

You must install UaGateway on the PC where the classic DA Server is running. However the Win2003Server operating system is not supported, hence installation will give you several errors (no Firewall, no AccessControl Limits, etc.). Therefore even locally the connection will (in most cases) not be established. There is no DCOM setting that will help you achieve this goal.
Best regards
Unified Automation Support Team

azheem
Jr. Member
Jr. Member
Posts: 2
Joined: 22 Feb 2024, 05:13

Re: Connection to OPC lost, trying reconnect

Post by azheem »

Thanks for your response. I've tried your suggestion to install the UAGateway on local DA server, the OS is Windows XP but we're still getting the same problem.

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: Connection to OPC lost, trying reconnect

Post by Support Team »

Hi,

in case you get no local connection running from UaGateway to your local DA Server (lost connection, trying reconnect) the most comon problem is the DA Server being just a wrapper on the data source, having insufficient permissions. The Microsoft COM is inheriting lauch permission and access permission from the caller (the DA Client, UaGateway) to the receiver (the DA Server, underlying). However for data-change callback (mostly used to read data by some OPC DA Client) the DA Server calls back the client (sending the changed data). For this you need access permission in oposit direction.

The UaGateway is an NT-Service but runs with dedicated user. You must check the DA Server process in Taskmanager and add the user running the DA Server to the "UaGatewayUserGroup" in your local Windows user store. This should be enough, because UaGateway set all ACL correctly during installation.

In rare cases you furthermore make sure the DA Server COM object is not impersonating the lauching user, but instead uses it's own dedicated user "This User", with dedicated user/pwd credentials (empty PWD is not allowed). The UAGateway-User and the DAServer-User must have access permissions vice versa (most easy configuration, if same user is used).

Note: when manually changing launch- and access permissions on local COM objects (DA Server), you may break the system completely. Therefore you better have HDD-image before changing anything on your life system.
Best regards
Unified Automation Support Team

Post Reply