How to restart ADB manually from Android Studio

后端 未结 11 734
星月不相逢
星月不相逢 2020-11-28 05:59

I previously developped Android apps on Android Studio . Everything works fine.

I work on real device, and Android Studio recognize it without issue.

Suddenl

相关标签:
11条回答
  • 2020-11-28 06:16

    I faced same issue just fallowed some min steps in Android studio:

    Manually fallowing steps in android studio

    1. Goto Command promt and in Command promt fallow a android SDK file path "android sdk>platform-tools>" adb kill-server press enter
    2. adb start-server press enter

    -------------------------------------------------OR-----------------------------------------------------------------------

    1. Open Command promt and got android sdk file path adb kill-server && adb start-server
    0 讨论(0)
  • 2020-11-28 06:19

    AndroidStudio:

    Go to: Tools -> Android -> Android Device Monitor

    see the Device tab, under many icons, last one is drop-down arrow.

    Open it.

    At the bottom: RESET ADB.

    0 讨论(0)
  • 2020-11-28 06:20
    1. Open a Task Manager by pressing CTRL+ALT+DELETE, or right click at the bottom of the start menu and select Start Task Manager. see how to launch the task manager here

    2. Click on Processes or depending on OS, Details. Judging by your screenshot it's Processes.

    3. Look for adb.exe from that list, click on END PROCESS

    4. Click on the restart button in that window above. That should do it.

    Basically by suddenly removing your device ADB got confused and won't respond while waiting for a device, and Android Studio doesn't want multiple instances of an ADB server running, so you'll have to kill the previous server manually and restart the whole process.

    0 讨论(0)
  • 2020-11-28 06:20

    Open task manager and kill adb.exe, now adb will start normally

    0 讨论(0)
  • 2020-11-28 06:27

    open cmd and type the following command

    netstat -aon|findstr 5037
    

    and press enter.

    you will get a reply like this :

      TCP    127.0.0.1:5037         0.0.0.0:0              LISTENING       3372
      TCP    127.0.0.1:5037         127.0.0.1:50126        TIME_WAIT       0
      TCP    127.0.0.1:5037         127.0.0.1:50127        TIME_WAIT       0
      TCP    127.0.0.1:50127        127.0.0.1:5037         TIME_WAIT       0
    

    this shows the pid which is occupying the adb. in this 3372 is the value. it will not be same for anyone. so you need to do this every time you face this problem.

    now type this :

    taskkill /pid 3372(the pid you get in the previous step) /f
    

    Voila! now adb runs perfectly.

    0 讨论(0)
提交回复
热议问题