New user's registration have been closed due to high spamming and low trafic on this forum. Please contact forum admins directly if you need an account. Thanks !

B2 won't accept DHCP Offer in rescue mode

Got problems with your B2 or B3? Share and get helped!
Ubi
Posts: 1549
Joined: 17 Jul 2007, 09:01

Re: B2 won't accept DHCP Offer in rescue mode

Post by Ubi »

That sounds plausible. What would be the correct iptables lines to add to solve this problem?
Gordon
Posts: 1462
Joined: 10 Aug 2011, 03:18

Re: B2 won't accept DHCP Offer in rescue mode

Post by Gordon »

Ubi wrote:That sounds plausible. What would be the correct iptables lines to add to solve this problem?

Code: Select all

-A INPUT -p udp -m udp --dport 67:68 -j ACCEPT
Ubi
Posts: 1549
Joined: 17 Jul 2007, 09:01

Re: B2 won't accept DHCP Offer in rescue mode

Post by Ubi »

erm... yes of course. Quite simple really :)
MouettE
Site admin
Posts: 345
Joined: 06 Oct 2011, 19:45

Re: B2 won't accept DHCP Offer in rescue mode

Post by MouettE »

So I started trying to diagnose this issue with my brand new serial console access :P. Here is my test environment :
- A Bubba 2 with the 2.4RC1 image on a FAT32 usb disk, DO_INSTALL=0 in bubba.cfg
- A laptop with debian squeeze with static IP adress 192.168.1.1/24 on eth0, without firewall
- busybox dhcp server (udhcpd) on the laptop with the following configuration :

Code: Select all

start 192.168.1.100
end 192.168.1.200
interface eth0
max_leases 101
option subnet 255.255.255.0
option domain local
option lease 864000
Here the last relevant messages from the boot :

Code: Select all

Starting network...
ip: RTNETLINK answers: File exists
udhcpc (v1.11.1) started
Sending discover...
Sending discover...
PHY: e0024520:01 - Link is Up - 1000/Full
Sending discover...
No lease, failing
Here are the packets seen by wireshark :

Code: Select all

1 0.000000    0.0.0.0               255.255.255.255       DHCP     DHCP Discover - Transaction ID 0x7cbc932a
2 0.007332    192.168.1.1           255.255.255.255       DHCP     DHCP Offer    - Transaction ID 0x7cbc932a
3 6.048017    0.0.0.0               255.255.255.255       DHCP     DHCP Discover - Transaction ID 0x7cbc932a
4 6.058832    192.168.1.1           255.255.255.255       DHCP     DHCP Offer    - Transaction ID 0x7cbc932a
And the udhcpd log :

Code: Select all

Nov 8 13:52:00 si91004 udhcpd[9121]: Sending OFFER of 192.168.1.100
Nov 8 13:52:06 si91004 udhcpd[9121]: Sending OFFER of 192.168.1.100
The dhcp offer packets are sent but the b2 seems to ignore them.

After that I logged into the console, tried to manually set the IP adress on eth0 and ping the laptop:

Code: Select all

# ip address show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast qlen 1000
    link/ether 00:22:02:00:10:94 brd ff:ff:ff:ff:ff:ff
3: eth1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop qlen 1000
    link/ether 00:22:02:00:10:95 brd ff:ff:ff:ff:ff:ff
# ip address add 192.168.1.2/24 dev eth0
# ping 192.168.1.1
PING 192.168.1.1 (192.168.1.1): 56 data bytes

--- 192.168.1.1 ping statistics ---
6 packets transmitted, 0 packets received, 100% packet loss
During the ping attempt, wireshark reported :

Code: Select all

 5 68.576345   ExcitoEl_00:10:94     Broadcast             ARP      Who has 192.168.1.1?  Tell 192.168.1.2
 6 68.576398   Usi_60:34:44          ExcitoEl_00:10:94     ARP      192.168.1.1 is at 00:21:86:60:34:44
 7 69.576317   ExcitoEl_00:10:94     Broadcast             ARP      Who has 192.168.1.1?  Tell 192.168.1.2
 8 69.576331   Usi_60:34:44          ExcitoEl_00:10:94     ARP      192.168.1.1 is at 00:21:86:60:34:44
 9 70.576312   ExcitoEl_00:10:94     Broadcast             ARP      Who has 192.168.1.1?  Tell 192.168.1.2
10 70.576327   Usi_60:34:44          ExcitoEl_00:10:94     ARP      192.168.1.1 is at 00:21:86:60:34:44
11 72.576321   ExcitoEl_00:10:94     Broadcast             ARP      Who has 192.168.1.1?  Tell 192.168.1.2
12 72.576335   Usi_60:34:44          ExcitoEl_00:10:94     ARP      192.168.1.1 is at 00:21:86:60:34:44
13 73.576327   ExcitoEl_00:10:94     Broadcast             ARP      Who has 192.168.1.1?  Tell 192.168.1.2
14 73.576342   Usi_60:34:44          ExcitoEl_00:10:94     ARP      192.168.1.1 is at 00:21:86:60:34:44
15 74.576317   ExcitoEl_00:10:94     Broadcast             ARP      Who has 192.168.1.1?  Tell 192.168.1.2
16 74.576333   Usi_60:34:44          ExcitoEl_00:10:94     ARP      192.168.1.1 is at 00:21:86:60:34:44
Well that definitely puzzled me : the b2 makes an arp requests, which gets answered, but ignored. At least that is coherent with the DHCP behaviour. I checked the arp table on the b2 :

Code: Select all

# cd /proc/net
# cat arp
IP address       HW type     Flags       HW address            Mask     Device
192.168.1.1      0x1         0x0         00:00:00:00:00:00     *        eth0
Last but not least I tried to ping from the laptop, wich didn't work either ; wireshark shows :

Code: Select all

17 156.539217  Usi_60:34:44          Broadcast             ARP      Who has 192.168.1.2?  Tell 192.168.1.1
18 157.539295  Usi_60:34:44          Broadcast             ARP      Who has 192.168.1.2?  Tell 192.168.1.1
19 158.538823  Usi_60:34:44          Broadcast             ARP      Who has 192.168.1.2?  Tell 192.168.1.1
The ARP requests from the laptop are ignored by the device.

I think I am probably missing something obvious here... It seems like the network card refuses to transmit inbound packets to the kernel, a problem I never heard of.
Post Reply