-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathhappy.1
135 lines (126 loc) · 5.43 KB
/
happy.1
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
.\" This is a comment
.\" Contact [email protected]
.TH man 1 "30 October 2014" ".1" "Man Page Example"
.SH NAME
happy \- happy eyeballs probing tool
.SH SYNOPSIS
.BR happy " [" \-abcms "] [" "\-p port" "] [" "\-q nqueries" "] [" "\-t timeout" "] [" "\-d delay" "] [" "\-f file" "] " target "..."
.SH DESCRIPTION
.I happy
is a TCP happy eyeballs probing tool. It uses non-blocking connect()
calls to establish connections concurrently to a number of possible
endpoints. This tool is particularly useful to determine whether happy
eyeball applications will use IPv4 or IPv6 if both are available.
.PP
A common interactive usage is in combination with watch(1):
.PP
watch -d -- happy -s www.google.com www.bing.com www.yahoo.com
.SH OPTIONS
.TP
.B -a
Generate detailed information about the name resolution. For each
endpoint of a target, list the canonical name and the reverse mapping
of the endpoint.
.TP
.B -b
For each endpoint of a target, send a sequence of HTTP requests in
order to determine the data rate at which the server returns
responses.
.TP
.B -c
Measure the connection establishment time to each endpoint of a target
using non-blocking connect() calls. This is the default if no other
measurements are selected.
.TP
.BI \-d " delay"
Set the delay between TCP connection attempts to
.I delay
milliseconds. The default is 25 milliseconds.
.TP
.BI \-f " file"
Read the targets from the
.I file
or from standard input if the file name is a single dash (`-').
.TP
.B -m
Produce more compact machine readable output. The output for a given
target consists of multiple lines, one line for each endpoint of the
target. Each line has a list of values separated by semicolons (';').
And example might look like this:
HAPPY.0;1360356320;OK;www.ietf.org;80;2001:1890:126c::1:1e;179411
HAPPY.0;1360356320;OK;www.ietf.org;80;64.170.98.30;172964
The first value is the string HAPPY.0 (indicates happy version 0). The
second value is a timestamp (seconds since 1970-01-01) indicating when
this test was executed. The third value indicates whether the test for
this particular endpoint was successfully executed (OK) or whether the
test could not be executed (FAIL), e.g., because the program did run
out of socket descriptors. Values four and five indicate the target
name and port number while the sixth value carries the IP address of
the endpoint. The remaining values report the measured connection
establishment time (in microseconds) or the recorded timeout time (in
negative microseconds). As such, it is important to pay attention to
sign of the values.
It the -b option is used, then the machine readable output will
contain lines that list the data rate measured. An example might look
like this:
PUMP.0;1388237987;OK;www.ietf.org;80;2001:1900:3001:11::2c;109.000;151.000
PUMP.0;1388237987;OK;www.ietf.org;80;4.31.198.44;118.000;561.000
The first value is the string PUMP.0 (indicates pump version 0). The
second value is a timestamp (seconds since 1970-01-01) indicating when
this test was executed. The third value indicates whether the test for
this particular endpoint was successfully executed (OK) or whether the
test could not be executed (FAIL), e.g., because the program did run
out of socket descriptors. Values four and five indicate the target
name and port number while the sixth value carries the IP address of
the endpoint. The remaining values report the number of bytes per
second pumped to the web server and the number of bytes per second
received from the web server.
If the -a option is used, then the machine readable output will
contain lines that show detailed information about the DNS resolution.
An example might look like this:
DNS.0;1413040293;OK;www.facebook.com;2a03:2880:f01c:d01:face:b00c::1;star.c10r.facebook.com;edge-star6-shv-14-fra3.facebook.com
DNS.0;1413040293;OK;www.facebook.com;173.252.120.6;star.c10r.facebook.com;edge-star-shv-12-frc3.facebook.com
The first value is the string DNS.0 (indicates dns version 0). The
second value is a timestamp (seconds since 1970-01-01) indicating when
this test was executed. The third value indicates whether the test for
this particular endpoint was successfully executed (OK) or whether the
test could not be executed (FAIL). Values four and five indicate the
target name and the associated endpoint. The sixth value is canonical
name (if any) and the last value shows the reverse name for the
endpoint.
.TP
.B -s
Sort the results for all endpoints of a given target. Sorting is based
on the average time it took to establish TCP connections. (Failed attempts
are ignored.)
.TP
.BI \-p " port"
Establish TCP connections to the given
.I port
instead of the default port 80. This option can be used multiple times
to probe multiple port simultaneously.
.TP
.BI \-q " nqueries"
Run
.I nqueries
attempts to establish a TCP connection for each IP address of the
given targets. The default is 3 attempts.
.TP
.BI \-t " timeout"
Set the timeout to
.I timeout
milliseconds. The default is 2000 milliseconds (= 2 seconds).
.SH SEE ALSO
watch (1), RFC 6555
.SH LIMITATIONS
The tool does not check whether the endpoints of a given target all
provide the same service. Hence, it is possible to impact the results
by setting up 'fake' servers that do not provide the service tested and
which are designed and deployed with the only purpose to provide fast
connection setup times.
.SH BUGS
Likely, but we will try to fix them if we can reproduce them.
.SH AUTHOR
Juergen Schoenwaelder <[email protected]>
.br
Vaibhav Bajpai <[email protected]>