Bootp hangs

Bootp hangs

Post by Guillaume Dargau » Thu, 05 May 2011 19:05:33



Hello all,
I develop embedded devices that do a network boot (for the OS, the kernel is
in flash). The latest card hangs during the bootp sequence and wireshark
running on the DHCP server doesn't see any packet.
I'm no network engineer so I need a little help with this:

Linux/PowerPC load: console=ttyUL0,115200 root=/dev/nfs rw ip=bootp
[...]
[   43.578791] Device Tree Probing 'ethernet'
[   43.583105] of:xilinx_lltemac 81c00000.ethernet: MAC address is now  0:
a:35:61: 9: 0
[   43.590334] of:xilinx_lltemac 81c00000.ethernet: XLlTemac: using DMA
mode.
[   43.597406] XLlTemac: Dma base address: phy: 0x84600100, virt: 0xc901c100
[   43.603884] XLlTemac: buffer descriptor size: 32768 (0x8000)
[   43.609367] XLlTemac: Allocating DMA descriptors with kmalloc
[   43.615011] XLlTemac: (buffer_descriptor_init) phy: 0x78d8000, virt:
0xc78d8000, size: 0x8000
[   43.627888] XTemac: PHY detected at address 7.
[   43.634195] of:xilinx_lltemac 81c00000.ethernet: eth0: Xilinx TEMAC at
0x81C00000 mapped to 0xC9016000, irq=17
[   43.649582] mice: PS/2 mouse device common for all mice
[   43.653549] oprofile: using timer interrupt.
[   43.660214] TCP cubic registered
[   43.662189] NET: Registered protocol family 17
[   44.174692] eth0: XLlTemac: Options: 0x3fa
[   44.177692] eth0: XLlTemac: allocating interrupt 19 for dma mode tx.
[   44.184044] eth0: XLlTemac: allocating interrupt 18 for dma mode rx.
[   46.200547] eth0: XLlTemac: speed set to 1000Mb/s
[   46.204069] eth0: XLlTemac: Send Threshold = 24, Receive Threshold = 4
[   46.210464] eth0: XLlTemac: Send Wait bound = 254, Receive Wait bound =
254
[   47.223788] Sending BOOTP requests ..
[   50.213852] eth0: XLlTemac: PHY Link carrier lost.
[   53.823790] .
[   56.223895] eth0: XLlTemac: speed set to 1000Mb/s
[   56.227493] eth0: XLlTemac: PHY Link carrier restored.
[   61.173791] .
[   66.223852] eth0: XLlTemac: PHY Link carrier lost.
[   70.233897] eth0: XLlTemac: speed set to 1000Mb/s
[   70.237332] eth0: XLlTemac: PHY Link carrier restored.
[   74.033791] .. timed out!
[  126.534344] IP-Config: Reopening network devices...
[  127.043865] eth0: XLlTemac: Options: 0x3fa
[  127.046770] eth0: XLlTemac: allocating interrupt 19 for dma mode tx.
[  127.053032] eth0: XLlTemac: allocating interrupt 18 for dma mode rx.
[  129.069839] eth0: XLlTemac: speed set to 1000Mb/s
[  129.073289] eth0: XLlTemac: Send Threshold = 24, Receive Threshold = 4
[  129.079825] eth0: XLlTemac: Send Wait bound = 254, Receive Wait bound =
254
[  130.093791] Sending BOOTP requests ...... timed out!
[  219.614344] IP-Config: Auto-configuration of network fe[  219.620053]
Root-NFS: no NFS server address
[  219.622965] VFS: Unable to mount root fs via NFS, trying floppy.
[  219.629252] List of all partitions:
[  219.632409] No filesystem could mount root, tried:
[  219.637256] Kernel panic - not syncing: VFS: Unable to mount root fs on
unknown-block(2,0)
[  219.645483] Call Trace:
[  219.647923] [c7829ea0] [c0007710] show_stack+0x40/0x168 (unreliable)
[  219.654243] [c7829ee0] [c020d2b8] panic+0xa4/0x1e4
[  219.658941] [c7829f30] [c0282ccc] mount_block_root+0x208/0x240
[  219.664741] [c7829f80] [c0282d94] mount_root+0x90/0xdc
[  219.669821] [c7829fb0] [c0282ec8] prepare_namespace+0xe8/0x194
[  219.675629] [c7829fd0] [c0282258] kernel_init+0x138/0x174
[  219.680974] [c7829ff0] [c000da80] kernel_thread+0x4c/0x68
[  219.686324] Rebooting in 180 seconds..

