Error -356612 or Error -356653 When Connecting to OPC UA Server

Updated May 11, 2023

Reported In

Software

  • LabVIEW OPC UA Toolkit

Issue Details

I am using the LabVIEW OPC UA Toolkit to connect my OPC UA client VI to an OPC UA server. The OPC UA Client Connect VI is reporting the one of the following errors:

Error -356612 occurred at NI OPC UA Client.lvlib:Connect.vi

Possible reason(s):

OPC UA Toolkit:  (Hex 0xFFFA8EFC) A communication problem occurred. Ensure that the OPC UA server that you specify in the server endpoint URL is running and the network between the OPC UA server and the OPC UA client is connectable.


 

Error 356653 occurred at NI OPC UA Client.lvlib:Connect.vi

Possible reason(s):

OPC UA Toolkit: (Hex 0xFFFA8ED3) The status of the OPC UA server is uncertain

 

image.png

 

Solution

This error indicates that the client VI was not able to establish a connection with the server. Try the following steps to resolve this error. Please note that you may need to contact the OPC UA server manufacturer to verify some of this information:
  1. When using PLCs make sure they support the OPC UA protocol. 
  2. Make sure that the endpoint URL is correctly formatted. It should be in the format opc.tcp://[server hostname or IP address]:[server port number]
  3. Make sure that the server hostname or IP address and OPC UA port number are correct.
  4. Check that the client is using the correct security policy that the server expects. For example, if the client is trying to use a policy of None, but this isn't supported by the server, it might give you this error.
  5. If using a security policy, make sure that the server is configured to trust your computer as a client and that the client has the correct security certificate.
  6. Some 3rd-party OPC UA servers use tunneling applications that are used to communicate data across firewalls. In these cases, LabVIEW may not be able to communicate directly with the server and may need to communicate with the tunneling client application instead.  
  7. It could be that your OPC Certificate has expired. Make sure you have gone through the steps to make sure your Certificate is valid and updated.
  8. Register the IP address and hostname on the Windows Hosts file. You will find it at C:\Windows\System32\drivers\etc.  Use the host name as the server endpoint URL.
OPC_Host.JPG

Additional Information

When getting OPC UA connection issues, you can run the OPC UA Demo LabVIEW example to make sure that your LabVIEW OPC UA client VI is able to communicate with a LabVIEW OPC UA server. You can also try using 3rd-party OPC UA client software (such as UA Expert from Unified Automation) to test the connection to the server.