-->
Page 1 of 1

DNS Lookup kills board

PostPosted: Sun Nov 30, 2014 11:46 am
by scargill
This is if I recall correctly the innards of one of the demo functions - without the function call - to get a DNS lookup.

sk=net.createConnection(net.TCP, 0)
sk:dns("www.bbc.co.uk",function(conn,ip)
print(ip)
end)
sk = nil

Instead of addr I've actually put the address in of a website.

If you run this maybe 10 times in a row - it forces the board to reboot.

Re: DNS Lookup kills board

PostPosted: Sat Dec 06, 2014 11:01 am
by GeoNomad
I have resolved some net. reboot issues by adding a net.close() here and there.

I suspect there are open connections waiting for a response sometimes.

I have seen the DNS FAILED! response, but not that often, even when DNS did fail.

What are the timeout parameters on the net functions? Can we change them?