forwarding in tcng

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi!

I am learning tcng without having experiance of tc and I am trying to
build something that shall schedule traffic dependent on the value in the
IPv4 packets ip_ttl field.

I have read the tcng reference manual and cannot find information about
forwarding. Is it possible to farward packets from ingress to egress
without sending them upwards in layers?

NIC---->ingress---->forward----->egress---->

In ingress I do some metering and in egress: classifying and Queuing.

Example (basic part of the source):

#includes
#defines

dev eth1 {
	$P = bucket(rate 1Mbps, burst 2kB, mpu 64B);
	ingress {
    		class (<>)
			if ((ip_ttl & 0x81) == 0x81) &&
			(conform $p && count $P);
    		drop if 1;
	}

	egress {
		class (<$high>) if (((ip_ttl & 0x1E) >> 1) <= 0x0F) &&
			(((ip_ttl & 0x1E) >> 1) >= 0x0C);
		class (<$mid>)....
		class (<$low>)....

		prio {
			$high = class {fifo (limit 64kB);}
			$mid = ...
			$low = ...
		}
	}

}

If forwarding is not possible can I use hash table with tcindex to store
information at ingress, and use this information at egress?

Thanks!

/Johan. C

_______________________________________________
LARTC mailing list / LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux