Thread Berechnung der Laenge von Unterbrechungen im HSDPA netz (37 answers)
Opened by bowkatz at 2009-07-08 10:02

bowkatz
 2009-07-13 11:51
#123096 #123096
User since
2009-07-10
7 Artikel
BenutzerIn
[default_avatar]
naja funktioniert immer noch nicht (wenn mann 3, oda 4, nimmmt) werden die Ausfaelle zwar weniger kommen aber immer noch nicht an den echten Wert heran.
es könnte daran liegen das ich wie von renee empfohlen eine for-schleifegenommen habe...
Code: (dl )
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
my $grenzwert = 0;
my @alle_zeilen=qx'C:\Programme\Wireshark\Tshark -r C:\Test2.pcap -z io,stat,1 ftp';
my $data;
for my $line (@alle_zeilen) {
next unless $line =~ /\d{4,}\.\d{3}-\d{4,}\.\d{3}/;
my( $bytes ) = $line =~ /\s(\d+)$/;
if ( $bytes > $grenzwert ) { $data .= '1' }
else { $data .= '0' }
}

my @fail;
for my $ausfall ( $data =~ /(0+)/g ) {
push @fail, length $ausfall;
}

my $summe = 0;
$summe += $_ for @fail;

my $mittel = $summe / @fail;

print "Ausfaelle: " . join( ", ", @fail ) . "\n";
print "$summe Sekunden insg. und ";
print "$mittel Sekunden im Mittel pro Ausfall\n";


output mit 3, :
Ausfaelle: 1260
1260 Sekunden insg. und 1260 Sekunden im Mittel pro Ausfall

und mit 4,

Ausfaelle: 260
260 Sekunden insg. und 260 Sekunden im Mittel pro Ausfall


Dann nun dies:
Code: (dl )
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
#!/usr/bin/perl -w
use strict;
my $grenzwert = 35;
my $data;
while ( my $line = <DATA> ) {
next unless $line =~ /\d{4,}\.\d{3}-\d{4,}\.\d{3}/;
my( $bytes ) = $line =~ /\s(\d+)$/;
if ( $bytes > $grenzwert ) { $data .= '1' }
else { $data .= '0' }
}

my @fail;
for my $ausfall ( $data =~ /(0+)/g ) {
push @fail, length $ausfall;
}

my $summe = 0;
$summe += $_ for @fail;

my $mittel = $summe / @fail;

print "Ausfaelle: " . join( ", ", @fail ) . "\n";
print "$summe Sekunden insg. und ";
print "$mittel Sekunden im Mittel pro Ausfall\n";

