xref: /freebsd/usr.sbin/traceroute6/traceroute6.8 (revision fe75646a0234a261c0013bf1840fdac4acaf0cec)
1.\"	$KAME: traceroute6.8,v 1.10 2004/06/06 12:35:15 suz Exp $
2.\"
3.\" Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\" 3. Neither the name of the project nor the names of its contributors
15.\"    may be used to endorse or promote products derived from this software
16.\"    without specific prior written permission.
17.\"
18.\" THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
19.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE
22.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28.\" SUCH DAMAGE.
29.\"
30.Dd October 25, 2023
31.Dt TRACEROUTE6 8
32.Os
33.\"
34.Sh NAME
35.Nm traceroute6
36.Nd "print the route IPv6 packets will take to a network node"
37.\"
38.Sh SYNOPSIS
39.Nm
40.Bk -words
41.Op Fl adEIlnNrSTUv
42.Ek
43.Bk -words
44.Op Fl f Ar firsthop
45.Ek
46.Bk -words
47.Op Fl g Ar gateway
48.Ek
49.Bk -words
50.Op Fl m Ar hoplimit
51.Ek
52.Bk -words
53.Op Fl p Ar port
54.Ek
55.Bk -words
56.Op Fl q Ar probes
57.Ek
58.Bk -words
59.Op Fl s Ar src
60.Ek
61.Bk -words
62.Op Fl t Ar tclass
63.Ek
64.Bk -words
65.Op Fl w Ar waittime
66.Ek
67.Bk -words
68.Op Fl A Ar as_server
69.Ek
70.Bk -words
71.Ar target
72.Op Ar datalen
73.Ek
74.\"
75.Sh DESCRIPTION
76The
77.Nm
78utility
79uses the IPv6 protocol hop limit field to elicit an ICMPv6 TIME_EXCEEDED
80response from each gateway along the path to some host.
81.Pp
82The only mandatory parameter is the destination host name or IPv6 address.
83The default probe datagram carries 20 bytes of payload,
84in addition to the IPv6 header.
85The size of the payload can be specified by giving a length
86(in bytes)
87after the destination host name.
88.Pp
89Other options are:
90.Bl -tag -width Ds
91.It Fl a
92Turn on AS# lookups for each hop encountered.
93.It Fl A Ar as_server
94Turn on AS# lookups and use the given server instead of the default.
95.It Fl d
96Debug mode.
97.It Fl E
98Detect ECN bleaching.
99Set the
100.Em IPTOS_ECN_ECT1
101Explicit Congestion Notification (ECN) bits
102.Pq Dv 01 ,
103and report if the hop has bleached
104.Pq Dv 00
105or mangled
106.Pq Dv 10
107them, or if it is experiencing congestion
108.Pq Dv 11 .
109Otherwise, report that it passed the bits appropriately.
110If
111.Fl t
112is also specified, the corresponding ECN bits will be replaced.
113.It Fl f Ar firsthop
114Specify how many hops to skip in trace.
115.It Fl g Ar gateway
116Specify intermediate gateway.
117Please note that
118.Nm
119tries to use routing headers.
120.It Fl I
121Use ICMP6 ECHO instead of UDP datagrams.
122.It Fl l
123Print both host hostnames and numeric addresses.
124Normally
125.Nm
126prints only hostnames if
127.Fl n
128is not specified, and only numeric addresses if
129.Fl n
130is specified.
131.It Fl m Ar hoplimit
132Specify maximum hoplimit, up to 255.
133The default is the value of the
134.Va net.inet6.ip6.hlim
135.Xr sysctl 8
136(the same default used for TCP connections).
137.It Fl n
138Do not resolve numeric address to hostname.
139.It Fl N
140Use a packet with no upper layer header for the probes,
141instead of UDP datagrams.
142.It Fl p Ar port
143Set SCTP/TCP/UDP port number to
144.Ar port .
145.It Fl q Ar probes
146Set the number of probe per hop count to
147.Ar probes .
148.It Fl r
149Bypass the normal routing tables and send directly to a host
150on an attached network.
151If the host is not on a directly-connected network,
152an error is returned.
153This option corresponds to the
154.Dv SO_DONTROUTE
155socket option;
156it can be used to ping a local host through an interface
157that has no route through it
158(e.g., after the interface was dropped by a routing daemon).
159.It Fl s Ar src
160.Ar Src
161specifies the source IPv6 address to be used.
162.It Fl S
163Use SCTP packets for the probes.
164The size of probe packets must be a multiple of 4.
165If
166.Ar datalen
167is up to 28, probe packets consist of a SHUTDOWN-ACK chunk possibly bundled
168with a PAD chunk.
169For larger probe packets, an INIT chunk is used.
170.It Fl t Ar tclass
171.Ar tclass
172specifies the
173.Em traffic class
174used when sending probe packets.
175The value must be a decimal integer in the range 0 to 255.
176The default is 0.
177.It Fl T
178Use TCP segments for the probes.
179.It Fl U
180Use UDP datagrams for the probes.
181This is the default.
182.It Fl v
183Be verbose.
184.It Fl w Ar waittime
185Specify the delay time between probes.
186.El
187.Pp
188This program prints the route to the given destination and the round-trip
189time to each gateway, in the same manner as traceroute.
190.Pp
191Here is a list of possible annotations after the round-trip time for each gateway:
192.Bl -hang -offset indent
193.It !N
194Destination Unreachable - No Route to Host.
195.It !P
196Destination Unreachable - Administratively Prohibited.
197.It !S
198Destination Unreachable - Not a Neighbour.
199.It !A
200Destination Unreachable - Address Unreachable.
201.It !H
202Parameter Problem - Unrecognized Next Header Type.
203.It !\&
204This is printed if the hop limit is <= 1 on a port unreachable message.
205This means that the packet got to the destination,
206but that the reply had a hop limit that was just large enough to
207allow it to get back to the source of the traceroute6.
208This was more interesting in the IPv4 case,
209where some IP stack bugs could be identified by this behaviour.
210.El
211.\"
212.Sh EXIT STATUS
213The
214.Nm
215utility will exit with 0 on success, and non-zero on errors.
216.\"
217.Sh SEE ALSO
218.Xr ping 8 ,
219.Xr traceroute 8
220.\"
221.Sh HISTORY
222The
223.Nm
224utility first appeared in WIDE hydrangea IPv6 protocol stack kit.
225