Technical FAQs

Ask a Question

OPC Server - Does not provide Tags - no data coming through to clients


ION Enterprise OPC Server does not provide any data to clients. Browsing the OPC Server from different clients may show folders, but not any tags. Trying to add one of these folders to the client may result in errors like "Failed to add item" or "The item ID is not defined in the server address space" which contain the code C0040007.

ION Enterprise OPC Test Client

Kepware OPC Quick Client

Matrikon OPC Explorer

Product Line
ION Enterprise 5.5, ION Enterprise 5.6, ION Enterprise 6.0, StruxureWare Power Monitoring 7.0.1, SturuxureWare Power Monitoring Expert 7.2.2

ION Enterprise OPC Test Client
Kepware OPC Quick Client
Matrikon OPC Explorer

There is an extra file in the \ION Enterprise\system\bin folder that the ION OPC Server is erroneously using as its configuration file. This file is causing ION OPC Server to not function properly.

In \ION Enterprise\system\bin, you will find two files:

  1. ION.OpcDaServer.exe.config <- good config file - a short XML file
  2. ION.OpcDaServer.config <- bad config file - binary file

Delete the 2nd, bad config file.
Make a copy of the 1st, good config file. Rename it to the same name as the bad one (remove the ".exe" from the middle).
Restart OPC Server.

More Information
The root cause of this problem is that .NET applications are looking for config files with the wrong names. Normally, when a .NET application is started (like OPC Server), it automatically looks for a file name "<application name>.exe.config". i.e. The OPC server " ION.OpcServerDa.exe" has an associated config file " ION.OpcServerDa.exe.config".
This is a small XML file that has configuration info for the application - which version of the .NET framework it uses, regional settings, database connection info, etc.

On some machines, .NET applications seem to be looking for config files with the name "<application name>.config". No ".exe" in the middle. Speculation is that it might be a bug in .NET 2.0 SP1. This issue needs more investigation.

ION OPC Server tries to use " ION.OpcServerDa.config" on startup, instead of the correct " ION.OpcServerDa.exe.config". A file with this name does not normally appear on ION Enterprise systems. Our OPC Test Client (OpcTestClient.exe) creates this file when you browse the ION OPC Server, then click File->Save. It creates files with the name "<OPC Server it's connected to>.config" and stores the subscription info in it, for retrieval the next time you open it. It is a binary file that is not human-readable. ION OPC Server can not read this binary file, and interprets it as a corrupt config file.

This causes a very strange .NET Exception from normally reliable & robust code. "The type initializer for 'System.Data.SqlClient.SqlConnection' threw an exception." It's a very standard call to a .NET function, in one particular place of the OPC Server code, that is even used in several other places. There is no actual reason this exception should be thrown. Unfortunately, because of the place in code this exception is being thrown, it is not logged anywhere.

Because of the exception handling in this area of code, instead of halting and reporting that an exception has occurred, instead it just returns from the routine without some variables being set correctly. This code is in the function that determines whether an OPC tag represents an "Item" or a "Grouping Object". The fall-through exception handling causes every tag in the system to be incorrectly reported as a "Grouping Object", even if it is truly an "Item".

Was this helpful?
What can we do to improve the information ?