- Posts: 27
- Thank you received: 0
Online Forums
Technical support is provided through Support Forums below. Anybody can view them; you need to Register/Login to our site (see links in upper right corner) in order to Post questions. You do not have to be a licensed user of our product.
Please read Rules for forum posts before reporting your issue or asking a question. OPC Labs team is actively monitoring the forums, and replies as soon as possible. Various technical information can also be found in our Knowledge Base. For your convenience, we have also assembled a Frequently Asked Questions page.
Do not use the Contact page for technical issues.
- Forum
- Discussions
- QuickOPC-UA in .NET
- General Issues, Building
- Timeout during WriteMultipleItemValues
Timeout during WriteMultipleItemValues
So, it is necessary to have the whole record of all log entries to rule out the queue overflow. Please check it, or post it here or send to support09 (at) opclabs.com.
This is the code how I subscribe to log and start the opc client
private static EasyDAClient Create()
{
EasyDAClient.LogEntry += EasyDAClientOnLogEntry;
EasyDAClient.SharedParameters.TopicParameters.TopicRetrialDelay = 0;
var opcClient = new EasyDAClient();
ApplyOpcLabsLicense(opcClient);
opcClient.InstanceParameters.EnableNativeClient = false;
opcClient.InstanceParameters.EnableNetApiClient = true;
opcClient.InstanceParameters.Mode.AllowAsynchronousMethod = false;
opcClient.InstanceParameters.Mode.DesiredMethod = OpcLabs.EasyOpc.DataAccess.Engine.DAReadWriteMethod.Synchronous;
opcClient.InstanceParameters.Timeouts.BrowseAccessPaths = int.MaxValue;
opcClient.InstanceParameters.Timeouts.BrowseNodes = int.MaxValue;
opcClient.InstanceParameters.Timeouts.BrowseProperties = int.MaxValue;
opcClient.InstanceParameters.Timeouts.BrowseServers = int.MaxValue;
opcClient.InstanceParameters.Timeouts.GetProperty = int.MaxValue;
opcClient.InstanceParameters.Timeouts.ReadItem = int.MaxValue;
opcClient.InstanceParameters.Timeouts.WriteItem = int.MaxValue;
return opcClient;
}
private static void EasyDAClientOnLogEntry(object sender, LogEntryEventArgs args)
{
//write to file
}
Below is the log entries that I got:
As you can see, logs were only created while the license was being applied. Do you have any idea why no logs were produced after that?
2025-01-20 13:58:33.5866|Information(1201): Licensing for EasyDAClient component started, license serial number *******, issuer name "*******", subject name "********".
2025-01-20 13:58:33.6786|Error(2): COM security initialization (process name "********", Id 20820) for requestor 'ComSecurityInitializingEasyDAClient' failed; the initialization object was: (Default).
CoInitializeSecurity failure (0x80010119): Security must be initialized before any interfaces are marshalled or unmarshalled. It cannot be changed once initialized.
+ This error (RPC_E_TOO_LATE) is not uncommon in hosted .NET applications. Depending on various factors, it might be possible to prevent it, or safely ignore it (if COM works as intended). Consult the product documentation.
+ Current thread name: "", from thread pool: yes, managed thread Id: 9, apartment state: MTA.
Please Log in or Create an account to join the conversation.
1) Try to increase the timeout (I can give instructions on how to do that), or
2) Try to use OPC Analyzer to analyze the communication between QuickOPC (your app) and the Kepware server. That would tell us whether it is the Kepware server not returning the "write" result in time, or some issue on QuickOPC side. Again, I can give some instruction on this if you like.
It would be great if you could give me instructions on how to increase the timeout and also what kind and how to use OPC Analyzer.
Please Log in or Create an account to join the conversation.
Thanks for the info. I am slightly concerned about the fact you worded your response. You wrote "I do see some log entries when I apply the license but I don't see any log entries when this error happens". If there truly was a queue overflow (which is what I am trying to determine), the log entry for that would *not* be when the :Write not completed" error occurs. It would be somewhere before it (even a long time before it). So, it is necessary to have the whole record of all log entries to rule out the queue overflow. Please check it, or post it here or send to support09 (at) opclabs.com.
In case the queue overflow is not the cause, it can then be truly the case that the server has not reported the outcome of the "Write" operation in time. And yes, that may have to do with the fact it is Modbus - perhaps even the actual device had not responded at all (or not in time). I think the default timeout now is 20 seconds. You can either
1) Try to increase the timeout (I can give instructions on how to do that), or
2) Try to use OPC Analyzer to analyze the communication between QuickOPC (your app) and the Kepware server. That would tell us whether it is the Kepware server not returning the "write" result in time, or some issue on QuickOPC side. Again, I can give some instruction on this if you like.
Best regards
Please Log in or Create an account to join the conversation.
Attachments:
Please Log in or Create an account to join the conversation.
EasyDAClient.LogEntry += EasyDAClientOnLogEntry;
Please Log in or Create an account to join the conversation.
see:
- opclabs.doc-that.com/files/onlinedocs/OPCLabs-OpcStudio/Late...PC%20UA%20event%20logging.html
- opclabs.doc-that.com/files/onlinedocs/OPCLabs-OpcStudio/Late...mponent%20Event%20Logging.html
The example provided is for EasyUAClient, but can be made analogically for EasyDAClient.
Regards
Please Log in or Create an account to join the conversation.
Once in a while I get the following error when using WriteMultipleItemValues. What can do to resolve/debug and understand what's causing it. The message suggests to Check the event log for queue overflow errors, where are the logs?:
Write not completed. This error indicates that it could not be verified that the requested write operation was completed during the timeout period. It is possible that the write operation will actually succeed or fail, but later. Increase the timeout period if you want to obtain positive or negative indication of the operation outcome. Other reason for this error may be that under heavy loads, topic request or response queue is overflowing. Check the event log for queue overflow errors (if event logging is supported by the product and enabled).
+ The client method called (or event/callback invoked) was 'WriteMultipleItemValues[4]'.
Please Log in or Create an account to join the conversation.
- Forum
- Discussions
- QuickOPC-UA in .NET
- General Issues, Building
- Timeout during WriteMultipleItemValues