Warning: No DNS servers found

Common bugs/problems with the Android SDK the Emulator and the ADT-Plugin.

Warning: No DNS servers found

Postby darolla » Thu Oct 09, 2008 11:28 am

Hi,

I am using KDE Linux and Android and Eclipse.

Starting Android under Eclipse throws this error: "Warning: No DNS servers found".

The effect is that I cannot use neither Android browser nor maps.

I started to google on that topic and found only this:

Troubleshooting Emulator Problems

The adb utility sees the emulator as an actual physical device. For this reason, you might have to use the -d flag with some common adb commands, such as install. The -d flag lets you specify which of several connected devices to use as the target of a command. If you don't specify -d, the emulator will target the first device in its list. For more information about adb, see Android Debug Bridge.

For emulators running on Mac OS X, if you see an error "Warning: No DNS servers found" when starting the emulator, check to see whether you have an /etc/resolv.conf file. If not, please run the following line in a command window:

ln -s /private/var/run/resolv.conf /etc/resolv.conf

See Frequently Asked Questions for more troubleshooting information.


Well, now I get other problems.

First of all I start Android inside Eclipse.

On commandline I enter "adb shell".

"ln -s /private/var/run/resolv.conf /etc/resolv.conf" doesnt work because:

"link failed Read-only file system".

What can I do now?

Help !!!
User avatar
darolla
Master Developer
Master Developer
 
Posts: 273
Joined: Thu Sep 25, 2008 5:16 pm
Location: Dortmund, Germany

Top

Postby darolla » Thu Oct 09, 2008 11:39 am

I just created a textfile called resolv.conf and copied it to /data/system.

That did the trick.

:D
User avatar
darolla
Master Developer
Master Developer
 
Posts: 273
Joined: Thu Sep 25, 2008 5:16 pm
Location: Dortmund, Germany

Postby ninor » Thu Oct 09, 2008 5:27 pm

:D
Image AndDev: Your Android Development Community / Tutorials | Here's my Basic ToolKit
User avatar
ninor
Moderator
Moderator
 
Posts: 180
Joined: Thu Aug 14, 2008 6:30 pm
Location: Barcelona, Spain

What I have to do next

Postby bobrowley » Fri Oct 10, 2008 8:59 am

Hi, I copied the resolv.conf to /data/system/ folder, but is still can't find the DNS server. What I have to do next?

Thanks.
bobrowley
Once Poster
Once Poster
 
Posts: 1
Joined: Fri Oct 10, 2008 8:29 am

Postby darolla » Wed Oct 15, 2008 1:28 pm

well, somehow it isn't working anymore...

I think the error in my case is inside the conf file:

nameserver 192.168.0.2

I think Android cannot connect to this private class C network...

Who can help ?

Greetings,
Marco
User avatar
darolla
Master Developer
Master Developer
 
Posts: 273
Joined: Thu Sep 25, 2008 5:16 pm
Location: Dortmund, Germany

Postby niteshnema » Thu Jul 16, 2009 4:52 pm

I am using Windows Android emulator.
It was working fine for last 2 days. I was behind proxy and set proxy in Wireless Settings(APN).
Now when I am launching emulator APN, which was created got vanished. And I am getting DNS error:


C:Documents and Settingsnitesne>emulator -avd nitesh_avd
Warning: No DNS servers found


I tried the solution provided in developer site of Android, but getting same error...

D:Androidandroid-sdk-windows-1.5_r2tools>adb shell
# ln -s /private/var/run/resolv.conf /etc/resolv.conf
ln -s /private/var/run/resolv.conf /etc/resolv.conf
link failed Read-only file system


Is anyone got the solution? One solution I suspect that I have to delete Android SDK folder and re-Unzip the SDK.
niteshnema
Once Poster
Once Poster
 
Posts: 1
Joined: Thu Jul 16, 2009 4:43 pm

Top

Return to SDK/ADT/Emulator Problems

Who is online

Users browsing this forum: Google Feedfetcher and 3 guests