__DATA__
1 0.000000 84.20.188.80 -> 194.48.124.202 DNS Standard query A www.perl-community.de
2 0.500000 194.48.124.202 -> 84.20.188.80 DNS Standard query response A 92.51.163.38
3 0.500000 84.20.188.80 -> 92.51.163.38 TCP 4808 > http [SYN] Seq=0 Win=65535 Len=0 MSS=1424 TSV=0 TSER=0
4 0.906250 92.51.163.38 -> 84.20.188.80 TCP http > 4808 [SYN, ACK] Seq=0 Ack=1 Win=5840 Len=0 MSS=1424
5 0.906250 84.20.188.80 -> 92.51.163.38 TCP 4808 > http [ACK] Seq=1 Ack=1 Win=65535 Len=0
6 0.906250 84.20.188.80 -> 92.51.163.38 HTTP GET /bat/poard/thread/13706 HTTP/1.1
7 1.828125 92.51.163.38 -> 84.20.188.80 TCP http > 4808 [ACK] Seq=1 Ack=511 Win=6432 Len=0
8 2.609375 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
9 2.625000 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
10 2.625000 84.20.188.80 -> 92.51.163.38 TCP 4808 > http [ACK] Seq=511 Ack=1952 Win=65535 Len=0
11 2.656250 84.20.188.80 -> 92.51.163.38 TCP 4809 > http [SYN] Seq=0 Win=65535 Len=0 MSS=1424 TSV=0 TSER=0
12 2.656250 84.20.188.80 -> 92.51.163.38 TCP 4810 > http [SYN] Seq=0 Win=65535 Len=0 MSS=1424 TSV=0 TSER=0
13 2.656250 84.20.188.80 -> 92.51.163.38 TCP 4811 > http [SYN] Seq=0 Win=65535 Len=0 MSS=1424 TSV=0 TSER=0
14 2.656250 84.20.188.80 -> 92.51.163.38 TCP 4812 > http [SYN] Seq=0 Win=65535 Len=0 MSS=1424 TSV=0 TSER=0
15 2.656250 84.20.188.80 -> 92.51.163.38 TCP 4813 > http [SYN] Seq=0 Win=65535 Len=0 MSS=1424 TSV=0 TSER=0
16 2.703125 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
17 2.718750 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
18 2.718750 84.20.188.80 -> 92.51.163.38 TCP 4808 > http [ACK] Seq=511 Ack=4800 Win=65535 Len=0
19 2.718750 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
20 2.734375 92.51.163.38 -> 84.20.188.80 TCP http > 4809 [SYN, ACK] Seq=0 Ack=1 Win=5840 Len=0 MSS=1424
21 2.734375 84.20.188.80 -> 92.51.163.38 TCP 4809 > http [ACK] Seq=1 Ack=1 Win=65535 Len=0
22 2.734375 84.20.188.80 -> 92.51.163.38 HTTP GET /battie/theme/default/layout.css HTTP/1.1
23 2.750000 92.51.163.38 -> 84.20.188.80 TCP http > 4810 [SYN, ACK] Seq=0 Ack=1 Win=5840 Len=0 MSS=1424
24 2.750000 84.20.188.80 -> 92.51.163.38 TCP 4810 > http [ACK] Seq=1 Ack=1 Win=65535 Len=0
25 2.750000 84.20.188.80 -> 92.51.163.38 HTTP GET /battie/theme/default/color.css HTTP/1.1
26 2.750000 92.51.163.38 -> 84.20.188.80 TCP http > 4811 [SYN, ACK] Seq=0 Ack=1 Win=5840 Len=0 MSS=1424
27 2.750000 84.20.188.80 -> 92.51.163.38 TCP 4811 > http [ACK] Seq=1 Ack=1 Win=65535 Len=0
28 2.750000 84.20.188.80 -> 92.51.163.38 HTTP GET /battie/theme/default/poard.css HTTP/1.1
29 2.781250 92.51.163.38 -> 84.20.188.80 TCP http > 4812 [SYN, ACK] Seq=0 Ack=1 Win=5840 Len=0 MSS=1424
30 2.781250 84.20.188.80 -> 92.51.163.38 TCP 4812 > http [ACK] Seq=1 Ack=1 Win=65535 Len=0
31 2.781250 92.51.163.38 -> 84.20.188.80 TCP http > 4813 [SYN, ACK] Seq=0 Ack=1 Win=5840 Len=0 MSS=1424
32 2.781250 84.20.188.80 -> 92.51.163.38 TCP 4813 > http [ACK] Seq=1 Ack=1 Win=65535 Len=0
33 2.781250 84.20.188.80 -> 92.51.163.38 HTTP GET /battie/theme/default/source-highlight.css HTTP/1.1
34 2.781250 84.20.188.80 -> 92.51.163.38 HTTP GET /battie/js/bbcode_buttons.js HTTP/1.1
35 2.781250 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
36 2.781250 84.20.188.80 -> 92.51.163.38 TCP 4808 > http [ACK] Seq=511 Ack=7648 Win=65535 Len=0
37 2.796875 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
38 2.796875 92.51.163.38 -> 84.20.188.80 TCP [TCP segment of a reassembled PDU]
39 2.796875 84.20.188.80 -> 92.51.163.38 TCP 4808 > http [ACK] Seq=511 Ack=10496 Win=65535 Len=0
40 2.828125 92.51.163.38 -> 84.20.188.80 TCP http > 4809 [ACK] Seq=1 Ack=544 Win=6516 Len=0
41 2.843750 92.51.163.38 -> 84.20.188.80 HTTP HTTP/1.1 304 Not Modified
42 2.843750 92.51.163.38 -> 84.20.188.80 TCP http > 4810 [ACK] Seq=1 Ack=540 Win=6468 Len=0
43 2.859375 92.51.163.38 -> 84.20.188.80 HTTP HTTP/1.1 304 Not Modified
44 2.859375 92.51.163.38 -> 84.20.188.80 TCP http > 4811 [ACK] Seq=1 Ack=543 Win=6504 Len=0
45 2.859375 92.51.163.38 -> 84.20.188.80 HTTP HTTP/1.1 304 Not Modified
46 2.875000 92.51.163.38 -> 84.20.188.80 TCP http > 4812 [ACK] Seq=1 Ack=553 Win=6624 Len=0
47 2.875000 92.51.163.38 -> 84.20.188.80 HTTP HTTP/1.1 304 Not Modified
956601 1259.578125 Send_08 -> Send_08 PPP LCP Termination Request
956602 1259.578125 Receive_08 -> Receive_08 PPP LCP Termination Ack

===================================================================
IO Statistics
Interval: 1.000 secs
Column #0:
| Column #0
Time |frames| bytes
000.000-001.000 6 979
001.000-002.000 1 54
002.000-003.000 56 26719
003.000-004.000 26 7318
004.000-005.000 0 0
005.000-006.000 0 0
006.000-007.000 0 0
007.000-008.000 0 0
008.000-009.000 0 0
009.000-010.000 0 0
010.000-011.000 3 674
011.000-012.000 100 78646
012.000-013.000 52 21535
013.000-014.000 221 48811
014.000-015.000 95 20487
015.000-016.000 7 1373
016.000-017.000 27 8583
017.000-018.000 0 0
018.000-019.000 0 0
019.000-020.000 0 0
020.000-021.000 0 0
021.000-022.000 9 486
022.000-023.000 0 0
023.000-024.000 14 756
024.000-025.000 0 0
025.000-026.000 0 0
026.000-027.000 0 0
027.000-028.000 1 54
028.000-029.000 0 0
029.000-030.000 0 0
030.000-031.000 0 0
031.000-032.000 6 324
032.000-033.000 2 48
033.000-034.000 0 0
034.000-035.000 0 0
035.000-036.000 0 0
036.000-037.000 0 0
037.000-038.000 0 0
038.000-039.000 0 0
039.000-040.000 0 0
040.000-041.000 0 0
041.000-042.000 0 0
042.000-043.000 14 476
043.000-044.000 2 96
044.000-045.000 2 96
045.000-046.000 2 96
046.000-047.000 21 1483
047.000-048.000 305 290810
048.000-049.000 820 798648
049.000-050.000 812 792200

output:Use of uninitialized value $data in pattern match (m//) at while.pl line 13, <DA
TA> line 106.
Illegal division by zero at while.pl line 20, <DATA> line 106.


Last edited: 2009-07-13 13:14:19 +0200 (CEST)

View full thread Berechnung der Laenge von Unterbrechungen im HSDPA netz