[Date Prev] [Date Next] | [Thread Prev] [Thread Next] | [Date Index] [Thread Index] |
[snips-users] patch for multiping
|
First off, the new RRD integration is just way too cool... and easy!!! The graphs for ICMP-RTT were showing some unreasonably high values, that were somewhat consistent for a certain machine, but a machine next to it was fine... pinging by hand said both were fine. Hmm... I tracked down a bug in multiping... If something else was generating ICMP traffic (like an existing instance of nocol on the same machine as your test install of SNIPS... heh heh.) multiping would only process the first response in the receive queue while it was sending, and then wait the interpacket gap, send another, then pop off one more response. At the end of a cycle, it would clean up the rest of the responses, but since the RTT calculation is based on when it is processed (not received by the kernel) each gap time spent in the queue was being added to the RTT calculation. -=-=- PING statistics -=-=- Number of Packets Round Trip Time Remote Site Sent Rcvd Rptd Lost Min Avg Max ------------------------- ------ ------ ------ ---- ---- ---- ---- 192.168.176.80 5 5 0 0% 0 0 0 192.168.199.106 5 5 0 0% 249 249 250 192.168.179.27 5 5 0 0% 50 50 50 192.168.2.2 5 0 0 100% 0 0 0 192.168.176.153 5 5 0 0% 150 199 249 192.168.178.191 5 5 0 0% 250 250 250 192.168.176.74 5 5 0 0% 249 249 250 192.168.177.96 5 5 0 0% 199 199 200 192.168.177.187 5 5 0 0% 150 150 150 192.168.170.54 5 5 0 0% 100 100 100 192.168.177.36 5 5 0 0% 50 50 50 ------------------------- ------ ------ ------ ---- ---- ---- ---- TOTALS 55 50 0 9% 0 149 250 Notice how all the times are multiples of the interpacket gap... 50ms. Also, how it tapers off for the last few... as the queue gets emptied. After the patch: [199.106 is supposed to be slow, and 2.2 is down] -=-=- PING statistics -=-=- Number of Packets Round Trip Time Remote Site Sent Rcvd Rptd Lost Min Avg Max ------------------------- ------ ------ ------ ---- ---- ---- ---- 192.168.176.80 5 5 0 0% 0 0 0 192.168.199.106 5 5 0 0% 100 103 116 192.168.179.27 5 5 0 0% 0 0 0 192.168.2.2 5 0 0 100% 0 0 0 192.168.176.153 5 5 0 0% 0 0 0 192.168.178.191 5 5 0 0% 0 0 0 192.168.176.74 5 5 0 0% 0 0 0 192.168.177.96 5 5 0 0% 0 0 0 192.168.177.187 5 5 0 0% 0 0 0 192.168.170.54 5 5 0 0% 0 0 0 192.168.177.36 5 5 0 0% 0 0 0 ------------------------- ------ ------ ------ ---- ---- ---- ---- TOTALS 55 50 0 9% 0 10 116 I added some more logic to drain the queue each time, and still ensure the minimum gap is still met. This was tested under Solaris 7 sparc, but is just some more select() calls, so should not break anywere else. Suggestions on improvements or other bugs encouraged... [By the way, I would NOT recommend trying to run snips and nocol on the same machine at the same time... it kind of breaks the startup and keepalive scripts... :) ] Chris Bell cbell at junknet com Context diff attached (uuencoded to preserve whitespace): begin 644 multiping.diff M*BHJ(&1I<W0O<VYI<',M,2XP+W!I;F=M;VXO;75L=&EP:6YG+VUU;'1I<&EN M9RYC"51U92!*=6P@,3 @,C Z,SDZ-#D@,C P,0HM+2T@<VYI<',M,2XP+W!I M;F=M;VXO;75L=&EP:6YG+VUU;'1I<&EN9RYC"5=E9"!!=6<@,C(@,30Z,C8Z M-3<@,C P,0HJ*BHJ*BHJ*BHJ*BHJ*BH**BHJ(#0T."PT-3D at *BHJ*@HM+2T@ M-#0X+#0W,2 M+2TM"B @("H@<VET92!A;F0 at =71I;&EZ92!T:&4 at =V%I=&EN M9R!P97)I;V0 at =&\@<V5E(&EF(&%N>2!R97-P;VYS97,@8V%M92!I;BX*(" @ M*B!)9B!A('9A;&ED('!A8VME="!C;VUE<R!I;BP at =&AE('!E<FEO9"!W86ET M960@:7,@=6YK;F]W;BP at 86YD(&AE;F-E+ H@(" J('=E(&1O(&%N;W1H97(@ M=V%I="@I('1O(&9O<F-E(&$@<&%U<V4 at 9F]R('1H92!)3E1%4E!+5$=!4"!T M:6UE+ at HK(" J"BL@("H@,C)A=6<P,3H@;W)I9VEN86P at 8V]D92!W;W5L9"!O M;FQY(&-H96-K(&9O<B!O;F4@<F5S<&]N<V4@<&5R(&QO;W L"BL@("H at 9&5L M87EI;F<@=&AE('!R;V-E<W-E<W-I;F<@;V8 at 86YY(&1U<&5S('5N=&EL('1H M92!N97AT(&ET97)A=&EO;BP@"BL@("H at 861D:6YG('1H92!G87 @=&EM92!T M;R!E86-H(%)45"!C86-L=6QA=&EO;BX@"BL@("H at 22!A9&1E9"!A(&YE=R!C M;W5N=&5R("AL87-T8WEC;&4O8WEC;&5T:6UE*2!T;R!A;&QO=R!F;W(**R @ M*B!P<F]C97-S:6YG(&]F(&%L;"!Q=65U960@<F5S<&]N<V5S(&%N9"!S=&EL M;"!M86EN=&%I;B!T:&4@;W9E<F%L;"!G87 **R @*B!D96QA>2X@("T at 8V)E M;&Q :G5N:VYE="YC;VT*(" @*B\*(" *("!M<&EN9V5R*"D*("!["B @("!I M;G0):3L**R @('-T<G5C="!T:6UE=F%L(&-Y8VQE=&EM93L**R @('-T<G5C M="!T:6UE=F%L(&-Y8VQE;F]W.PHK(" @<W1R=6-T('1I;65V86P@;&%S=&-Y M8VQE.PH@( HK(" @;&%S=&-Y8VQE+G1V7W-E8R ](&QA<W1C>6-L92YT=E]U M<V5C(#T@,#L at +RH@9FER<W0@<&%C:V5T+"!N;R!D96QA>2 J+PHK( H@(" @ M9F]R("AI(#T@,#L@:2 \(&YU;7-I=&5S.R!I*RLI"B @("!["B @(" @(&EN M=" @(" @(" @(" @("!F<F]M;&5N.PHJ*BHJ*BHJ*BHJ*BHJ*BH**BHJ(#0V M,BPT-CD at *BHJ*@HM+2T at -#<T+#4P-B M+2TM"B @(" @('-T<G5C="!T:6UE M=F%L('1I;65O=70["B @(" @(&9D7W-E= EF9',["B @"BL@(" @(&=E='1I M;65O9F1A>2 at F8WEC;&5N;W<L($Y53$PI.PHK( HK("\J(&%D9"!G87 @*&US M*2!T;R!L87-T(&-Y8VQE+"!A;F0@<V5E(&AO=R!L;VYG('=E(&AA=F4 at =&\@ M=V%I="P@:68 at 870@86QL("HO"BL@(" @(&-Y8VQE=&EM92YT=E]S96,@(#T@ M;&%S=&-Y8VQE+G1V7W-E8R M(&-Y8VQE;F]W+G1V7W-E8SL**R @(" @8WEC M;&5T:6UE+G1V7W5S96,@/2!L87-T8WEC;&4N='9?=7-E8R K("A)3E1%4E!+ M5$=!4" J(#$P,# I("T at 8WEC;&5N;W<N='9?=7-E8SL**R @(" @=VAI;&4@ M*&-Y8VQE=&EM92YT=E]U<V5C(#P@,"D@>PHK(" @(" @(&-Y8VQE=&EM92YT M=E]U<V5C("L](#$P,# P,# ["BL@(" @(" @8WEC;&5T:6UE+G1V7W-E8RTM M.PHK(" @("!]"BL@(" @('=H:6QE("AC>6-L971I;64N='9?=7-E8R ^/2 Q M,# P,# P*2!["BL@(" @(" @8WEC;&5T:6UE+G1V7W5S96,@+3T@,3 P,# P M,#L**R @(" @("!C>6-L971I;64N='9?<V5C*RL["BL@(" @('T**R @(" @ M:68 at *&-Y8VQE=&EM92YT=E]S96,@/" P*2 **R @(" @("!C>6-L971I;64N M='9?<V5C(#T at 8WEC;&5T:6UE+G1V7W5S96,@/2 P.PHK("\J(&YE9V%T:79E M+"!W92!H879E('!A<W-E9"!T:&4 at 9V%P('1I;64 at 86QR96%D>2 J+PHK( HK M("\J(" @("!F<')I;G1F*'-T9&5R<BP**R @(" @(" @(F-Y8VQE=&EM92 ] M("5L9"XE;&1<;B(L(&-Y8VQE=&EM92YT=E]S96,L(&-Y8VQE=&EM92YT=E]U M<V5C*3L at +RH@("HO"BL at +RH@:68 at =V4@;F5E9"!T;R!W86ET(&%T(&%L;"P@ M=7-E('-E;&5C="X at *B\**R @(" @:68 at *&-Y8VQE=&EM92YT=E]S96,@/B P M('Q\(&-Y8VQE=&EM92YT=E]U<V5C(#X@,"D**R @(" @("!S96QE8W0H,"P@ M*&9D7W-E=" J*4Y53$PL("AF9%]S970 at *BE 54Q,+" H9F1?<V5T("HI3E5, M3"P@)F-Y8VQE=&EM92D[( HK( H@(" @("!R96%L7W!I;F=E<BAI*3L*(" * M*R @(" @9V5T=&EM96]F9&%Y*"9L87-T8WEC;&4L($Y53$PI.PHK( H@(" @ M("!T:6UE;W5T+G1V7W-E8R ](# ["B @(" @('1I;65O=70N='9?=7-E8R ] M("A)3E1%4E!+5$=!4" J(#$P,# I.PDO*B!I;B!M:6QL:7-E8W,@*B\*(" @ M(" @1D1?6D523R at F9F1S*3L**BHJ*BHJ*BHJ*BHJ*BHJ"BHJ*B T.3 L-#DW M("HJ*BH*(" *(" )=&EM96]U="YT=E]S96,@/2 P.PH@( ET:6UE;W5T+G1V M7W5S96,@/2 H24Y415)02U1'05 @*B Q,# P*3L)+RH@:6X@;6EL;&ES96-S M("HO"B$@"7-E;&5C=" H,"P at *&9D7W-E=" J*4Y53$PL("AF9%]S970 at *BE M54Q,+" H9F1?<V5T("HI3E5,3"P@)G1I;65O=70I.R *(2 @(" @?0H@(" @ M?0DO*B!E;F0Z("!F;W(H;G5M<VET97,N+BXI(" J+PH@( D*(" @("LK;G1R M86YS;6ET=&5D PHM+2T at -3(W+#4U,B M+2TM"B @"B @"71I;65O=70N='9? M<V5C(#T@,#L*(" )=&EM96]U="YT=E]U<V5C(#T at *$E 5$524$M41T%0("H@ M,3 P,"D["2\J(&EN(&UI;&QI<V5C<R J+PHA( EW:&EL92 H('-E;&5C=" H M<RLQ+" F9F1S+" H9F1?<V5T("HI3E5,3"P at *&9D7W-E=" J*4Y53$PL("9T M:6UE;W5T*2 ^(# I( HA( E[(" @+RH@:68 at =&AE<F4 at =V%S(&UO<F4 at =&AA M;B!O;F4@<&%C:V5T('%U975E9"P at 96UP='D at =&AE;2 J+PD*(2 )(" @(&9R M;VUL96X@/2!S:7IE;V8H9G)O;2D["B$@"2 @("!I9B H*&-C(#T@<F5C=F9R M;VTH<RP at *&-H87(@*BD@<&%C:V5T+"!P86-K;&5N+" P+ HA( D)"2AS=')U M8W0@<V]C:V%D9'(@*BD@)F9R;VTL("9F<F]M;&5N*2D@/" P*0HA( D@(" @ M>PHA( D):68 at *&5R<FYO(#T]($5)3E12*0DO*B!I;G1E<G)U<'1E9"P at 9F]R M9V5T('!R;V-E<W-I;F<@=&AI<R!T:6UE("HO"B$@"0D@(&-O;G1I;G5E.PHA M( D)<&5R<F]R*")P:6YG.B!R96-V9G)O;2!I;B!M<&EN9V5R(BD["2\J('-O M;64@;W1H97(@97)R;W(@*B\*(2 )"6-O;G1I;G5E.PHA( D@(" @?0HA( D@ M(" @96QS92 @+RH@<')O8V5S<R!G;V]D(')E<W!O;G-E+"!T:&5N(&9O<F-E M(&$ at 9&5L87D at *B\*(2 )(" @('L*(2 )"7!R7W!A8VLH*&-H87(@*BD@<&%C M:V5T+"!C8RP@)F9R;VTI.PHA( HA( D)=&EM96]U="YT=E]S96,@/2 P.PHA M( D)=&EM96]U="YT=E]U<V5C(#T at *$E 5$524$M41T%0("H@,3 P,"D["2\J M(&EN(&UI;&QI<V5C<R J+PHA( D@(" @('T*(2 )?2 O*B!E;F0Z('=H:6QE M(&=E="!M;W)E('%U975E9"!P86-K971S+BXN("HO"B$@(" @('T at +RH@96QS M93H@('!R;V-E<W,@9V]O9"!R97-P;VYS92XN+B J+PH@(" @?0DO*B!E;F0Z M("!F;W(H;G5M<VET97,N+BXI(" J+PH@( D*(" @("LK;G1R86YS;6ET=&5D ".PIF end |