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.

Are there Unix tools to troubleshoot UDP packet corruption? I'd like to avoid writing my own...

I think ping might report when a packet is corrupted, but it doesn't really seem to have options targeting corruption. I guess I'd like to find the BER and also—if possible—where in the path its occurring.

(Background: I have three OpenVPN VPNs (all in UDP mode, using certificates) running between two Linux machines, over different ISPs. One of the VPNs occasionally spits out "Authenticate/Decrypt packet error: packet HMAC authentication failed", which I believe means either that one of the VPN packets was corrupted in transit, or alternatively someone spewed random junk to the OpenVPN port. I'm guessing corruption, as it occurs mainly during a bulk transfer at night.)

share|improve this question
1  
This is a problem above the UDP level, it is the VPN detecting the problem. If there are broken UDP packages, your application won't find out. –  vonbrand Mar 18 '13 at 16:48
    
@vonbrand It happens on only one of the the three VPNs (with the same software and same config, except for IP/port). The UDP checksum should discard bad packets, bit its only a 16-bit checksum, so 1/65536 should make it through by chance. –  derobert Mar 18 '13 at 19:24
    
Check cabling, etc. Is some cable passing near a fluorescent light (copious eletromagnetic interference, might be turned on only during the night)? –  vonbrand Mar 18 '13 at 19:25
    
@vonbrand The lights here are off at night (this side is in a small office, so all of that is turned off at night) But I'm hoping to find some tool to just blast several mbps of UDP traffic across to confirm its actually packet corruption. –  derobert Mar 18 '13 at 19:30
    
If you want to blast traffic around, use nc (aka netcat, part of nmap). You shold be able to see errors in the various counters associated to the interfaces, or by comparing what goes through to what was sent (just size for UDP). But again, if this is only for one VPN, see if you can smoke out some difference which could explain the problem. Perhaps not-so-good network card, cable, switch port, network cable too near/parallel to electric cables, ...). –  vonbrand Mar 18 '13 at 19:43

Your Answer

 
discard

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

Browse other questions tagged or ask your own question.