/
README
152 lines (104 loc) · 5.07 KB
/
README
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
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
# $Id$
IDX-TSUNAMI README
IDEALX
____________________________________________________________
Table of Contents
1. Introduction
1.1 General
1.2 What This Package Is
2. Getting Things Installed
2.1 Dependencies
2.2 Compilation and Installation
2.3 Problems/Bugs
2.4 Platform Issues
______________________________________________________________________
1. Introduction
1.1. General
This document gives pointers for information on this package which is
distributed under the GNU General Public License version 2 (see file
COPYING).
1.2. What This Package Is
The purpose of IDX-TSUNAMI is to simulate users in order to test
the scalability and performances of IP based client/server
applications. Currently, HTTP and Jabber protocol have been
implemented and tested, but it can be easily extended (see
doc/Design.txt). IDX-TSUNAMI use the Erlang language.
This tool can simulate thousands of users concurrently, and can be
distributed on several client machines. Up to 10000 users can be
simulated on a single machine (the limit depends on the hardware and
also on the activity of the simulated clients).
The idea is to simulate the behavior of a real world client using a
stochastic model, in order to achieve a more realistic traffic than
other simple models (deterministics).
In this context, a client's session is characterize by:
- the mean time elapsed between requests ("think time")
- a list of requests during a session
- the type and parameters of requests (including, for example,
'chat' message size for Jabber)
At the end of a session, the client stops.
Another key parameters are the mean time between clients arrival,
and the duration of the test.
In the current implementation, the client arrival rate and the user
"think time" are represented by an exponential distribution
(therefore, the arrival process is a Poisson process). The thinktime
can also be fixed (determinist).
The traffic can be logged to a file and, after completion of
all the clients, these files can be analyzed by scripts to get
useful measurements of responses time. A small script is furnished
for the Jabber protocol (mean, median, standard variation, and so on
are computed, for different types of messages: authentication,
chat, offline messages ...) and generic statistics.
Since v0.2.0, stats are also be computed in real-time, and dumped in
a text file at regular interval. A script is provided to print
graphics using gnuplot.
This software is currently under development and can be enhanced
in many ways (see TODO file).
2. Getting Things Installed
2.1. Dependencies
- tested with Erlang/OTP R9C-0
(http://www.erlang.org/download.html)
- xmerl-0.15 (http://www.erlang.org/user.html#xmerl-0.15)
- gnuplot and perl5 (optional; for graphical output with analyse_msg.pl script)
- for distributed test, you need an ssh access to remote machines
without passwd (use a RSA key without passphrase)
2.2. Compilation and Installation
Edit Makefile if you want to change the install path (prefix)
(/usr/local/idx-tsunami by default)
Edit src/tsunami.rel.src and src/tsunami_controller.rel.src if your
Erlang version is not R9C-0 and set erts, kernel, ssl and stdlib
version according to your Erlang distribution.
make
make install
How to use it:
1a/ Edit $prefix/etc/idx-tsunami.xml file (read the comments for explanation
on the parameters, there is a sample file etc/idx-tsunami_default.xml)
1b/ Read the doc/Jabber.txt file for Jabber-specific information.
2/ use "idx-tsunami start" to launch the simulated clients.
3/ When it's finished, you can use analyse_msg.pl to get
statistical results from the logfiles.
Since v0.2.0, you can have 'realtime' stats using with the
--stats and --plot option (no monitoring needed). It will
generate graphics in postscript using gnuplot. For HTTP, you
MUST use --stats. This option requires a logfile, by default it
is named 'idx-tsunami.log-YYYY:MM:DD-HH:mm'
Every 10sec (default value), stats are dump in the log file,
and the script can create graphics about the current activity.
Availables stats:
- response_time (response time for each request (~ request for HTTP))
- page_resptime (response time for each set of requests (~ page for HTTP))
- connect (duration of the connection)
- reconnect (number of reconnection)
- size (size of responses)
- session (duration of a user's session)
- users (number of simultaneous users)
HTTP specific stats:
- counter for each response status (200, 404, etc.)
- http_bad_content_length (Body is larger than expected)
- http_no_content_length
Since v0.3.0, you can customize statistics using
"transactions" in session definition.
2.3. Problems/Bugs
Submit bug reports/ask questions to the authors (see CONTRIBUTORS)
2.4. Platform Issues
This package has only be tested on Linux. It should work
on Erlang supported platforms (Solaris, *BSD)