zeroconf - jmDNS /etc/resolv.conf IO error

Problems with WiFi, SQLite ,Bluetooth, WiMax, Proxies, etc...

zeroconf - jmDNS /etc/resolv.conf IO error

Postby peterkirn » Thu Dec 10, 2009 2:38 pm

I'm trying to work with zeroconf, but I'm stuck on an IOException I hit when initializing the JmDNS library.

Excerpts from the exception:

Code: Select all
12-10 08:31:05.044: WARN/javax.jmdns.JmDNS(19087): Initializing JmDNS with null address an name of 'computer'
12-10 08:31:05.083: WARN/System.err(19087): org.jmdns.api.DiscoveryException: io error instantiating jmdns
12-10 08:31:05.146: WARN/System.err(19087): Caused by: java.io.IOException: Error running exec(). Commands: [grep, nameserver, /etc/resolv.conf] Working Directory: null Environment: null
12-10 08:31:05.146: WARN/System.err(19087): Caused by: java.io.IOException: Permission denied


I'm definitely using working initialization code, and yes, I have given the application the INTERNET permission (other networking is working without issue as a result).

It appears that it's not able to access /etc/resolv.conf, which is odd -- I've seen a smattering of other complaints about this. Any ideas?

Incidentally, I did find a nice wrapper that makes invoking Java mDNS easier:
http://www.offthehill.org/articles/tag/mdnsresponder/

Naturally, jmdns is the way to go, as Apple's Bonjour library relies on JNI.
http://peter.noisepages.com
developing art + music apps for android
peterkirn
Freshman
Freshman
 
Posts: 3
Joined: Mon Nov 16, 2009 7:30 pm
Location: New York, NY

Top

Postby steff@MA » Thu Jan 07, 2010 9:43 pm

Hi there,

did you make any progress? I'm kindda stuck with JmDNS as well.

Everything compiles just fine but not a single listener responds to anything. They just keep doing nothing.
Btw, this might even be a handset issue (in my special case). I stumbled upon Tunes Control. Service discovery did not work at all. When I typed in the IP manually everything worked fine. This happens on a Motorola Milestone (the EU version of the Droid). But discovery should work for most other users since I didn't find anything in the app comments on the market...

Thanks for any comments.
steff@MA
Junior Developer
Junior Developer
 
Posts: 20
Joined: Fri Nov 27, 2009 5:14 pm

Top

Return to Networking & Database Problems

Who is online

Users browsing this forum: Yahoo [Bot] and 4 guests