Sunday, September 4, 2022

[SOLVED] emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused

Issue

Emulator has stopped working on Fedora 21 starting 3.18 and 3.19 kernels. API 21 emulators don't boot they are stuck with black screen. Any pointers to resolve this issue would be much appreciated.

emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused
emulator: ASC 127.0.0.1:1970: Retrying connection. Connector FD = 26
emulator: Error while connecting to socket '127.0.0.1:1970': 111 -> Connection refused

Solution

The patch that fixes it has been accepted upstream. Workaround is still available.

Intel dev's workaround quoted from the issue.

I cannot speak for Google, who decides when to issue a new release of the emulator (SDK Tools). But for people who need this fix now, it is possible to manually apply it to their Android SDK installation:

  1. Download the attached bios.bin. It is the same file that I just uploaded to https://android-review.googlesource.com/159501 (still under review). To download from the review, use the following link instead:
    https://android-review.googlesource.com/cat/159501%2C1%2Cx86/pc-bios/bios.bin%5E0

  2. Make a backup of $ANDROID_SDK_ROOT/tools/lib/pc-bios/bios.bin ($ANDROID_SDK_ROOT is the Android SDK installation directory).

  3. Copy the downloaded bios.bin to $ANDROID_SDK_ROOT/tools/lib/pc-bios/.



Answered By - Sudhir Singh Khanger
Answer Checked By - Gilberto Lyons (WPSolving Admin)