On the DHCP server nothing comes through (no packet shown by wireshark).
After that nothing happens (no new dots after "Sending BOOTP requests ."
like when there's no physical connection)

I've tried with 2 different network cards on the server, a crossover cable,
a straight cable (which normally works too), 2 switches (10mbps and 1gbps),
a 100mbps hub...

I have another design with the exact same kernel, only different dts
(hardware definition) file.

$ cat /etc/dhcpd.conf:
allow bootp;
allow booting;
ddns-update-style interim;
subnet 192.168.1.0 netmask 255.255.255.0 {
        default-lease-time 21600;
        option routers 192.168.1.185;
        option subnet-mask 255.255.255.0;
        option ntp-servers 192.168.1.185;
#       range dynamic-bootp 192.168.1.128 192.168.1.254;

Quote:}

host meascur {
        hardware ethernet 0:a:35:61:9:0;
        fixed-address 192.168.1.232;
        server-name "192.168.1.185";
        option host-name "meascur";
        option root-path
"192.168.1.185:/media/meascur,v3,rsize=1024,wsize=1024,proto=tcp,nolock,intr";

Quote:}

$ cat /etc/sysconfig/dhcpd
DHCPDARGS=eth1

$ cat /etc/exports
/media/meascur
meascur(rw,no_root_squash,no_all_squash,async,insecure,fsid=0)

If I try to ping 192.168.1.232 from the server, on eth1 I see packets:
205     269.000435      Broadcom_5f:67:bc       Broadcast       ARP    
Who has 192.168.1.232?  Tell 192.168.1.185
But obviously no reply.

What can I try to diagnose this ?
--
Guillaume Dargaud
http://www.gdargaud.net/

 
 
 

Bootp hangs

Post by Tauno Voipi » Fri, 06 May 2011 03:53:23



Quote:> Hello all,
> I develop embedded devices that do a network boot (for the OS, the kernel is
> in flash). The latest card hangs during the bootp sequence and wireshark
> running on the DHCP server doesn't see any packet.
> I'm no network engineer so I need a little help with this:

> Linux/PowerPC load: console=ttyUL0,115200 root=/dev/nfs rw ip=bootp
> [...]
> [   43.578791] Device Tree Probing 'ethernet'
> [   43.583105] of:xilinx_lltemac 81c00000.ethernet: MAC address is now  0:
> a:35:61: 9: 0
> [   43.590334] of:xilinx_lltemac 81c00000.ethernet: XLlTemac: using DMA
> mode.
> [   43.597406] XLlTemac: Dma base address: phy: 0x84600100, virt: 0xc901c100
> [   43.603884] XLlTemac: buffer descriptor size: 32768 (0x8000)
> [   43.609367] XLlTemac: Allocating DMA descriptors with kmalloc
> [   43.615011] XLlTemac: (buffer_descriptor_init) phy: 0x78d8000, virt:
> 0xc78d8000, size: 0x8000
> [   43.627888] XTemac: PHY detected at address 7.
> [   43.634195] of:xilinx_lltemac 81c00000.ethernet: eth0: Xilinx TEMAC at
> 0x81C00000 mapped to 0xC9016000, irq=17
> [   43.649582] mice: PS/2 mouse device common for all mice
> [   43.653549] oprofile: using timer interrupt.
> [   43.660214] TCP cubic registered
> [   43.662189] NET: Registered protocol family 17
> [   44.174692] eth0: XLlTemac: Options: 0x3fa
> [   44.177692] eth0: XLlTemac: allocating interrupt 19 for dma mode tx.
> [   44.184044] eth0: XLlTemac: allocating interrupt 18 for dma mode rx.
> [   46.200547] eth0: XLlTemac: speed set to 1000Mb/s
> [   46.204069] eth0: XLlTemac: Send Threshold = 24, Receive Threshold = 4
> [   46.210464] eth0: XLlTemac: Send Wait bound = 254, Receive Wait bound =
> 254
> [   47.223788] Sending BOOTP requests ..
> [   50.213852] eth0: XLlTemac: PHY Link carrier lost.

This points to the hardware, maybe bad cable or a mis-behaving switch.

Loss of PHY link means that there is nothing to do in software.

--

Tauno Voipio

 
 
 

Bootp hangs

Post by Guillaume Dargau » Fri, 06 May 2011 17:11:28


Quote:> This points to the hardware, maybe bad cable or a mis-behaving switch.
> Loss of PHY link means that there is nothing to do in software.

Correct. Using a 100mbps switch works, so that's how I'll be using it I
guess.
--
Guillaume Dargaud
http://www.gdargaud.net/
 
 
 

1. bootp server replies being ignored by bootp client

I've got a Linux client whose 2.4.3 kernel is configured to generate
BOOTP requests to obtain the host machine's IP address at boot-up. The
kernel is indeed sending out BOOTP requests but it's ignoring the
replies from the BOOTP server. Any ideas why this would be happening
???

FWIW, I've sniffed the network with 'ethereal' v0.8.17 during the
BOOTP transactions between the client and server and have confirmed
that: a ) the BOOTP server is responding to the client's BOOTP
requests, and b) the packets are arriving at the ethernet hub that the
BOOTP client is connected to. Furthermore, the responses contain the
correct information -- e.g., the client's IP address, the file name of
the client's kernel (relative to the BOOTP server's file system), the
directory on the BOOTP server that the client should mount via NFS as
its root file system, etc.

FWIW2, I've added the following debug statements to the beginning of
the 'ic_boot_recv()' function in 'linux/net/ipv4/ipconfig.c' (in the
2.4.3 source tree), but the '<--here--> etc.' debug message (see
below) is never printed -- i.e., it seems the 'ic_bootp_recv()'
function is never called, even though the bootp server is sending back
well-formed reply packets.

--- begin patch ---

diff -Nuar /old/linux/net/ipv4/ipconfig.c linux/net/ipv4/ipconfig.c
--- /old/linux/net/ipv4/ipconfig.c Fri Feb  9 11:34:13 2001

 #include <asm/checksum.h>

 /* Define this to allow debugging output */
-#undef IPCONFIG_DEBUG
+#define IPCONFIG_DEBUG

 #ifdef IPCONFIG_DEBUG

  struct bootp_pkt *b = (struct bootp_pkt *) skb->nh.iph;
  struct iphdr *h = &b->iph;
  int len;
+#ifdef IPCONFIG_DEBUG
+printk( "<--here--> %s() called...\n" __FUNCTION__ );
+#endif

  /* If we already have a reply, just drop the packet */
  if (ic_got_reply)

--- end patch ---

Any ideas what's going on here?  (BTW, I'm using a 3Com 3c905C NIC and
its driver is compiled into the kernel...)

Jim

2. problems connecting to my ISP

3. bootp client ignoring replies from bootp server

4. Linux groups in Kansas City area

5. kernel 2.2.19 bootp client + bootp server 2.4.3 = problem

6. How to access SBCDRom ?

7. DHCP <-> BOOTP - Linux only has Bootp?

8. Win95 telnet to Linux

9. bootp server replies being ignored by bootp client ?

10. Hang, Hang, Hangs. No hopes!

11. SCSI Bus Hangs (was OSR5.0.2 Install Hangs)

12. 4.7 install hangs (CD boot hangs when probing devices)

13. SS-1000 hangs / df hangs