]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - share/man/man4/vale.4
Remove $FreeBSD$: two-line nroff pattern
[FreeBSD/FreeBSD.git] / share / man / man4 / vale.4
1 .\" Copyright (c) 2012 Luigi Rizzo, Universita` di Pisa
2 .\" All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 .\" SUCH DAMAGE.
24 .\"
25 .\" This document is derived in part from the enet man page (enet.4)
26 .\" distributed with 4.3BSD Unix.
27 .\" $Id: $
28 .\"
29 .Dd March 6, 2022
30 .Dt VALE 4
31 .Os
32 .Sh NAME
33 .Nm vale
34 .Nd a very fast Virtual Local Ethernet using the netmap API
35 .Sh SYNOPSIS
36 .Cd device netmap
37 .Sh DESCRIPTION
38 .Nm
39 is a feature of the
40 .Xr netmap 4
41 module that implements multiple Virtual switches that can
42 be used to interconnect netmap clients, including traffic
43 sources and sinks, packet forwarders, userspace firewalls,
44 and so on.
45 .Pp
46 .Nm
47 is implemented completely in software, and is extremely fast.
48 On a modern machine it can move almost 20 Million packets per
49 second (Mpps) per core with small frames, and about 70 Gbit/s
50 with 1500 byte frames.
51 .Sh OPERATION
52 .Nm
53 dynamically creates switches and ports as clients connect
54 to it using the
55 .Xr netmap 4
56 API.
57 .Pp
58 .Nm
59 ports are named
60 .Pa valeSSS:PPP
61 where
62 .Pa vale
63 is the prefix indicating a VALE switch rather than a standard interface,
64 .Pa SSS
65 indicates a specific switch (the colon is a separator),
66 and
67 .Pa PPP
68 indicates a port within the switch.
69 Both SSS and PPP have the form [0-9a-zA-Z_]+ , the string cannot
70 exceed IFNAMSIZ characters, and PPP cannot be the name of any
71 existing OS network interface.
72 .Pp
73 See
74 .Xr netmap 4
75 for details on the API.
76 .Ss LIMITS
77 .Nm
78 currently supports up to 254 ports per switch. The maximum
79 number of switches is provided by the max_bridges sysctl variable.
80 .Sh SYSCTL VARIABLES
81 See
82 .Xr netmap 4
83 for a list of sysctl variables that affect
84 .Nm
85 bridges.
86 .Sh EXAMPLES
87 Create one switch, with a traffic generator connected to one
88 port, and a netmap-enabled tcpdump instance on another port:
89 .Bd -literal -offset indent
90 tcpdump -ni valea:1 &
91 pkt-gen  -i valea:0 -f tx &
92 .Ed
93 .Pp
94 Create two switches,
95 each connected to two qemu machines on different ports.
96 .Bd -literal -offset indent
97 qemu -net nic -net netmap,ifname=vale1:a ... &
98 qemu -net nic -net netmap,ifname=vale1:b ... &
99 qemu -net nic -net netmap,ifname=vale2:c ... &
100 qemu -net nic -net netmap,ifname=vale2:d ... &
101 .Ed
102 .Sh SEE ALSO
103 .Xr netmap 4
104 .Pp
105 Luigi Rizzo, Giuseppe Lettieri: VALE, a switched ethernet for virtual machines,
106 June 2012, http://info.iet.unipi.it/~luigi/vale/
107 .Sh AUTHORS
108 .An -nosplit
109 The
110 .Nm
111 switch was designed and implemented in 2012 by
112 .An Luigi Rizzo
113 and
114 .An Giuseppe Lettieri
115 at the Universita` di Pisa.
116 .Pp
117 .Nm
118 was funded by the European Commission within FP7 Projects
119 CHANGE (257422) and OPENLAB (287581).