correct.
On Mo, 2014-09-22 at 11:33 -0400, Artemios G. Voyiatzis wrote:
Thank you for the prompt reply. Regarding #2, it means that it takes 3 rounds of hashing before sending a file?
-----Original Message----- From: Ibr-dtn [mailto:ibr-dtn-bounces@ibr.cs.tu-bs.de] On Behalf Of David Goltzsche Sent: Monday, September 22, 2014 5:24 PM To: ibr-dtn@ibr.cs.tu-bs.de Subject: Re: [ibr-dtn] dtnoutbox handling of files
Hi Artemios,
On Mo, 2014-09-22 at 09:14 -0400, Artemios G. Voyiatzis wrote:
Hi,
I am trying to understand how dtnoutbox handles file deletion after it has been sent and I hope you can shed some light on this :)
I am checking https://github.com/ibrdtn/ibrdtn/blob/master/ibrdtn/tools/src/dtnoutbox.cpp and some older versions of the code. I understand that dtnoutbox checks periodically a directory for changes and if it finds news files, it sends them to the destination EID.
Now my questions are two:
- Is there an option or functionality so that the files are removed (deleted) from the directory, once they are sent? If not, then they must be removed manually by another script; in that case how could be the script informed if the dtnoutbox is processing the file by the time the script tries to delete it?
This functionality has been removed when adding support for libarchive. You could set the --verbose flag and parse the output in order to inform your script.
- How is the "rounds" parameter used? If the file remains unchanged after say 3 rounds, dtnoutbox will stop trying sending it? If another process adds more data in the file later on, this will go unnoticed?
Dtnoutbox takes hashes of the files and compares them. If a file's hash stays unchanged for 3 (this the default value) rounds; dtnoutbox assumes that some process has finished writing the file and sends it out. If another process changes the file later, the hash changes and dtnoutbox will send it again.
If it is of an any help, I am exploring how IBR-DTN can be used to build a log file (measurements) transfer mechanism over DTN; another process will be placing the log files to the outbox folder and expect to have them delivered to the collection point (dtninbox).
Thank you, Artemios.
I hope it helps!
David
-- !! This message is brought to you via the `ibr-dtn' mailing list. !! Please do not reply to this message to unsubscribe. To unsubscribe or adjust !! your settings, send a mail message to ibr-dtn-request@ibr.cs.tu-bs.de !! or look at https://mail.ibr.cs.tu-bs.de/listinfo/ibr-dtn.