
Hello, IBR-DTN developers and users!
I suspect that IBR-DRN does excessive work on copying files while doing dtnrecv.
Here is what I do. 1. On the node2 I start dtnrecv --file /var/tmp/1.iso --name file 2. On the node1 I start dtnsend dtn://node-2.dtn/file /media/1.iso
Then in another console on node2 I look, what does IBR-DTN do. 1. It stores the data, received, from node1 to a blob file in /var/spool/dtnd/blobs/ 2. Than it copies that blob file to a bundle file in /var/spool/dtnd/bundles/ 3. Than it copies the bundle file to the destination file /var/tmp/1.iso
Steps 1 and 2 look ok to me. But why use bit-by-bit copy on step 3 instead of just move (mv) the bundle file to the destination file without the expensive data transfer? This excessive data copying consumes memory to store the whole bundle and takes more time.
My node2 has 2Gb RAM. The file that I send (1.iso) is 1.2Gb. RAM gets exhausted on the step 3, and dtnrecv fails with error message "Aborted".
So I have two proposals. 1. Implement better error reporting, e.g. "Not enough memory to copy file." instead of "Aborted." 2. Move bundle file to the destination file instead of copying it.
------------------------------------------------------------------------------------------------------------------------------- My IBR-DTN config: local_uri = dtn://node-2.dtn logfile = /var/log/ibrdtn.log timezone = +4 limit_blocksize = 0 user = dtnd blob_path = /var/spool/dtnd/blobs storage_path = /var/spool/dtnd/bundles limit_storage = 5G discovery_announce = 0 net_interfaces = eth0 net_rebind = yes net_autoconnect = 60 net_eth0_type = tcp net_eth0_interface = eth0 net_eth0_port = 4556 net_eth0_discovery = yes routing_forwarding = yes static1_address = 192.168.150.38 static1_port = 4556 static1_uri = dtn://node-1.dtn static1_proto = tcp static1_immediately = yes dht_enabled = yes dht_bootstrapping = yes
Best Regards, Sergey Syreskin