equalitie / ouisync

A secure peer-to-peer file synchronization app.
https://ouisync.net
Mozilla Public License 2.0
36 stars 9 forks source link

Extremely slow transfer on LAN #174

Open Juul opened 2 months ago

Juul commented 2 months ago

Running ouisync-app 0.8.0 and latest ouisync-cli from git as of August 1st 2024 (commit 83578550713068dc32e006d202550688c003936a) with no docker involved. Ubuntu 20.04 and latest stable de-googled GrapheneOS.

A repo was created using ouisync-cli, a single file of about 230 MB was added and the repo was shared with the android device in write mode.

The repo appeared correctly on android and the circle of two arrows icon appears next to the repo or in the top menu bar after clicking the repo but the icon was flashing unpredictably (generally faster than once per second). After a couple of minutes of this flashing the filename of the only file in the repo appeared with 0.1 MB showing as having been transferred. The flashing continued and over 10 minutes later it showed that 0.2 MB had been transferred. Clicking the three vertical dots to the top right when inside the repo showed "Synced: 0%".

About 5 mins later the circular progress indicator suddenly appeared and began increasing in size. the "Synced: %" display began updating as well. After this happened it still took about 10 minutes for the 230 MB to transfer. This comes out to about 3 Mbps. The wifi should be capable of at least hundreds of Mbps. As soon as the file finished transferring I ran a fast.com speedtest through firefox on the same android device and got a result over 500 Mbps down and over 300 Mbps up.

ouisync-cli debug output and both ouisync-cli and ouisync-app peer lists confirms connection is happening over LAN and only over LAN.

Cache servers were disabled for the repo in ouisync-app

As a side note, the small text with <x>/<y> MiB under the filename that shows how much has been transferred only ever made it to 0.2/230 MiB until it finished downloading but that seems to be an unrelated bug.

Juul commented 2 months ago

I should note that I also tested this with a ouisync-cli that I compiled from latest git on July 11th so this bug was already present then.