please include function dm_sendFileToOtherMachine. // for chunkSize svoid dm_retrieveFileFromOtherMachine(S computerID, S remotePath, File f) { backupFile(f); long size = toLong(dm_evalOnOtherMachine(computerID, "fileSizeOrMinus1(fileRelativeToUserDir(" + quote(remotePath) + "))"); if (size < 0) { if (f.exists()) print("Deleting file: " + f); ret; } for (LongRange r : chunks(size, dm_sendFileToOtherMachine_chunkSize)) { print("Retrieving file chunk " + r + " of " + computerID + ":" + remotePath + " to " + f); byte[] chunk = cast dm_evalOnOtherMachine(computerID, "loadBinaryFileChunk(fileRelativeToUserDir(" + quote(remotePath) + "), " + r.start + "L, " + r.length() + ")"); saveBinaryFilePart(f, r.start, chunk); } truncateFile(f, size); print("File retrieved: " + f); }