• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Help Milestone not getting IP address from Wifi

rt_hat

Lurker
Apr 13, 2010
5
0
I'm having trouble with Wifi connectivity on my Milestone. This has happened at several different open Wifi hotspots, so not just at home. The hotspots seem okay, because I can connect through my laptop. Just not through the phone.

When I connect to an AP, and I go to the Wifi settings, it shows me as Connected to that AP. However the phone does not get an IP address. I can tell because I go to the Wifi Settings and click on that AP and it shows me as connected along with the signal strength, but there is no IP address entry. I've tried :
- restarting the phone
- forgetting the AP and re-adding it

This problem started showing up in the last month or so. I'm thinking probably when I got the phone updated to that 2.1-update1 on my phone's network.

Any ideas on what is going on ? I have a Milestone running 2.1-update1 on the Rogers network.
 
I'm having trouble with Wifi connectivity on my Milestone. This has happened at several different open Wifi hotspots, so not just at home. The hotspots seem okay, because I can connect through my laptop. Just not through the phone.

When I connect to an AP, and I go to the Wifi settings, it shows me as Connected to that AP. However the phone does not get an IP address. I can tell because I go to the Wifi Settings and click on that AP and it shows me as connected along with the signal strength, but there is no IP address entry. I've tried :
- restarting the phone
- forgetting the AP and re-adding it

This problem started showing up in the last month or so. I'm thinking probably when I got the phone updated to that 2.1-update1 on my phone's network.

Any ideas on what is going on ? I have a Milestone running 2.1-update1 on the Rogers network.

If connected it should be showing a IP. There is no way to connect to a router with out having it pull an IP. For security what does it say?

Example Below

Staus=connected
Speed=54mbs
Signal strength=excellent
Security=WPA/WPA2 PSK
IP Address=192.168.*.*

In this case * can = any number

Sometimes the security protocol does prevent the connection of a device if the device does not support the security protocol that the router is currently using.
 
Upvote 0
If connected it should be showing a IP. There is no way to connect to a router with out having it pull an IP. For security what does it say?

Example Below

Staus=connected
Speed=54mbs
Signal strength=excellent
Security=WPA/WPA2 PSK
IP Address=192.168.*.*

In this case * can = any number

Sometimes the security protocol does prevent the connection of a device if the device does not support the security protocol that the router is currently using.

It shows everything but the IP Address entry. For the security stuff, even connecting to open networks gives the same results. From your example, it shows everything but the IP Address entry. Very strange huh ?

Static IP is not enabled.
 
Upvote 0
I am having the same issue. When I click on the AP that I am connected to, I see all the other info, but the line containing the IP address that is being talked about here is missing. I am running Android 2.1 on my Motorola Milestone (Telus).

Any thoughts would be greatly appreciated.

Cheers,

-f.
 
Upvote 0
Here's some pictures. One is from the Android Wifi settings, the other is from the ipconfig app. Also, this is the stock Android 2.1 system on the Motorola Milestone.

The wifi connection still works (can browse the web, go on the market, do everything), it's just that IP does not show up. This is at a hotel, so I can't check on the access point to see what IP address was assigned. But it happens on pretty much any wireless network I join.

It's good to see that I'm not the only one.
 

Attachments

  • IMG_0183.JPG
    IMG_0183.JPG
    24.4 KB · Views: 81
  • IMG_0184.JPG
    IMG_0184.JPG
    20.6 KB · Views: 79
Upvote 0
I thought I was occasionally getting this a couple of weeks ago. It turned out that I was getting an IP address, but no DNS addresses. Therefore I couldn't use anything on the internet that needed a domain name resolving.

There are two main wifi networks I use (home and work), and the problem seemed to be when I swapped between them. Since I tracked it down to a DNS issue though, I've been keeping an eye on it, and, of course, it has worked perfectly ever since!

The NetInfo app is the best thing I've found for checking the settings.

STM
 
Upvote 0
Yes - this has been annoying me for some time. The problem went away when I deleted some applications. So I decided to get to the bottom of it.

My symptoms were:
* When connecting via wifi, the IP address would be set to OK but the Domain Name Server would not. So when I tried to access the internet it would get "Host not found page".

I have a rooted Milestone (2.1-update1) with busybox installed so I put some debug in the dhcpcd rc scripts - dhcpcpd is started up on wifi connect and gets the network config from your DHCP service (usually your router). It sets a number of android properties, one of them being the dns servers. On my milestone device the command run by /system/etc/dhcpcd/dhcpcd-hooks/20-dns.conf for my home network is:

setprop dhcp.tiwlan0.dns1 192.168.0.60

Thing is when you watch the properties with watchprop or do a getprop for that property it was not set.

Similarly setting the property on the command line did not work. It gave a zero return code but when you did getprop it wasn't there.

The big clue is that if you run:
getprop | wc -l
you get 247 as the number of properties.

[Excellent article here about properties: just do IT: android property system ]

It turns out that the number of system properties is hard a limit at 247 and then any subsequent set or properties that do not exist will just be ignored.

The boot sequence does not ordinarily create properties for the dhcp process - they are created on first usage - ie when you turn the wifi on.

So, the fix is to create the very important dhcp property early. You can do this by editing your /data/local.prop file to create the dns property before the 247 property limit is reached.

So on mine I have the following at the top of my /data/local.prop file:
dhcp.tiwlan0.dns1=

Reboot your phone and all is now well.

The entry is just a dummy entry for my WiFi interface (tiwlan0). You would need to find out what your wifi interface is. Use:
ip link
to get your devices.

Only gotcha with this is that I have not solved the real problem - number of properties limitted to 247 - so I still have some properties not being set properly. My system is locked by Motorola so I cannot hack the code but maybe they will have it fixed in the next release (when it finally arrives;-)

Good luck.

Tony Jewell
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones