Micromax Yureka: Indian Handset with CyanogenMod

Thesoap opera involving Cyanogen Inc., OnePlus, and Micromax is one of the most talked about … more

Chainfire Turns Your Bootanimation into a Logging Center

Having a nice boot animation certainly adds a little bit of aesthetic polish to your … more

Android TV Launcher Pushed to Google Play

Over the past decade, the tech universe has seen two drastic and widely contrasting changes with … more

Cyngn, OnePlus, Micromax – The Legal Battle

Recently, a battle has been waging in India over the rights to distribute the commercial … more

Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
Post Reply

no route by dhcp - flock dhcpcd-wlan0.pid

OP 41.kretschi

6th March 2014, 10:42 AM   |  #1  
Hi guys,
I have a problem with my wifi connection:
it's connecting and receiving the ip address by dhcp but no route is beeing set. It happens with different routers and wifi networks, so its not a router problem. also with my notebook I can connect to it regularly and everything works fine.
On my phone I have to set the route by hand afterwards - it's the only fix I found so far.
I do it by redoing the dhcp process and I have to do it twice. I don't really understand the problem dhcpcd has the first time but maybe that's the problem why no route is being set in the first place.

Code:
root@serranolte:/ # dhcpcd wlan0
dhcpcd[12685]: flock `/data/misc/dhcp/dhcpcd-wlan0.pid': Try again
1|root@serranolte:/ # dhcpcd wlan0
dhcpcd[12706]: version 5.5.6 starting
dhcpcd[12706]: wlan0: rebinding lease of 10.126.49.136
dhcpcd[12706]: wlan0: NAK: requested address not available from 1.1.1.1
dhcpcd[12706]: wlan0: broadcasting for a lease
dhcpcd[12706]: wlan0: offered 10.126.49.97 from 1.1.1.1
dhcpcd[12706]: wlan0: acknowledged 10.126.49.97 from 1.1.1.1dhcpcd[12706]: wlan0: checking for 10.126.49.97
dhcpcd[12706]: wlan0: leased 10.126.49.97 for 14400 seconds
dhcpcd[12706]: forked to background, child pid 12749
root@serranolte:/ #
I also took a look at the dhcpcd.conf and the hooks files. the properties are not being set. is this an issue? maybe you guys know how to fix this.

Code:
root@serranolte:/ # getprop | grep dhcp
[dhcp.wlan0.dns1]: []
[dhcp.wlan0.dns2]: []
[dhcp.wlan0.dns3]: []
[dhcp.wlan0.dns4]: []
[dhcp.wlan0.domain]: []
[dhcp.wlan0.gateway]: []
[dhcp.wlan0.ipaddress]: []
[dhcp.wlan0.leasetime]: []
[dhcp.wlan0.mask]: []
[dhcp.wlan0.mtu]: []
[dhcp.wlan0.pid]: [30155]
[dhcp.wlan0.reason]: [BOUND]
[dhcp.wlan0.result]: [ok]
[dhcp.wlan0.server]: []
[dhcp.wlan0.vendorInfo]: []
[init.svc.dhcpcd_wlan0]: [running]
root@serranolte:/ #
I don't know if this is an CM issue? I didn't have problems with other devices running CM connecting to the same AP at the same location.
I already read a lot about similar problems at other phones but nobody ever had a fix for it.
Is it a radio problem or maybe a kernel issue?

I hope this is the right forum for it.

I'm running the latest CM11 nightly on a Samsung Galaxy S4 mini LTE (GT-I9195)
The problem also occurred with the stable builds of cm10.2 and cm10.1

any help will be appreciated

Thanks and cheers 41


Gesendet von meinem GT-I9195 mit Tapatalk
Last edited by 41.kretschi; 6th March 2014 at 12:39 PM.
10th March 2014, 12:22 PM   |  #2  
delete
Last edited by 41.kretschi; 18th March 2014 at 07:12 PM.
15th March 2014, 09:54 AM   |  #3  
Member
Thanks Meter: 194
 
92 posts
Join Date:Joined: Feb 2014
More
First of all: hi

Second: The props should get set

"
root@mb526:/ # getprop | grep dhcp
[dhcp.wlan0.dns1]: [a.b.c.d]
[dhcp.wlan0.dns2]: []
[dhcp.wlan0.dns3]: []
[dhcp.wlan0.dns4]: []
[dhcp.wlan0.domain]: [lan]
[dhcp.wlan0.gateway]: [a.b.c.d]
[dhcp.wlan0.ipaddress]: [a.b.c.e]
[dhcp.wlan0.leasetime]: [43200]
[dhcp.wlan0.mask]: [255.255.255.0]
[dhcp.wlan0.mtu]: []
[dhcp.wlan0.pid]: [12193]
[dhcp.wlan0.reason]: [REBOOT]
[dhcp.wlan0.result]: [ok]
[dhcp.wlan0.server]: [a.b.c.d]
[dhcp.wlan0.vendorInfo]: []
[init.svc.dhcpcd_wlan0]: [running]
"
with a.b.c.d being the AP/router and a.b.c.e the phone/client

Interestingly your [....result] prop is [ok]. Anyway, the [...reason] says bound (and your pid file is still there), so do more than one instance of dhcpd run in conflict? Also
"
dhcpcd[12706]: wlan0: NAK: requested address not available from 1.1.1.1
"
looks suspicious. Address collision with another client?

Local dhcpcd.conf reads

"
interface wlan0
option subnet_mask, routers, domain_name_servers
"


EDIT

Ok, forget about the [ok] and [BOUND] stuff...
You could run
"
dhcpcd -B -d wlan0
"

which stops dhcpcd from going background (-B) and should print debug info (-d). dhcpcd defaults to syslog which I don't know how to retrieve, hence no info in logcat either.
Last edited by htto; 15th March 2014 at 10:34 AM.
The Following User Says Thank You to htto For This Useful Post: [ View ]
18th March 2014, 08:06 AM   |  #4  
Thank you!
Actually I found out that it only happens when I use a wifi network with 802.1x security. Standard WPA2 works fine.

It happens with some phones and works fine with some other phones.

Is this a kernel issue?

I'll try the debug next week when I'm back at the 802 network. Will report back then.

Gesendet von meinem GT-I9195 mit Tapatalk
18th March 2014, 09:10 AM   |  #5  
Member
Thanks Meter: 194
 
92 posts
Join Date:Joined: Feb 2014
More
Quote:
Originally Posted by 41.kretschi

Thank you!
Actually I found out that it only happens when I use a wifi network with 802.1x security. Standard WPA2 works fine.

It happens with some phones and works fine with some other phones.

Is this a kernel issue?

I'll try the debug next week when I'm back at the 802 network. Will report back then.

Gesendet von meinem GT-I9195 mit Tapatalk

Phew, could have several reasons, but does the dhcp server by chance do MAC based client setup? Though it could also be a phone issue, but the
"dhcpcd[12706]: wlan0: NAK: requested address not available from 1.1.1.1"
makes me think it's a server issue. I guess
"dhcpcd -B -d wlan0"
could provide some useful insights.
The Following User Says Thank You to htto For This Useful Post: [ View ]
25th March 2014, 09:57 PM   |  #6  
Quote:
Originally Posted by htto

Phew, could have several reasons, but does the dhcp server by chance do MAC based client setup? Though it could also be a phone issue, but the
"dhcpcd[12706]: wlan0: NAK: requested address not available from 1.1.1.1"
makes me think it's a server issue. I guess
"dhcpcd -B -d wlan0"
could provide some useful insights.

Code:
1|root@serranolte:/data # dhcpcd -B -d wlan0
dhcpcd[12468]: flock `/data/misc/dhcp/dhcpcd-wlan0.pid': Try again
1|root@serranolte:/data # dhcpcd -B -d wlan0
dhcpcd[12472]: version 5.5.6 starting
dhcpcd[12472]: wlan0: using hwaddr c8:14:79:cb:f4:ec
dhcpcd[12472]: wlan0: executing `/system/etc/dhcpcd/dhcpcd-run-hooks', reason PREINIT
dhcpcd[12472]: wlan0: executing `/system/etc/dhcpcd/dhcpcd-run-hooks', reason CARRIER
dhcpcd[12472]: wlan0: reading lease `/data/misc/dhcp/dhcpcd-wlan0.lease'
dhcpcd[12472]: wlan0: rebinding lease of 10.126.51.101
dhcpcd[12472]: wlan0: sending REQUEST (xid 0xe082c143), next in 4.33 seconds
dhcpcd[12472]: wlan0: NAK: requested address not available from 1.1.1.1
dhcpcd[12472]: wlan0: executing `/system/etc/dhcpcd/dhcpcd-run-hooks', reason NAK
dhcpcd[12472]: wlan0: broadcasting for a lease
dhcpcd[12472]: wlan0: sending DISCOVER (xid 0x1fa99d89), next in 3.87 seconds
dhcpcd[12472]: wlan0: sending DISCOVER (xid 0x1fa99d89), next in 8.67 seconds
dhcpcd[12472]: wlan0: offered 10.126.49.192 from 1.1.1.1
dhcpcd[12472]: wlan0: sending REQUEST (xid 0x1fa99d89), next in 4.52 seconds
dhcpcd[12472]: wlan0: acknowledged 10.126.49.192 from 1.1.1.1
dhcpcd[12472]: wlan0: checking for 10.126.49.192
dhcpcd[12472]: wlan0: sending ARP probe (1 of 3), next in 1.44 seconds
dhcpcd[12472]: wlan0: sending ARP probe (2 of 3), next in 1.05 seconds
dhcpcd[12472]: wlan0: sending ARP probe (3 of 3), next in 2.00 seconds
dhcpcd[12472]: wlan0: leased 10.126.49.192 for 14400 seconds
dhcpcd[12472]: wlan0: adding IP address 10.126.49.192/22
dhcpcd[12472]: wlan0: adding route to 10.126.48.0/22
dhcpcd[12472]: wlan0: adding default route via 10.126.48.250
dhcpcd[12472]: wlan0: writing lease `/data/misc/dhcp/dhcpcd-wlan0.lease'
dhcpcd[12472]: wlan0: executing `/system/etc/dhcpcd/dhcpcd-run-hooks', reason BOUND
dhcpcd[12472]: wlan0: sending ARP announce (1 of 2), next in 2.00 seconds
dhcpcd[12472]: wlan0: sending ARP announce (2 of 2)
I can't see anything from that. Can you? Any ideas?

When I turn off Wifi at the phone and turn it on again, the same game starts over again.
26th March 2014, 12:45 AM   |  #7  
Member
Thanks Meter: 194
 
92 posts
Join Date:Joined: Feb 2014
More
Quote:
Originally Posted by 41.kretschi

Code:
dhcpcd[12472]: wlan0: adding IP address 10.126.49.192/22
dhcpcd[12472]: wlan0: adding route to 10.126.48.0/22
dhcpcd[12472]: wlan0: adding default route via 10.126.48.250
dhcpcd[12472]: wlan0: writing lease `/data/misc/dhcp/dhcpcd-wlan0.lease'
dhcpcd[12472]: wlan0: executing `/system/etc/dhcpcd/dhcpcd-run-hooks', reason BOUND
I can't see anything from that. Can you? Any ideas?

When I turn off Wifi at the phone and turn it on again, the same game starts over again.

Umm... that looks like it gets a route(r) and also sets the default gateway? That is a failure log? If so, what would be the supposed gateway? And the run-hooks with reason BOUND should set the properties you were missing in your first post. I'm a bit puzzled...

Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes