-
-
Notifications
You must be signed in to change notification settings - Fork 262
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug: Paired devices are not showing unless on same network #71
Comments
Is there simply a message or are they in fact not persistent? If you ever see the unpair button it means that the devices are persistent and it‘s a wrong error message. |
hm. Some more debugging shows the following: WS: {type: 'pair-device-initiated', roomSecret: '----', roomKey: '430048'}
network.js:66 WS: {type: 'peers', peers: Array(0), roomType: 'secret', roomSecret: '----'}
network.js:66 WS: {type: 'pair-device-joined', roomSecret: '----', peerId: '47016234-f559-4234-aae4-669f389a6eed'}
network.js:66 WS: {type: 'peer-joined', peer: {…}, roomType: 'secret', roomSecret: '----'}
ui.js:1766 Request successful. RoomSecret added: ----
ui.js:1697 This browser does not support IndexedDB. Paired devices will be gone after the browser is closed. The devices are indeed persisted through page load and browser close. And discovery happens while on different networks: ICE Gathering connected
network.js:655 RTC: state changed: connected
network.js:584 RTC: channel opened with 0c0cc604-1658-455c-a62b-4339f15215c7
network.js:597 RTC: {type: 'display-name-changed', displayName: 'Moiraine'}
network.js:597 RTC: {type: 'display-name-changed', displayName: 'Moiraine'}
network.js:66 WS: {type: 'peer-left', peerId: '47016234-f559-4234-aae4-669f389a6eed', roomType: 'ip', roomSecret: '', disconnect: false}
network.js:66 WS: {type: 'peer-left', peerId: '47016234-f559-4234-aae4-669f389a6eed', roomType: 'secret', roomSecret: '-----', disconnect: false}
network.js:66 WS: {type: 'peer-joined', peer: {…}, roomType: 'ip', roomSecret: ''}
network.js:66 WS: {type: 'peer-joined', peer: {…}, roomType: 'secret', roomSecret: '-----'} However the page shows no devices unless they are on the same network. My version: "3.3"
services:
server:
container_name: pairdrop
image: lscr.io/linuxserver/pairdrop
restart: unless-stopped
networks:
- nginx
ports:
- 127.0.0.1:3000:3000
environment:
- WS_FALLBACK=true
- PUID=1000
- PGID=1000
- RATE_LIMIT=false
- TZ=America/Chicago
- RTC_CONFIG=/rtc_config.json
volumes:
- ./rtc_config.json:/rtc_config.json
networks:
nginx:
external: true |
Sorry, as I started debugging things got muddied!
I’ll try the regular hosted one and see if it happens there! |
Hm. Same thing happens on the hosted version too. I wonder if it’s the local network blocking something? It is a school network. |
@schlagmichdoch thanks for debugging with me! I'll try this route. |
As an idea for the VPS, you could start with an oracle always free instance. They go up to 24gigs of RAM. But I think the bandwidth is limited per month. @schlagmichdoch |
Pairdrop with websockets enabled shouldn't require a TURN server? But still getting the same error |
I'm using my own pairdrop instance, websockets enabled. One browser with webrtc disabled, one browser with webrtc enabled (so it should use websockets). It's still getting that error. |
That's weird.. When both of your devices are on the same network and they are shown to each other, are they shown with a red border indicating the websocket fallback? Otherwise WebRTC would be used. |
Same network: WebRTC enabled: does work |
Okay, thanks a lot for checking back! That confirmes the current state, that the TURN server is broken but everything else works. I will have to look into why the error message about paired devices not being persistent is showing (are you using Firefox private tabs?). Otherwise your issue will be resolved as soon as the TURN server is up and running. |
I have since deployed a new TURN server for pairdrop.net that enables sending between devices that are behind different NATs. Does this resolve your issue @Robin-Sch ? @acupofjose Have you tried deploying your own TURN server? Try following this guide: https://gabrieltanner.org/blog/turn-server/ |
i just made a pull-request #106 for the docker-compose-coturn.yml with some changes around to get the turn, turns, stun and stuns working. Now you can deploy a pairdrop and coturn-server which are wired together (you still can use the coturn with other services too!). What's not working is to listen on port 443 for the turns coturn-part, because the nginx is listening there too.. Maybe this fixes this bug too... |
I still get the error when linking the two devices |
So you’re getting the error, that device pairing is not persistent. Does everything else work though? So is it a false warning? I guess the false warning about persistence is probably a different issue |
I get the error and it doesn't work, just like before Same network: WebRTC enabled: does work |
Have you specified a turn server? |
I'm getting the error also on the official instance (which has a turn server enabled?) |
I could reproduce your issue on chromium based browsers and debugged my turn server. Could you please test again whether the official instance does now work for you? I will then update the turnserver_example.conf to include the changes. Additionally, #106 will fix the possibility to host your turn server easily via docker-compose together with PairDrop. |
You can also try my server https://pairdrop.schuerz.at Coturn is listening for turns on port 443. |
Still gives the error, but it does connect |
If you want... i did some changes again... test against my instance. |
Thanks for testing @Robin-Sch ! About the problem with persistent storage on Google Chrome:
And only after the script has explicitly asked for permissions. I implemented this on #108 which is live on this test instance: https://pairdrop-persistence.onrender.com After enabling notifications (via the bell) or adding the page to your bookmarks, device pairing and name changing should work persistently. Would you please test one more time? |
WebRTC disabled (firefox): shows that pairdrop requires webrtc enabled to work.
|
good day I am seeing that I have the following problem in relation to all this: Scenario A is correct, scenario B is wrong: Scenario A: ScenarioB: I attach the screens with the scenarios: |
Please also test on https://pairdrop-persistence.onrender.com/, which is running with the following PR: #108 After enabling notifications (via the bell) or adding the page to your bookmarks, device pairing and name changing should work persistently. |
Hello, |
That's weird, because on that instance I got a different error: (see #71 (comment) ) |
@matiasperaltt I guess that was an issue with the TURN server. Thanks for reporting! Please test the official instance at pairdrop.net again. @Robin-Sch Is the pairing process on Google Chrome still not persistent for you using pairdrop.net? I cannot reproduce the issue on my machine anymore. |
It's working right now |
Hi all, i have the same issue. Pairdrop works fine with all devices in same network, but its doesn't work for different networks. I found the following error message in the developer options: @Robin-Sch: It works fine with your instance with devices in same and differents networks. I use the default configuration with Docker Compose. Any ideas? |
Hi @schlagmichdoch, thank's for the reply. |
The following comments were deleted by GitHub (via hubot) as part of mistakenly marking this account as spam on 17th February 2024. The correct thread order and the creation date is unclear. I decided to manually restore them anyway in order to complete the information this issue holds even though the restored information might be outdated: Comment by @schlagmichdoch:thanks for the additional information!
Not sure whether I understand correctly. When you are on different networks and the devices are not visible to each other, is this unique to the Chrome PWA or is this the case for all browsers of the device? Are the devices becoming visible to each other when you pair them again? If not, that's probably a different issue with your specific network constellation. As you are self-hosting:
Comment by @schlagmichdoch:So after writing the following debugging instruction, to check how to find out that something is not working, I tested it myself and found out that the free public TURN server seems to be down for now I'm afraid. I also believe it's likely that it will not come up again. That means that connections between devices behind different NATs are not possible with the default settings right now 😞 Of course you can easily setup your own TURN server and specify to use it via the As a workaround for As this quota will not be enough for all PairDrop users by far, I will setup an official TURN server on a VPS soon. Big advantages are that the speed for these relayed connections will increase a lot and that will be under PairDrops control. Disadvantage is the cost: With the smallest RAM It will create additional costs of 30-40 € per year. Would appreciate any support. Your new info confirms what I thought: It has nothing todo with the PWA or the specific browser but with the network. Your devices must be able to create webrtc connections. You can check here: https://www.webrtc-experiment.com/DetectRTC/#isWebRTCSupported (under Addionally you must be able to connect to the given stun servers. If there is no NAT between you devices googles STUN server ( Comment by @schlagmichdoch:@Robin-Sch the websocket fallback is only used if one of the two devices does not support WebRTC as is the case on some vpn connections. In your case WebRTC seems to be supported by both devices but the connection fails as the turn server is not reachable. If you want the fallback to be used additionally if the rtc connection fails i would appreciate if you would create another issue as a feature request @marcogreiveldinger thanks for the suggestion! I will look into it. I’m not sure though about the bandwidth limit. If many more people are using pairdrop.net in this device constellation 1 TB bandwidth per month is not much. 1 TB is only 1000 users sending 1 GB of files or 100000 users sending 10 MB of files. Even now, without any data relaying, 100GB per month will soon not be enough. So probably I will get some VPS without any bandwidth limit I need to worry about. I have sth in mind but need to check some reviews first :) Comment by @schlagmichdoch:@Sschhsd FYI: Have you deployed a TURN server? This is needed for some connections across networks. The new documentation includes a step-by-step guide how to deploy a TURN server alongside PairDrop via docker compose If you have any questions regarding that, feel free to open a new issue |
Describe the bug
I get the error "Paired devices are not persistent." when attempting to link two instances that have been installed as a Chrome PWA.
In the Console it says: "This browser does not support IndexedDB. Paired devices will be gone after the browser is closed."
To Reproduce
Expected behavior
Desktop (please complete the following information):
Self-Hosted
Yes
Self-Hosted Setup
Proxy: Nginx Proxy Manager
Deployment: docker-compose
The text was updated successfully, but these errors were encountered: