maximum filetype write size

Questions regarding the use of the C++ SDK for Server or Client development or integration into customer products ...

Moderator: uasdkcpp

Post Reply
scalfee
Hero Member
Hero Member
Posts: 73
Joined: 08 Mar 2014, 01:13

maximum filetype write size

Post by scalfee »

Hi,

I am trying out the fileType stuff. Pretty neat.

However I find that I cannot write 600Mbyte files? Just trying with some .mp4 file I had in my home directory.

OpcUa_UInt64 OpcUa::FileType::maxFileSize ( ) const
Get maximum file size accepted for writing.
Default value 0 is unlimited.

above returns 0.

I can write 10Mbyte files. I have not tried any size in between 10M and 600M. Is there some other limitation on the max file size?

Thanks, Steve

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

Re: maximum filetype write size

Post by Support Team »

Hello Steve,

are you trying to write that file locally or do you try to write the file from a client to the server?

What error code do you get when the write fails for the 600 MB file?

Best Regards

Unified Automation Support Team

scalfee
Hero Member
Hero Member
Posts: 73
Joined: 08 Mar 2014, 01:13

Re: maximum filetype write size

Post by scalfee »

Hi,

I am doing the upload from uaexpert client to my custom, but not very far from uaservercpp server.

Here is the log file. It says there was a disconnect/reconnect during the write failure. The server did not crash and did not log anything to the console.

Code: Select all

10:21:38.711 | Method Plugin      | UaSdkC - Lesson07 - None - ... | <-- QascMethodPlugin::sltMethodCall()
10:21:36.816 | Method Plugin      | UaSdkC - Lesson07 - None - ... | Call succeeded
10:21:33.778 | Method Plugin      | UaSdkC - Lesson07 - None - ... | Read property Description on node NS2|String|testing_binary.Close returned status 0x80350000
10:21:33.769 | Method Plugin      | UaSdkC - Lesson07 - None - ... | The method has only input arguments
10:21:33.762 | Method Plugin      | UaSdkC - Lesson07 - None - ... | --> QascMethodPlugin::sltMethodCall()
10:21:32.667 | Reference Plugin   | UaSdkC - Lesson07 - None - ... | Browse succeeded.
10:21:32.666 | Attribute Plugin   | UaSdkC - Lesson07 - None - ... | Read attributes of node 'NS2|String|testing_binary.Close' succeeded [ret = Good].
10:21:30.660 | Method Plugin      | UaSdkC - Lesson07 - None - ... | <-- QascMethodPlugin::sltMethodCall()
10:21:08.442 | Server Node        | UaSdkC - Lesson07 - None - ... | Connection status of server 'UaSdkC - Lesson07 - None - None' changed to 'Connected'.
10:21:08.441 | AddressSpaceModel  | UaSdkC - Lesson07 - None - ... | Registered for ModelChangeEvents
10:21:08.272 | Server Node        | UaSdkC - Lesson07 - None - ... | Connection status of server 'UaSdkC - Lesson07 - None - None' changed to 'ConnectionErrorApiReconnect'.
10:21:08.272 | Method Plugin      | UaSdkC - Lesson07 - None - ... | Call failed with status 'BadDisconnect'
10:20:19.531 | Method Plugin      | UaSdkC - Lesson07 - None - ... | Read property Description on node NS2|String|testing_binary.
 returned status 0x80350000
10:20:19.526 | Method Plugin      | UaSdkC - Lesson07 - None - ... | The method has only input arguments
10:20:19.523 | Method Plugin      | UaSdkC - Lesson07 - None - ... | --> QascMethodPlugin::sltMethodCall()
10:20:16.120 | Reference Plugin   | UaSdkC - Lesson07 - None - ... | Browse succeeded.
10:20:16.119 | Attribute Plugin   | UaSdkC - Lesson07 - None - ... | Read attributes of node 'NS2|String|testing_binary.Write' succeeded [ret = Good].
10:20:13.263 | Reference Plugin   | UaSdkC - Lesson07 - None - ... | Browse succeeded.
10:20:13.263 | Attribute Plugin   | UaSdkC - Lesson07 - None - ... | Read attributes of node 'NS2|String|testing_binary.Close' succeeded [ret = Good].
10:20:08.735 | Reference Plugin   | UaSdkC - Lesson07 - None - ... | Browse succeeded.
10:20:08.732 | Attribute Plugin   | UaSdkC - Lesson07 - None - ... | Read attributes of node 'NS2|String|testing_binary.Write' succeeded [ret = Good].
10:20:05.970 | Method Plugin      | UaSdkC - Lesson07 - None - ... | <-- QascMethodPlugin::sltMethodCall()
10:20:04.590 | Method Plugin      | UaSdkC - Lesson07 - None - ... | Call succeeded
10:20:00.017 | Method Plugin      | UaSdkC - Lesson07 - None - ... | Read property Description on node NS2|String|testing_binary.Open returned status 0x80350000
10:20:00.011 | Method Plugin      | UaSdkC - Lesson07 - None - ... | The method has input and output arguments
10:20:00.009 | Method Plugin      | UaSdkC - Lesson07 - None - ... | --> QascMethodPlugin::sltMethodCall()
10:19:57.655 | Reference Plugin   | UaSdkC - Lesson07 - None - ... | Browse succeeded.
10:19:57.654 | Attribute Plugin   | UaSdkC - Lesson07 - None - ... | Read attributes of node 'NS2|String|testing_binary.Open' succeeded [ret = Good].
10:19:25.828 | Method Plugin      | UaSdkC - Lesson07 - None - ... | <-- QascMethodPlugin::sltMethodCall()
10:19:24.766 | Method Plugin      | UaSdkC - Lesson07 - None - ... | Call succeeded
10:19:21.157 | Method Plugin      | UaSdkC - Lesson07 - None - ... | 

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

Re: maximum filetype write size

Post by Support Team »

Hi,

This is not an issue in client or server side, it is just a problem with the way you use the functionality.

OPC UA messages have certain security related limitations like max message size, max byte string size, max string size. These limitations are one of the reasons why we added the file type. The Read and Write methods allow a client and server to limit the size of a single block to read or write and read and write can be called several times to exchange the complete file. The FileType provides the synchronization context (open/close) to allow only one client to open the file if write capability is requested.

The problem is that you can load only the complete file with UaExpert and you can not load parts of a file. UaExpert tries to call write then with the whole file. This works as long as the file size does not exceed the encoder limit which is 16MB for the message size. If you exceed these limits, the connection will be closed between client and server. This is what you can see in the log.

You must program your own client that writes data blocks smaller than 16MB and it should work then.

Best Regards,
Unified Automation Support Team

Post Reply