sfa-siard / siard-suite

Other
5 stars 0 forks source link

Archive failed with the message "External LOB folder could not be relativized!" with command line option -x #107

Open bt-cgi opened 4 weeks ago

bt-cgi commented 4 weeks ago

Hello,

I need to archive tables that contains Blob fields in command line. I try to use the option -x=D:\POC\Blob (existing folder) and the process failed with the message:

External LOB folder d:\POC\Blob could not be relativized!

Could you please tell me what caused this error?

Without this option, the blobs fields are stored into the siard file. Could you please tell me what is the benefit of this option ?

Thanks in advance.

mburri commented 1 week ago

Hi @bt-cgi Sorry for the late answer! We are currently busy with other projects.

Regarding your question. If your database contains some sort of binary data you'll have to options to handle it:

  1. Store the data inside your siard-archive file. This is what happened to you when you did not specify the option (-x=...)
  2. keep the binary data outside of the archive.

Option 1 is perfectly fine if your database contains only a few small blobs. But If there are lots of large blobs in your DB, the resulting siard-archive file can get quite big. It's perfectly possible that you could reach your Operating Systems file system limit this way.

This means that you should go with option 2 for larger databases and specify a folder where your blobs should be stored outside of the archive file.

You specified an absolute path - and this does not seem to work. While I'm surprised that it did not work at all, I'd advise against using absolute paths. See the documentation about the reasoning behind this: https://github.com/sfa-siard/siard-suite/blob/main/docs/user-manual/en/user-manual.adoc#archiving-databases-with-binary-data

Try with the option -x=./lobs and that's probably what you want.

I hope this still helps.