Poor Battery Life Due To Constant Btsync Queries?


heymoe

Recommended Posts

I'm currently using BTSync to sync photos and other files on my mobile android devices to my Windows laptop and a home server running Linux.

 

I'm running BTSync v1.3.93 on the Windows laptop and Linux server and v1.3.20 on Android. 

 

I noticed that my battery life on my Android device was really bad when I was connected to my home WiFi network due to excessive wlan_rx_wake wake locks. Basically these wake locks keep my Android device from going into deep sleep / low battery consumption mode. If I disconnected from WiFi and went back to 4G the wake locks stopped and battery drain would go back to more reasonable levels.

 

Doing some packet sniffing I found that BTSync on my laptop and home server were sending UDP packets to the IP of my Android device even though BTSync on my Android device was not running. I confirmed that if I shutdown BTSync on my laptop and home server that these UDP packets would stop. Once these UDP packets stopped, the number of wlan_rx_wake wake locks went down significantly and my Android device was able to stay in deep sleep mode.

 

The WiFI network (bridged) and the Lan network that my laptop and home server are connected to are on the same subnet.

 

I noticed that if I changed the IP of my Android device while BTSync was running on my laptop and home server that my Android device would stop receiving these UDP packets but I could see from the packet sniffing that my laptop and home server were still trying to send those packets to the old IP. If I start BTSync on my Android device on this New IP, let things sync up and then shut it down again, the UDP packets from my laptop and home server start hitting the new IP. 

 

My guess is that BTSync on my laptop and home server are just trying to reconnect with my Android device even though I turned BTSync off on that device but it seems that this constant "hey are you there now" UDP packets are keeping my Android device awake because it has to respond to any packet directed to its IP (not broadcast). 

 

The main Android device I've been testing this with is an LG G2 running Android 4.4.2. 

 

Any thoughts on this?

Link to comment
Share on other sites

  • 2 weeks later...

Just an update: It would seem that BTSync v1.3.94 has corrected non-stop flood of UDP packets to the IP of a shutdown client. Based on my packet capture after updating my Windows and Linux server to v1.3.94, the UDP traffic continues for about 1 mins after I shutdown my Android client and then stops. My Android device is now able to stay in deep sleep mode while connected to WiFi thus my battery drain is back to reasonable levels. Thanks!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.