Unable to run 'adb': null
首先,打开命令行工具,查看失败信息中提示的端口是否被占用(比如我这边提示的是5037) netstat -ano | findstr :5037
如果端口被占用,在任务列表中找到占用端口的进程(可在上一步中查看) tasklist | findstr processID
关闭占用这个端口的程序,然后运行命令手动启动adb,成功 adb start-server
21:20 Unable to run 'adb': null 21:20 'E:\AndroidSDK\platform-tools\adb.exe start-server' failed -- run manually if necessary 21:20 error: cannot open transport registration socketpair: Invalid argument 21:20 This application has requested the Runtime to terminate it in an unusual way. 21:20 Please contact the application's support team for more information. 21:20 could not read ok from ADB Server 21:20 * failed to start daemon * 21:20 error: cannot connect to daemon
adb无法连接,出现如上日志文件
解决方法:
windows 10环境下关闭防火墙即可
试了一下果然就行了