Identify if the file is being copied

Welcome to BestSync Support Forum!
If you have any questions, comments, concerns, suggestion, please summit here, we'll try to reply you in short time.
Thank you!
Post Reply
vsurapaneni
Posts: 2
Joined: Wed Aug 30, 2017 3:37 pm

Identify if the file is being copied

Post by vsurapaneni »

Hi,

We have a setup where BestSync is used for transferring files from one network to another network over LAN-LAN VPN and then the files are further processed at a certain frequency from the target folders.

Right now, we have an issue where the files are being processed from the target folder even before they are copied to that location completely causing incomplete files.

Few years back, when we had a similar issue with BestSync we created a rule in our app to ignore files starting with _BS since we thought the temp files created by BestSync started with that naming convention. And that resolved the issue for us until we started using the latest version of BestSync and in this version it doesn't seem to create temp files in that naming convention.

Also to work around the issue, we checked the write option on the file in the target folder and it is returning true indicating that the file can be modified, so we assumed that the file copy is complete and so we can consider that file for processing. But even this resulted in incomplete files.

The Best Sync logs does not indicate any failures, so I think the files are copied correctly, it is just the further processing started before the files are copied completely.

Any ideas on how we can identify the files that are copied completely to avoid this issue.

Thanks in advamce.
RiseFly
Site Admin
Posts: 1077
Joined: Tue Nov 03, 2009 2:51 pm

Re: Identify if the file is being copied

Post by RiseFly »

There is an option in BestSync for using the temporary file while transferring the file.
The option is "Use intermediate file during copy." in "Copy Options" tab.

The intermediate file is named like following rule:
_BS8_<Original File Name>.BS_.<Original Extension>
vsurapaneni
Posts: 2
Joined: Wed Aug 30, 2017 3:37 pm

Re: Identify if the file is being copied

Post by vsurapaneni »

The temp naming convention is what we have used earlier. Does it work when we upload files to SFTP also ?
RiseFly
Site Admin
Posts: 1077
Joined: Tue Nov 03, 2009 2:51 pm

Re: Identify if the file is being copied

Post by RiseFly »

Yes, this method should work with uploading files to SFTP.
Post Reply