这是我的步骤:
adb connect '我的安卓 IP 地址'
连接的
adb reboot //在这一步中,我的手机正在重启并且进程挂起。
可能是什么问题,是否有任何修复或解决方法?
当我使用 USB 电缆处理 ADB 时,它运行良好。
谢谢
Somewhat speculation, but adb reboot
may shut the phone down abruptly enough that the ADBD on the phone never gets to properly close the TCP connection to the ADB server on your development machine. This would be a lot like the way "hung" TCP connections can result from pulling out a network cable - TCP is designed to survive intermittent communication failures, and so doesn't give up on the possibility of the other end answering until a fairly substantial amount of time (in human terms) has passed.
It's entirely plausible that the ADB server isn't written to take into account the combination of two features which are even individually a bit on the obscure side - TCP connection with rebooting.
If that is the case, your practical options may be to have something kill the ADB server immediately after issuing the reboot, or else modify ADB (it's open source after all) to more intelligently handle this, for example automatically disconnecting after a second or two of non-response if it has issued a reset command.