I have enabled wireless debugging on my android phone and connected it with a linux machine. But after few minutes or hours i have to re-enable the wireless debugging to keep connected.

When running adb connect i am getting Device refused to connect error. So i have to connect my phone again with usb and give permission for wireless debugging. Which i am doing with below commands

adb tcpip 5555
adb connect

I am on android 12 and arch linux. One more thing i want to share is, in wifi settings randomized mac-address is enabled, i have no idea if this is the reason or not.

If this is how wireless debugging works than is there a way to keep your device connected to adb with wireless-debugging without getting permissions provoked.

  • "randomized mac-address is enabled, i have no idea if this is the reason or not" - please rule this out first
    – alecxs
    Apr 22 at 22:38
  • @alecxs i will try but my permissions are provoked randomely so i don't know when my permissions will be provoked again. So it may take some time to update question
    – tycoon
    Apr 23 at 5:31
  • @alecxs while going throgh developer options i found disable adb authorisation timeout according to it if not connected for a time period (default 7 days) permissions will be revoked. So maybe this is the reason.
    – tycoon
    Apr 23 at 5:37
  • 1
    @alecxs for now i have disabled randomize mac address, if i get the same issue again i will update
    – tycoon
    Apr 23 at 7:51


You must log in to answer this question.

Browse other questions tagged .