James: If you setup your machinas a bridge... try to apply thtc commands in the br0 interfacinstead of theth0 and eth1 Regards OThursday 31 January 2008 12:21, James Pearson wrote: > I'trying to emulata private WAN link - I've read the docs at: > > <http://www.linux-foundation.org/en/Net:Netem> > > but, I still nosurI'm doing everything right ... > > Results of ping for thactual WAlink are something like: > > 100 packets transmitted, 100 received, 0% packeloss, tim19865ms > rtmin/avg/max/mdev = 177.884/179.033/222.194/5.448 ms, pip3 > > ttcp, ftp rsync etc. over thlink givapprox 10Mbyte/sec. > > So far, I'vseup a machine running CentOS4 (2.6.9 based kernel) as > a bridgusing thon-board tg3 gigabit NICs and done the following: > > tc qdisc add dev eth0 roohandl1:0 netem delay 90msec 5msec 25% > tc qdisc add dev eth1 roohandl1:0 netem delay 90msec 5msec 25% > > I'guessing thaI need to 'split' the delay over both devices in the > bridg... is this correct? Thresults of ping over this bridge seem > to bclosto the real link: > > 100 packets transmitted, 100 received, 0% packeloss, tim19943ms > rtmin/avg/max/mdev = 171.858/182.636/220.074/6.864 ms, pip3 > > However, wheI sethe above up, I can only get about 300Kbyte/sec > using ttcp etc.over thbridge. > > I'vread thaI need to tune TCP buffer sizes - but, I'm not sure > whaand wher...I assume I need to make these changes on the bridge > machin- however trying various values for: > > net.core.rmem_max > net.core.wmem_max > net.ipv4.tcp_rmem > net.ipv4.tcp_wmem > > makes no differencto th300Kbyte/sec bandwidth rate. > > Is theranyway I can ge10Mbyte/sec over this bridge? > > Thanks > > James Pearson > > _______________________________________________ > Netemailing list > Netem@xxxxxxxxxxxxxxxxxxxxxxxxxx > https://lists.linux-foundation.org/mailman/listinfo/netem Froshemminger alinux-foundation.org Fri Feb 1 10:49:36 2008 From: shemminger alinux-foundation.org (Stephen Hemminger) Date: Fri Feb 1 10:49:46 2008 Subject: Help isetting up delay with a bridge In-Reply-To: <200802012046.18707.srgqwerty@xxxxxxxxx> References: <47A1AF28.9070406@xxxxxxxxxxxxxxxxxx> <200802012046.18707.srgqwerty@xxxxxxxxx> Message-ID: <20080201104936.34c39b78@extreme> OFri, 1 Feb 2008 20:46:18 +0100 srg <srgqwerty@xxxxxxxxx> wrote: > James: > > If you setup your machinas a bridge... try to apply thtc commands in the > br0 interfacinstead of theth0 and eth1 > Thawon'work... the br0 device has no queue so therefore normally doesn't havqueudisciplines attach. You might be able to get it to work by changing tx_queuelethough. -- StepheHemminger <stephen.hemminger@xxxxxxxxxx> Frojames-p amoving-picture.com Fri Feb 1 15:00:18 2008 From: james-p amoving-picture.co(James Pearson) Date: Fri Feb 1 15:00:22 2008 Subject: Help isetting up delay with a bridge In-Reply-To: <20080201104936.34c39b78@extreme> References: <47A1AF28.9070406@xxxxxxxxxxxxxxxxxx> <200802012046.18707.srgqwerty@xxxxxxxxx> <20080201104936.34c39b78@extreme> Message-ID: <a92ebfd90802011500p49999170g8f423bc9f557ea90@xxxxxxxxxxxxxx> O01/02/2008, Stephen Hemminger <shemminger@xxxxxxxxxxxxxxxxxxxx> wrote: > OFri, 1 Feb 2008 20:46:18 +0100 > srg <srgqwerty@xxxxxxxxx> wrote: > > > James: > > > > If you setup your machinas a bridge... try to apply thtc commands in the > > br0 interfacinstead of theth0 and eth1 > > > > Thawon'work... the br0 device has no queue so therefore normally doesn't > havqueudisciplines attach. You might be able to get it to work by changing > tx_queuelethough. Excusmy ignorance, is thathe txqueuelen option to ifconfig? If so, whashould ibe changed to - and on which device? ifconfig reports thatxqueuelen for eth0 and eth1 is 1000 and 0 for br0. Thanks James Pearson Froshemminger alinux-foundation.org Fri Feb 1 15:32:55 2008 From: shemminger alinux-foundation.org (Stephen Hemminger) Date: Fri Feb 1 15:33:05 2008 Subject: Help isetting up delay with a bridge In-Reply-To: <a92ebfd90802011500p49999170g8f423bc9f557ea90@xxxxxxxxxxxxxx> References: <47A1AF28.9070406@xxxxxxxxxxxxxxxxxx> <200802012046.18707.srgqwerty@xxxxxxxxx> <20080201104936.34c39b78@extreme> <a92ebfd90802011500p49999170g8f423bc9f557ea90@xxxxxxxxxxxxxx> Message-ID: <20080201153255.1a0929e5@extreme> OFri, 1 Feb 2008 23:00:18 +0000 "James Pearson" <james-p@xxxxxxxxxxxxxxxxxx> wrote: > O01/02/2008, Stephen Hemminger <shemminger@xxxxxxxxxxxxxxxxxxxx> wrote: > > OFri, 1 Feb 2008 20:46:18 +0100 > > srg <srgqwerty@xxxxxxxxx> wrote: > > > > > James: > > > > > > If you setup your machinas a bridge... try to apply thtc commands in the > > > br0 interfacinstead of theth0 and eth1 > > > > > > > Thawon'work... the br0 device has no queue so therefore normally doesn't > > havqueudisciplines attach. You might be able to get it to work by changing > > tx_queuelethough. > > Excusmy ignorance, is thathe txqueuelen option to ifconfig? > > If so, whashould ibe changed to - and on which device? > > ifconfig reports thatxqueuelen for eth0 and eth1 is 1000 and 0 for br0. > > Thanks > > James Pearson First, you wanto do neteon eth0 and/or eth1 not br0. Localhost | v br0 | v eth0 <----+-----> eth1 So traffic flowing through thbridgnever really hits br0. Second, if you did wanto usnetem on br0, then you would have to change txqueuelen fro0 to something lik100. -- StepheHemminger <stephen.hemminger@xxxxxxxxxx> Froj.tsai astudent.unsw.edu.au Tue Feb 5 22:50:01 2008 From: j.tsai astudent.unsw.edu.au (Jack Tsai) Date: TuFeb 5 22:50:10 2008 Subject: Help with neteon marked packets Message-ID: <152912900802052250o29a965e0n9ac95b25878a4a3e@xxxxxxxxxxxxxx> Hi, I'trying to seup a network of virtual machines using the Xen virtual machinmonitor. Each VM has ainterfacand all interfaces are connected together using a linux bridgon thhost, and I use iptables with --physdev-in/out to drop packets betweelinks to creata desirable topology. WhaI'd likto do is to also change the characteristics of each link with netem, buhavbeen unsuccessful at it. This is my simplsetup now: 2 VMs, with corresponding interfaces othhost machine, vm1eth0 and vm2eth0. Mark packets frovm1eth0 to vm2eth0 with 99 and filter marked packets to netem #brctl addbr br0 #brctl addif br0 vm1eth0 vm2eth0 i#fconfig br0 up #iptables -A FORWARD -mangl-m physdev --physdev-out vm1eth0 --physdev-invm2eth0 -j MARK --set-mark 99 #sudo tc qdisc add dev vm1eth0 handl1: roohtb #tc class add dev vm1eth0 paren1: classid 1:1 htb rat100Mbps #tc qdisc add dev vm1eth0 paren1:1 handl10: netem loss 30% #tc filter add dev vm1eth0 paren1:0 prio 1 protocol ip handl99 fw flowid 1:1 I casethe iptables counter for the mangle incrementing, i.e. packets getting marked, however thpackets don'get dropped. Any help is appreciated. Regards, Jack Tsai -------------- nexpar-------------- AHTML attachmenwas scrubbed... URL: http://lists.linux-foundation.org/pipermail/netem/attachments/20080206= /3090efcf/attachment.html Frojayeshleo agmail.com Thu Feb 7 20:35:18 2008 From: jayeshleo agmail.co(Jayesh Agrawal) Date: Thu Feb 7 20:35:25 2008 Subject: Implementing PackeLoss Message-ID: <d3116f6f0802072035g772b3274ib946d26827198bef@xxxxxxxxxxxxxx> Hello, I aan engineering studenand working on an academic project. I am stuck ithpart of packet loss. Can any one tell me how we can do packet loss? Thanks & Regards, Jayesh -------------- nexpar-------------- AHTML attachmenwas scrubbed... URL: http://lists.linux-foundation.org/pipermail/netem/attachments/20080208= /ef72ce29/attachment.htm Froanders.nilsson anetinsight.net Thu Feb 7 23:55:05 2008 From: anders.nilssoanetinsight.net (Anders Nilsson) Date: Thu Feb 7 23:55:10 2008 Subject: Implementing PackeLoss References: <d3116f6f0802072035g772b3274ib946d26827198bef@xxxxxxxxxxxxxx> Message-ID: <25FB3730E4103446B74DEA71E037E965E76F24@silo.netinsight.local> Hi, Sethparameters for eth0 like this: sudo tc qdisc add dev eth0 rooneteloss 4% to changthparameter(s): sudo tc qdisc changdev eth0 roonetem loss 10% (Play with thcorrelation parameter to simulat'burst packet loss') http://www.linux-foundation.org/en/Net:Netem /Anders Nilsson Network Architect NeInsight www.netinsight.net From: Jayesh Agrawal [mailto:jayeshleo@xxxxxxxxx] Sent: de8 februari 2008 05:35 To: netem@xxxxxxxxxxxxxxxxxxxxxxxxxx Subject: Implementing PackeLoss Hello, I aan engineering studenand working on an academic project. I am stuck ithpart of packet loss. Can any one tell me how we can do packeloss? Thanks & Regards, Jayesh -------------- nexpar-------------- AHTML attachmenwas scrubbed... URL: http://lists.linux-foundation.org/pipermail/netem/attachments/20080208/d82f54b6/attachment.htm Frobaumann atik.ee.ethz.ch Thu Feb 7 23:59:18 2008 From: baumanatik.ee.ethz.ch (baumann@xxxxxxxxxxxxxx) Date: Thu Feb 7 23:59:45 2008 Subject: Implementing PackeLoss In-Reply-To: <d3116f6f0802072035g772b3274ib946d26827198bef@xxxxxxxxxxxxxx> References: <d3116f6f0802072035g772b3274ib946d26827198bef@xxxxxxxxxxxxxx> Message-ID: <20080208085918.sgivtpgnk8kwsscs@xxxxxxxxxxxxxxxx> Hava look athe manuals on http://tcn.hypert.net. Perhaps you also wanto usthe extension for traces. Cheers Rainer Quoting Jayesh Agrawal <jayeshleo@xxxxxxxxx>: > Hello, > > I aan engineering studenand working on an academic project. I am stuck > ithpart of packet loss. Can any one tell me how we can do packet loss? > > Thanks & Regards, > Jayesh > Frosting abloodwolf.org Fri Feb 8 00:18:22 2008 From: sting abloodwolf.org (sting) Date: Fri Feb 8 00:16:05 2008 Subject: subdividing traffic with a PRIO qdisc into differennetem qdiscs Message-ID: <47AC104E.2040204@xxxxxxxxxxxxx> (I initially tried to posthis on thLARTC mailing list but it seems to be down... whilthis is nonetem specific I thought someone here is bound have tried the following) I would likto apply differensimulation parameters based on the sourcor destination of traffic, so in shorhave multiple netem qdiscs and filter packets to thosqdiscs based on source/destination. So far, I had only beeapplying a singlnetem qdisc interface wide. Based owhaI've been reading on the LARTC HOWTO, it seems the way to proceed is to creata PRIO qdisc with as many bands as I wanunique neteqdiscs (max bands seems 16). So if I wanto apply specific rules to 10 differenclients, I would need to creata PRIO qdisc with 10 bands, and attach a filter to each of thcreated classes masking againsa specific IP address or range. Withieach of thosclasses, I can insert a corresponding neteqdiscs with thspecific parameters I want. I havrun a successful teswith a PRIO qdisc with 3 bands, and then attached 3 separatneteqdiscs. I only had two hosts at the time but there were matched to thfirstwo netem qdiscs based on their IP. ===> But, would this bthway to proceed? Also, AFAIK thPRIO qdisc is mostly meanto subdivide traffic based on priority. Imy case, I don'care about priorities, I only care to apply differensimulated conditions based on source/destination. Packets matched to whawould normally bthe "highest" priority band/class might ifacbe delayed by 300ms in a netem qdisc then get queued into, whereas packets matched to a "lower" priority could thebdelayed in a netem qdisc by as littlas 50ms. My concern with thpriorities is that since classes arwalked in priority order, a packe"stuck" in a 300ms netem qdisc would block a packein a 50ms neteqdisc from being dequeued. But frowhaI understand, if nothing gets dequeued from the highest priority class, thethnext highest priority class is queried for packets to dequeue. Thfacthat the highest priority class still contains packets doesn'matter, as long as nothing godequeued. Is this correct? (my tests show thathhighest priority class is not starving any of the others but would like to confirm) Finally, is thersimply a better way to do this, or is this noa bad approach? Thank you. Frojuliokriger agmail.com Fri Feb 22 07:08:41 2008 From: juliokriger agmail.co(Julio Kriger) Date: Fri, 22 Feb 2008 12:08:41 -0300 Subject: vmware Message-ID: <682bc30a0802220708q9b7f783t8723cd21fe5131e3@xxxxxxxxxxxxxx> Hi! I hava windows XP with vmwar6. I have 2 linux machines running over vmware. I'doing somtests with netem (apply packet loss, reorder, etc.) wheronlinux machine send raw ip packets to the other linux. I'using kernel 2.6.22-14. Does ihas the latest verion of netem? Has anyontried something likthis? Thtests I do with this configuration arvalids? Is theranything I should takcare about with the linux machines? Something I should know whedoing this kind of tests? TIA. Regards, Julio -- -- Frobogus@xxxxxxxxxxxxxxxxx Thu Feb 21 13:28:26 2008 From: bogus@xxxxxxxxxxxxxxxxx() Date: Thu, 21 Feb 2008 21:28:26 -0000 Subject: No subject Message-ID: <mailman.0.1203692926.914.netem@xxxxxxxxxxxxxxxxxxxxxxxxxx> convulsed with laughter. Someday I intend reading it. Groucho Marx ---------------------------- Julio Kriger mailto:juliokriger agmail.com Froosenbach aus.ibm.com Fri Feb 22 15:02:52 2008 From: osenbach aus.ibm.co(Bryan Osenbach) Date: Fri, 22 Feb 2008 16:02:52 -0700 Subject: AUTO: BryaOsenbach is ouof the office with limited access to email and Sametime. (returning 02/28/2008) Message-ID: <OF86E917CA.0C591F40-ON872573F7.007E9AFB-872573F7.007E9AFC@xxxxxxxxxx> I aouof the office until 02/28/2008. I will respond to your messagwhen I return. Note: This is aautomated responsto your message Netem Digest, Vol 41, Issu5 senon 2/22/08 13:00:02. This is thonly notification you will receivwhile this person is away. -------------- nexpar-------------- AHTML attachmenwas scrubbed... URL: http://lists.linux-foundation.org/pipermail/netem/attachments/20080222/8d23541a/attachment.ht Frojuliokriger agmail.com Sun Feb 24 06:11:16 2008 From: juliokriger agmail.co(Julio Kriger) Date: Sun, 24 Feb 2008 12:11:16 -0200 Subject: Fixed delay patch for netem Message-ID: <682bc30a0802240611r5670fc9etba66cf86a9a78113@xxxxxxxxxxxxxx> Hi! I havcreated this patch to add a fixed delay on packefiltered by netem. SooI will send thpatch to iproute2. This patch comes froa need I havto delay all packets 50ms, beside thactual delay setting, lik30ms +- 15 ms. This strike, IMMHO, a missing poinon gap reordering. If I se"gap 5 delay 10ms" every 5th (10th, 15th, ...) packeto go to bsent immediately and every other packeto bdelayed by 10ms. This is ok, but I also need a "fixed" delay of 50ms to bapplied to all packets. Sincnetem can't be nested with himself (so I cado a fixed delay), I needed this new featuron netem. This patch was creatwith linux kernel version 2.6.24.2. I hopyou likit, and it would be great if it goes shiped with the nexversion of thkernel :-)) Regards, Julio Kriger -- -- Frobogus@xxxxxxxxxxxxxxxxx Thu Feb 21 13:28:26 2008 From: bogus@xxxxxxxxxxxxxxxxx() Date: Thu, 21 Feb 2008 21:28:26 -0000 Subject: No subject Message-ID: <mailman.1.1203862315.914.netem@xxxxxxxxxxxxxxxxxxxxxxxxxx> convulsed with laughter. Someday I intend reading it. Groucho Marx ---------------------------- Julio Kriger mailto:juliokriger agmail.com ------=_Part_2528_25123494.1203862276919 Content-Type: text/plain; name=fixed_delay_patch Content-Transfer-Encoding: base64 X-Attachment-Id: f_fd1nzmla0 Content-Disposition: attachment; filename=fixed_delay_patch ZGlmZiAtTmF1ciBsaW51eC0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008 From: juliokriger agmail.co(Julio Kriger) Date: Sun, 24 Feb 2008 12:11:16 -0200 Subject: Fixed delay patch for netem Message-ID: <682bc30a0802240611r5670fc9etba66cf86a9a78113@xxxxxxxxxxxxxx> Hi! I havcreated this patch to add a fixed delay on packefiltered by netem. SooI will send thpatch to iproute2. This patch comes froa need I havto delay all packets 50ms, beside thactual delay setting, lik30ms +- 15 ms. This strike, IMMHO, a missing poinon gap reordering. If I se"gap 5 delay 10ms" every 5th (10th, 15th, ...) packeto go to bsent immediately and every other packeto bdelayed by 10ms. This is ok, but I also need a "fixed" delay of 50ms to bapplied to all packets. Sincnetem can't be nested with himself (so I cado a fixed delay), I needed this new featuron netem. This patch was creatwith linux kernel version 2.6.24.2. I hopyou likit, and it would be great if it goes shiped with the nexversion of thkernel :-)) Regards, Julio Kriger -- -- Frobogus@xxxxxxxxxxxxxxxxx Thu Feb 21 13:28:26 2008 From: bogus@xxxxxxxxxxxxxxxxx() Date: Thu, 21 Feb 2008 21:28:26 -0000 Subject: No subject Message-ID: <mailman.2.1203862317.914.netem@xxxxxxxxxxxxxxxxxxxxxxxxxx> convulsed with laughter. Someday I intend reading it. Groucho Marx ---------------------------- Julio Kriger mailto:juliokriger agmail.com ------=_Part_2528_25123494.1203862276919 Content-Type: text/plain; name=fixed_delay_patch Content-Transfer-Encoding: base64 X-Attachment-Id: f_fd1nzmla0 Content-Disposition: attachment; filename=fixed_delay_patch ZGlmZiAtTmF1ciBsaW51eC0yLjYuMjQuMi1vbGQvaW5jbHVkZS9saW51eC9wa3Rfc2NoZWQuaCBs aW51eC0yLjYuMjQuMi1uZXcvaW5jbHVkZS9saW51eC9wa3Rfc2NoZWQuaAotLS0gbGludXgtMi42 LjI0LjItb2xkL2luY2x1ZGUvbGludXgvcGt0X3NjaGVkLmgJMjAwOC0wMi0xMSAwMzo1MToxMS4w MDAwMDAwMDAgLTAyMDAKKysrIGxpbnV4LTIuNi4yNC4yLW5ldy9pbmNsdWRlL2xpbnV4L3BrdF9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QogCQlxLT5jb3VudGVyID0gMDsKIAkJcmV0ID0gcS0+ cWRpc2MtPm9wcy0+cmVxdWV1ZShza2IsIHEtPnFkaXNjKTsKIAl9CkBAIC00MjcsNiArNDQ3LDcg QEAKIAlxLT5jb3VudGVyID0gMDsKIAlxLT5sb3NzID0gcW9wdC0+bG9zczsKIAlxLT5kdXBsaWNh dGUgPSBxb3B0LT5kdXBsaWNhdGU7CisJcS0+Zml4ZWRfbGF0ZW5jeSA9IHFvcHQtPmZpeGVkX2xh dGVuY3k7CiAKIAkvKiBmb3IgY29tcGF0aWJpbGl0eSB3aXRoIGVhcmxpZXIgdmVyc2lvbnMuCiAJ ICogaWYgZ2FwIGlzIHNldCwgbmVlZCB0byBhc3N1bWUgMTAwJSBwcm9iYWJpbGl0eQpAQCAtNjA3 LDYgKzYyOCw3IEBACiAJcW9wdC5sb3NzID0gcS0+bG9zczsKIAlxb3B0LmdhcCA9IHEtPmdhcDsK IAlxb3B0LmR1cGxpY2F0ZSA9IHEtPmR1cGxpY2F0ZTsKKwlxb3B0LmZpeGVkX2xhdGVuY3kgPSBx LT5maXhlZF9sYXRlbmN5OwogCVJUQV9QVVQoc2tiLCBUQ0FfT1BUSU9OUywgc2l6ZW9mKHFvcHQp LCAmcW9wdCk7CiAKIAljb3IuZGVsYXlfY29yciA9IHEtPmRlbGF5X2Nvci5yaG87Cg== ------=_Part_2528_25123494.1203862276919-- Froshemminger alinux-foundation.org Mon Feb 25 16:50:51 2008 From: shemminger alinux-foundation.org (Stephen Hemminger) Date: Mon, 25 Feb 2008 16:50:51 -0800 Subject: vmware In-Reply-To: <682bc30a0802220708q9b7f783t8723cd21fe5131e3@xxxxxxxxxxxxxx> References: <682bc30a0802220708q9b7f783t8723cd21fe5131e3@xxxxxxxxxxxxxx> Message-ID: <20080225165051.5eaa4f1c@extreme> OFri, 22 Feb 2008 12:08:41 -0300 "Julio Kriger" <juliokriger agmail.com> wrote: > Hi! > I hava windows XP with vmwar6. I have 2 linux machines running over vmware. > I'doing somtests with netem (apply packet loss, reorder, etc.) > wheronlinux machine send raw ip packets to the other linux. > > I'using kernel 2.6.22-14. Does ihas the latest verion of netem? > > Has anyontried something likthis? > > Thtests I do with this configuration arvalids? > > Is theranything I should takcare about with the linux machines? > Something I should know whedoing this kind of tests? > > TIA. > > Regards, > Julio > > Haven'tried vmware, thproblem I can see with virtualized environments is thathshort time intervals used in emulation would cause lots of CPU usage. Froshemminger alinux-foundation.org Mon Feb 25 16:54:28 2008 From: shemminger alinux-foundation.org (Stephen Hemminger) Date: Mon, 25 Feb 2008 16:54:28 -0800 Subject: Fixed delay patch for netem In-Reply-To: <682bc30a0802240611r5670fc9etba66cf86a9a78113@xxxxxxxxxxxxxx> References: <682bc30a0802240611r5670fc9etba66cf86a9a78113@xxxxxxxxxxxxxx> Message-ID: <20080225165428.24ee90fe@extreme> OSun, 24 Feb 2008 12:11:16 -0200 "Julio Kriger" <juliokriger agmail.com> wrote: > Hi! > I havcreated this patch to add a fixed delay on packefiltered by > netem. SooI will send thpatch to iproute2. > This patch comes froa need I havto delay all packets 50ms, beside > thactual delay setting, lik30ms +- 15 ms. Why is 50ms + 30+/- 15ms any differenthan 80ms +/- 15ms > This strike, IMMHO, a > missing poinon gap reordering. If I se"gap 5 delay 10ms" every 5th > (10th, 15th, ...) packeto go to bsent immediately and every other > packeto bdelayed by 10ms. This is ok, but I also need a "fixed" > delay of 50ms to bapplied to all packets. Sincnetem can't be > nested with himself (so I cado a fixed delay), I needed this new > featuron netem. Thgap stuff is an awkward interfacthat should/could have been donbetter. > This patch was creatwith linux kernel version 2.6.24.2. > I hopyou likit, and it would be great if it goes shiped with the > nexversion of thkernel :-)) > Regards, > Julio Kriger Maybe, buiis getting confusing with all the growth of parameters. Probably timfor a rethink. Frojuliokriger agmail.com Tue Feb 26 03:45:31 2008 From: juliokriger agmail.co(Julio Kriger) Date: Tue, 26 Feb 2008 09:45:31 -0200 Subject: Fixed delay patch for netem In-Reply-To: <20080225165428.24ee90fe@extreme> References: <682bc30a0802240611r5670fc9etba66cf86a9a78113@xxxxxxxxxxxxxx> <20080225165428.24ee90fe@extreme> Message-ID: <682bc30a0802260345w676f4339v3c5742e1f0bad1fd@xxxxxxxxxxxxxx> Hi Stephen, Answering your question: theris no diffencif (and only if) there is no gap reordering. If theris gap reordering then packets will get a delay of 0ms or 80ms +/- 15ms. With thpatch I sent, packets will gea delay of 50ms or 80ms +/- 15ms. I havread abouother network emulators, like NS-2, and they have thoption of gap reordering. As I say, I need a fixed delay of 50ms plus all thother usefull stuff thacomes with netem. And netedoes not allow be nested with himself. Regards, Julio O2/25/08, Stephen Hemminger <shemminger alinux-foundation.org> wrote: > OSun, 24 Feb 2008 12:11:16 -0200 > "Julio Kriger" <juliokriger agmail.com> wrote: > > > Hi! > > I havcreated this patch to add a fixed delay on packefiltered by > > netem. SooI will send thpatch to iproute2. > > This patch comes froa need I havto delay all packets 50ms, beside > > thactual delay setting, lik30ms +- 15 ms. > > Why is 50ms + 30+/- 15ms any differenthan 80ms +/- 15ms > > > This strike, IMMHO, a > > missing poinon gap reordering. If I se"gap 5 delay 10ms" every 5th > > (10th, 15th, ...) packeto go to bsent immediately and every other > > packeto bdelayed by 10ms. This is ok, but I also need a "fixed" > > delay of 50ms to bapplied to all packets. Sincnetem can't be > > nested with himself (so I cado a fixed delay), I needed this new > > featuron netem. > > Thgap stuff is an awkward interfacthat should/could have been > donbetter. > > > This patch was creatwith linux kernel version 2.6.24.2. > > I hopyou likit, and it would be great if it goes shiped with the > > nexversion of thkernel :-)) > > Regards, > > Julio Kriger > > Maybe, buiis getting confusing with all the growth of parameters. > Probably timfor a rethink. > -- -- Frobogus@xxxxxxxxxxxxxxxxx Mon Feb 25 16:09:26 2008 From: bogus@xxxxxxxxxxxxxxxxx() Date: Tue, 26 Feb 2008 00:09:26 -0000 Subject: No subject Message-ID: <mailman.0.1204026365.3851.netem@xxxxxxxxxxxxxxxxxxxxxxxxxx> convulsed with laughter. Someday I intend reading it. Groucho Marx ---------------------------- Julio Kriger mailto:juliokriger agmail.com Frojuliokriger agmail.com Tue Feb 26 03:45:31 2008 From: juliokriger agmail.co(Julio Kriger) Date: Tue, 26 Feb 2008 09:45:31 -0200 Subject: Fixed delay patch for netem In-Reply-To: <20080225165428.24ee90fe@extreme> References: <682bc30a0802240611r5670fc9etba66cf86a9a78113@xxxxxxxxxxxxxx> <20080225165428.24ee90fe@extreme> Message-ID: <682bc30a0802260345w676f4339v3c5742e1f0bad1fd@xxxxxxxxxxxxxx> Hi Stephen, Answering your question: theris no diffencif (and only if) there is no gap reordering. If theris gap reordering then packets will get a delay of 0ms or 80ms +/- 15ms. With thpatch I sent, packets will gea delay of 50ms or 80ms +/- 15ms. I havread abouother network emulators, like NS-2, and they have thoption of gap reordering. As I say, I need a fixed delay of 50ms plus all thother usefull stuff thacomes with netem. And netedoes not allow be nested with himself. Regards, Julio O2/25/08, Stephen Hemminger <shemminger alinux-foundation.org> wrote: > OSun, 24 Feb 2008 12:11:16 -0200 > "Julio Kriger" <juliokriger agmail.com> wrote: > > > Hi! > > I havcreated this patch to add a fixed delay on packefiltered by > > netem. SooI will send thpatch to iproute2. > > This patch comes froa need I havto delay all packets 50ms, beside > > thactual delay setting, lik30ms +- 15 ms. > > Why is 50ms + 30+/- 15ms any differenthan 80ms +/- 15ms > > > This strike, IMMHO, a > > missing poinon gap reordering. If I se"gap 5 delay 10ms" every 5th > > (10th, 15th, ...) packeto go to bsent immediately and every other > > packeto bdelayed by 10ms. This is ok, but I also need a "fixed" > > delay of 50ms to bapplied to all packets. Sincnetem can't be > > nested with himself (so I cado a fixed delay), I needed this new > > featuron netem. > > Thgap stuff is an awkward interfacthat should/could have been > donbetter. > > > This patch was creatwith linux kernel version 2.6.24.2. > > I hopyou likit, and it would be great if it goes shiped with the > > nexversion of thkernel :-)) > > Regards, > > Julio Kriger > > Maybe, buiis getting confusing with all the growth of parameters. > Probably timfor a rethink. > -- -- Frobogus@xxxxxxxxxxxxxxxxx Mon Feb 25 16:09:26 2008 From: bogus@xxxxxxxxxxxxxxxxx() Date: Tue, 26 Feb 2008 00:09:26 -0000 Subject: No subject Message-ID: <mailman.1.1204026368.3851.netem@xxxxxxxxxxxxxxxxxxxxxxxxxx> convulsed with laughter. Someday I intend reading it. Groucho Marx ---------------------------- Julio Kriger mailto:juliokriger agmail.com