Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I've got an embedded system which is running a stripped down Gentoo userland with a manually build kernel. The system acquires data from a PCI card and sends it out to an UDP multicast group.

All worked well with an old kernel (2.6.11). Now I updated to a slightly younger kernel (2.6.15) to fix a different problem where the board would hang during reboot. This fixed the hang at reboot but now sending data to the UDP multicast group fails.

My calls to sendto under 2.6.15 give error ENOTCONN. However, the link is up and I can send data over TCP over the link without problems. My program was not changed, in fact I didn't even recompile it. Calling ifconfig eth0 under both kernels gives the same output.

Any ideas what I could have configured wrongly while building the 2.6.15 kernel? Or was there a bug or an API change in 2.6.15? I can not update to anything younger than 2.6.15 as this is the latest kernel supported by the crappy driver for the PCI card in the system.

share|improve this question
    
I just tried 2.6.19 and the effect stayed the same. –  fschmitt Sep 5 '11 at 14:21
add comment

2 Answers

After 15 hours of debugging I found the problem: The program attempted to send extremely large packets where often the size passed to sendto exceeded the maximum allowed size for UDP packets of 2^16 bytes. Now I added some logic which set the maximum packet size passed to sendto to 50000 and everything works again. It's really weird it previously worked with the older kernel and Windows XP and 7 at all.

share|improve this answer
add comment

Compare the .config from the 2.6.11 and the 2.6.15. My guess is that on your new kernel you have CONFIG_IP_MULTICAST=n (or possibly m). It should be y.

share|improve this answer
    
No, it is set to 'y' in both. –  fschmitt Sep 6 '11 at 6:41
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.