Android adb wireless/WIFI debug Operation timed out

14,890

Solution 1

Make sure your computer and the android device are using the same wifi network. I had the same issue and fixed it after changing to the same wifi.

Solution 2

I think this might help...

for windows run cmd from "As Administrator" then

netsh int ip reset

For Mac users

  1. Click the Apple icon in the top left-hand corner and then select System Preferences from the drop-down menu.

  2. Select Network.

  3. Select your Connected internet connection (Ethernet or Wi-Fi) and then click Advanced.

enter image description here

  1. Select the TCP/IP tab and then click Renew DHCP Lease. And press Ok

enter image description here

Solution 3

So after a huge number of trials, I think the problem is somehow wifi related, I think this feature does not work well with WPA2 (or any kind of?) Enterprise encryption, because I was using my school Wifi, and it turned out to be okay, up and running, for the hotspot I set up with another laptop.

Solution 4

What solved this for me:

  • disconnect the phone from USB cable
  • restart the phone
  • reconnect the phone by USB cable

(meanwhile):

  • adb kill-server
  • adb start-server

Then follow the "standard" procedure.

Solution 5

If you are connected on same network and still can't connect then check your IP twice . Sometimes it get changed. check your IP = phone settings -> About phone -> Status -> IP address

Share:
14,890

Related videos on Youtube

TPWang
Author by

TPWang

Just me.

Updated on June 06, 2022

Comments

  • TPWang
    TPWang almost 2 years

    I followed steps in this post and tried to connect to my Motorola X Gen 2 for Wifi debugging, on OS X El Cap.

    I connected my phone to the laptop with usb cable, I killed and started server, the server was started successfully, and then in:

    ./adb devices
    

    I got

    List of devices attached
    TA44909GA0  device
    

    Then I did

    ./adb tcpip 5555
    

    And I tried

    ./adb connect <IP addr of my phone>:5555
    

    both with usb cable connected and disconnected, none of them worked. Both returned error message saying:

    unable to connect to ***.***.***.***:5555: Operation timed out
    

    I cannot figure out what is happening here, I tried the Android Studio plugin ADB WIFI, which returned the same message, operation timed out. I restarted everything, tried connecting with a different cable and all, nothing worked.

    Does anyone know what's happening here?

    • Alex P.
      Alex P. over 8 years
      make sure that AP isolation is off on your wifi router
    • TPWang
      TPWang over 8 years
      I don't think that's the problem, it worked once, just once, the day before, and the next day it went back to "operation timed out". (And I am using my school wifi, so probably the setting didn't change)
    • shiladitya
      shiladitya over 8 years
      Any solution to this?
    • TPWang
      TPWang over 8 years
      Not net. Restarting ./adb and phone and wait for a couple of hours would get it to work for a while. I'm suspecting it's hardware problem. Probably not good for this site...
    • Shamm
      Shamm over 8 years
      Really, "adb reboot" (will restart your device) worked for me.
    • Tim
      Tim almost 8 years
      Make sure you are not in any VPN network
    • AA_PV
      AA_PV over 7 years
      Doesn't work for me. Same network, not on VPN, restarted adb, restarted phone, still nothing. I'm not sure about AP isolation, but I'll live with the intermittent usb for now and focus on the app
    • TPWang
      TPWang over 7 years
      @AA_PV It's better not to use it with a router that has a firewall itself, e.g. those ones that you need admin password to log in.
  • AweSIM
    AweSIM over 7 years
    same thing happened to me.. my machine and device were connected to different wifi routers in my home.. =) =P
  • R. Zagórski
    R. Zagórski over 7 years
    This does not provide an answer to the question. Once you have sufficient reputation you will be able to comment on any post; instead, provide answers that don't require clarification from the asker. - From Review
  • Petter Friberg
    Petter Friberg over 7 years
    @R.Zagórski this seems like an answer "your computer and the android device needs to use the same wifi network"
  • Saik Caskey
    Saik Caskey almost 6 years
    You should explain how this works, as it worked for me and I have no idea, and if anyone asks I tell them not to just follow instructions from the internet.. but it worked so..
  • Luka Bradeško
    Luka Bradeško over 3 years
    Just the kill/start on it's own is often enough
  • haridsv
    haridsv about 3 years
    This made no difference for me.
  • haridsv
    haridsv about 3 years
    I have one router at home and both my MBP and FireTV are connected to the same SSID, but I could neither ping the IP or connect via adb. When I had both connect to my mobile hotspot, it worked fine.
  • AEB
    AEB over 2 years
    This saved my day. Thanks. Additionally, a little bit of descriptive explanation would be better.