Networking Forums

Networking Forums > Computer Networking > Linux Networking > reason for dropped packets?

Reply
Thread Tools Display Modes

reason for dropped packets?

 
 
Azeem
Guest
Posts: n/a

 
      04-26-2007, 09:33 AM
Hello everyone,

I am using a linux box as a router. I have enabled packet
forwarding in my Linux machine (kernel 2.6.16-13) via the

echo 1 > /proc/sys/net/ipv4/ip_forward command.


Packet forwarding over the various interfaces is working fine.


I am sending anonymized packets (using a tool called Click) which
generates addresses from the entire IPv4 address space to this
machine. My routing table (which is about 167K entries long) is set up
to forward all the incoming packets to one of two interfaces eth0 and
eth1 (there are a total of 4 interfaces in the box). A couple of other
boxes at the other end of these interfaces are collecting these
packets and couting them.

I keep observing a certain amount of packets being dropped by the
router. The number of dropped packets vary each time I run my test
script. Some are being dropped by the incoming NIC itself (as observed
by the output of ifconfig <interface_name>), but these are very few
compared to the ones being dropped by the router itself.

Nothing is turning up in /var/log/messages and I have set the
printk verbosity to 8 using the
echo 8 > /proc/sys/kernel/printk command.

Two questions:
---------------------
How do I figure out why these packets are being dropped?
How do I count the number of packets being dropped?


Just an aside:
When I send non-anonymized packets to this machine (ie.
by using the IP addresses of the subnets attached to the router) no
packets are being lost at all even for much higher packets per second
injection rate. Also, the switches are not losing packets because I
ran the tests using short cross-over cables also.


Thank You.

Azeem Khan
Bombay, India.

 
Reply With Quote
 
 
 
 
Pascal Hambourg
Guest
Posts: n/a

 
      04-26-2007, 12:51 PM
Hello,

Azeem a écrit :
>
> I am sending anonymized packets (using a tool called Click) which
> generates addresses from the entire IPv4 address space to this
> machine. [...]
> I keep observing a certain amount of packets being dropped by the
> router. The number of dropped packets vary each time I run my test
> script. Some are being dropped by the incoming NIC itself (as observed
> by the output of ifconfig <interface_name>), but these are very few
> compared to the ones being dropped by the router itself.

[...]
> How do I figure out why these packets are being dropped?
> How do I count the number of packets being dropped?
>
> Just an aside:
> When I send non-anonymized packets to this machine (ie.
> by using the IP addresses of the subnets attached to the router) no
> packets are being lost


Check /proc/sys/net/ipv4/conf/*/rp_filter which controls source address
validation by reversed path.
 
Reply With Quote
 
Azeem
Guest
Posts: n/a

 
      04-27-2007, 04:09 AM
Hello Pascal,

Thank you for responding. The rp_filter was set to 1 for all my
interfaces. I set them all to 0. It did not help. I still lost a lot
of packets.

Then I enabled the log_martians capability and I noticed a bunch
of invalid addresses being logged by the system. The addresses were
those whose first octet was zero '0'.

However, the number of messages/packets logged is far fewer than
the number of packets being dropped.


Therefore 3 questions:
1. I assume, martian logging is rate limited somehow?
1.1 If so, how can I at least get a count
of the martian packets?
1.2 Can I modify kernel code somewhere to
get this count?


Thank you.

Azeem Khan
Bombay, India.

On Apr 26, 5:51 pm, Pascal Hambourg <boite-a-s...@plouf.fr.eu.org>
wrote:
> Hello,
>
> Azeem a écrit :
>
>
>
>
>
> > I am sending anonymized packets (using a tool called Click) which
> > generates addresses from the entire IPv4 address space to this
> > machine. [...]
> > I keep observing a certain amount of packets being dropped by the
> > router. The number of dropped packets vary each time I run my test
> > script. Some are being dropped by the incoming NIC itself (as observed
> > by the output of ifconfig <interface_name>), but these are very few
> > compared to the ones being dropped by the router itself.

> [...]
> > How do I figure out why these packets are being dropped?
> > How do I count the number of packets being dropped?

>
> > Just an aside:
> > When I send non-anonymized packets to this machine (ie.
> > by using the IP addresses of the subnets attached to the router) no
> > packets are being lost

>
> Check /proc/sys/net/ipv4/conf/*/rp_filter which controls source address
> validation by reversed path.



 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
dropped packets David Dumas Linux Networking 1 08-31-2005 01:38 AM
Dropped/slow packets - VERY odd Justin Rich Wireless Networks 1 05-05-2005 10:14 PM
di-614+ and mn-720 dropped packets and so on cefek Broadband Hardware 0 08-24-2004 01:20 PM
new dropped packets over wireless paul Wireless Internet 0 12-21-2003 02:04 AM
Logging dropped packets Tim Sampson Linux Networking 1 08-12-2003 01:19 PM



1 2 3 4 5 6 7 8 9 10 11