After the system is reinstalled and ADT (ADT-bunlde-Windows) is used, a ddms initialization error always occurs, and logcat cannot obtain the log. The error message is:
Failed to initialize Monitor thread: unable to establish loopback connection
The actual problem is that the ADB process cannot be started. The following error message is displayed when you use ADB devices on the command line:
* Daemon not running. Starting it now on port 5037 *
ADB server didn't ACK
* Failed to start daemon *
Error: cannot connect to Dae
There are several solutions available on the Internet:
1. Disable Windows Firewall;
2. Disable IPv6 or set IPv4 preferences. Specifically, in "Device Manager", the hidden devices are displayed, and a network device starting with "Teredo" is disabled; in eclipse. add INI file (parameters of the last line)
Openfile
-Vmargs
-Djava.net. preferipv4stack = true
3. Disable virtual network adapters (virtual network adapters created by VMware and virtualbox );
I did step 2 and Step 3 and did not succeed. I had to do step 1. The problem was solved, ddms started, and logcat rolled. However, it is strange to close the firewall and start the firewall again. However, during the secure period, the firewall is still started and an exception rule is added to the firewall,
The rule is simple, that is, to allow all communications on the port 5037, there are still security risks, but it is better to disable the firewall. Of course, you can also restrict programs to reduce security risks.