1: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
2: <HTML>
3: <HEAD>
4: <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
5: <TITLE>General mpd commands</TITLE>
6: </HEAD>
7: <BODY text="#000000" bgcolor="#ffffff">
8:
9: <A HREF="mpd.html"><EM>Mpd 5.9 User Manual</EM></A>
10: <b>:</b> <A HREF="mpd17.html"><EM>Configuring Mpd</EM></A>
11: <b>:</b> <EM>General mpd commands</EM><BR>
12: <b>Previous:</b> <A HREF="mpd17.html"><EM>Configuring Mpd</EM></A><BR>
13: <b>Next:</b> <A HREF="mpd19.html"><EM>Mpd Layers</EM></A>
14:
15:
16: <HR NOSHADE>
17: <H2><A NAME="18"></A>4.1. General mpd commands<A NAME="gencmd"></A></H2>
18:
19: <p>This chapter describes general mpd commands that do not
20: apply to a specific layer.</p>
21: <p>
22: <dl>
23:
24: <dt><b><code>create bundle [ template | static ] <em>name</em> [ <em>template</em> ] </code></b><dd><p>Create new bundle with specified name, optionally based on specified template.
25: If 'template' option is specified, bundle will not operate itself,
26: but will be used to create new bundles on demand.
27: If 'static' option is specified, it will be a permanent bundle which will not
28: disappear after operation completes.
29: Maximum name length is 10 characters for templates and 15 characters
30: for the rest of bundles.</p>
31:
32: <dt><b><code>create link [ template | static ] <em>name</em> ( <em>type</em> | <em>template</em> ) </code></b><dd><p>Create new link with specified name and type, optionally based on
33: specified template.
34: If 'template' option is specified, link will not operate itself,
35: but will be used to create new links on demand.
36: If 'static' option is specified, it will be a permanent link which will not
37: disapear after operation complete.
38: Maximum name length is 10 characters for templates and 15 characters
39: for the rest of links.</p>
40:
41: <dt><b><code><br>destroy bundle [ <em>name</em> ]<br>
42: destroy link [ <em>name</em> ]</code></b><dd><p>Destroy existing link/bundle.
43: Note that if link is in use, it may not disapear after command returns,
44: it may take some time to properly close it.</p>
45:
46: <dt><b><code>bundle [ <em>name</em> ] </code></b><dd><p>This command changes the currently active bundle to the bundle named
47: <code><em>name</em></code>. The currently active link is also
48: changed, to the first link of the bundle. If no
49: <code><em>name</em></code> is given, this command lists all
50: of the defined bundles and their constituent links.
51: The new bundle will be reflected in the prompt.</p>
52:
53: <dt><b><code>link [ <em>name</em> | <em>[number]</em> ] </code></b><dd><p>This command changes the currenly active link to the link named
54: <code><em>name</em></code>. If this link does not belong to
55: the currently active bundle, then the currently active bundle
56: is changed to the bundle that owns link <code><em>name</em></code>.
57: The new link will be reflected in the prompt.
58: Link <em>number</em> (RAD_NAS_PORT) can be specified in hex form in
59: square brackets in place of name.</p>
60:
61: <dt><b><code>repeater [ <em>name</em> ] </code></b><dd><p>This command changes the currenly active repeater to the repeater named
62: <code><em>name</em></code>. The currently active phys is also
63: changed, to the first phys of the repeater. If no
64: <code><em>name</em></code> is given, this command lists all
65: of the defined repeaters and their constituent physes.
66: The new phys will be reflected in the prompt.</p>
67:
68: <dt><b><code>iface [ <em>iface</em> ] </code></b><dd><p>This command changes the currenly active bundle to the bundle using
69: interface <code><em>iface</em></code>.</p>
70:
71: <dt><b><code>msession [ <em>msesid</em> ] </code></b><dd><p>This command changes the currenly active bundle to the bundle holding
72: session with multilink session ID <code><em>msesid</em></code>.</p>
73:
74: <dt><b><code>session [ <em>sesid</em> ] </code></b><dd><p>This command changes the currenly active link to the link holding
75: session with session ID <code><em>sesid</em></code>.</p>
76:
77: <dt><b><code>authname [ <em>name</em> ] </code></b><dd><p>This command changes the currenly active link to the link holding
78: session with peer auth name <code><em>name</em></code>. If CI argument is present
79: login comparasion will be case insensitive.</p>
80:
81: <dt><b><code>load [ <em>file</em> ] <em>label</em></code></b><dd><p>This command causes mpd to read the entry for <code><em>label</em></code>
82: out of <code>mpd.conf</code> or other file if specified and
83: execute the corresponding commands. <em>file</em> can be relative
84: or absolute file path or http/https/ftp URL. Note, that remote file
85: access may be less reliable.</p>
86:
87: <dt><b><code>show [ <em>item</em> ] </code></b><dd><p>This command displays various status information. The valid
88: values for <code><em>item</em></code> are:</p>
89: <p>
90: <dl>
91:
92: <dt><b>bundle</b><dd><p>Show status information about the currently active bundle.</p>
93: <dt><b>link</b><dd><p>Show status information about the currently active link.</p>
94: <dt><b>repeater</b><dd><p>Show status information about the currently active repeater.</p>
95: <dt><b>iface</b><dd><p>Show status information about the interface layer associated
96: with the currently active bundle.</p>
97: <dt><b>routes</b><dd><p>Show the current IP routing table.</p>
98: <dt><b>ipcp</b><dd><p>Show status information about the IP control
99: protocol associated with the currently active bundle.</p>
100: <dt><b>ippool</b><dd><p>Show status information about configures IP pools.</p>
101: <dt><b>ccp</b><dd><p>Show status information about the compression control
102: protocol associated with the currently active bundle.</p>
103: <dt><b>lcp</b><dd><p>Show status information about the link control
104: protocol associated with the currently active link.</p>
105: <dt><b>nat</b><dd><p>Show information about NAT on the currently active bundle.</p>
106: <dt><b>auth</b><dd><p>Show status information about Authentication.</p>
107: <dt><b>eap</b><dd><p>Show status information about EAP.</p>
108: <dt><b>radius</b><dd><p>Information relating to RADIUS authentication.</p>
109: <dt><b>proto</b><dd><p>Show protocol statistics for the currently active bundle and link.</p>
110: <dt><b>types</b><dd><p>Show the device types supported by this version of mpd.</p>
111: <dt><b>layers</b><dd><p>Show the names of the layers that are valid as arguments to the <code>open</code>
112: and <code>close</code> commands.</p>
113: <dt><b>l2tp</b><dd><p>Show active L2TP tunnels.</p>
114: <dt><b>pptp</b><dd><p>Show active PPTP tunnels.</p>
115: <dt><b>events</b><dd><p>Show all pending events (for debugging mpd).</p>
116: <dt><b>mem</b><dd><p>Show distribution of dynamically allocated memory (for debugging mpd).</p>
117: <dt><b>version</b><dd><p>Show running mpd version and supported features.</p>
118: <dt><b>sessions [ <em>param</em> <em>value</em> ]</b><dd><p>Show active sessions conforming specified param/value.
119: Available params: iface, ip, bundle, msession, link, session, user, peer.</p>
120: <dt><b>customer</b><dd><p>Show active customer details.</p>
121: <dt><b>summary</b><dd><p>Show status summary.</p>
122: <dt><b>console</b><dd><p>Show console summary.</p>
123: <dt><b>web</b><dd><p>Show web server summary.</p>
124: <dt><b>user</b><dd><p>Show defined console users.</p>
125: <dt><b>netflow</b><dd><p>Show status information about NetFlow.</p>
126:
127: </dl>
128: </p>
129:
130: <dt><b><code>set ...</code></b><dd>
131: <p>This command sets various configuration information. Further
132: details are contained in later sections in this chapter.
133: The valid completions for <code>set</code> are:</p>
134: <p>
135: <dl>
136:
137: <dt><b><code>set global startrule <em>num</em><br>
138: set global startpipe <em>num</em><br>
139: set global startqueue <em>num</em><br>
140: set global starttable <em>num</em></code></b><dd><p>These commands define initial values for autonumeration of ipfw
141: rules, pipes, queues and tables.
142: Defaults are 10000, 10000, 10000 and 32 accordingly.</p>
143:
144: <dt><b><code>set global pptptimeout <em>seconds</em><br>
145: set global l2tptimeout <em>seconds</em></code></b><dd><p>Set PPTP/L2TP tunnels inactivity shutdown delay.</p>
146: <p>Default is 10 seconds.</p>
147:
148: <dt><b><code>set global pptplimit <em>num</em><br>
149: set global l2tplimit <em>num</em></code></b><dd><p>Limit maximum number of calls per PPTP/L2TP tunnel. When limit
150: is reached new tunnel will be created for the next call.
151: This option violates PPTP RFC which requires only one tunnel existing
152: for the PAC/PNS pair, but it can increase busy tunnels stability.</p>
153: <p>Defaults are 100 (10 for L2TP before FreeBSD 6.3-STABLE and 7.0-RELEASE).</p>
154:
155: <dt><b><code>set global max-children <em>num</em></code></b><dd><p>This option specifies global maximum number of links, created using
156: template, that could exist at the same time.</p>
157: <p>The default value is 10000.</p>
158:
159: <dt><b><code>set global qthreshold <em>min</em> <em>max</em></code></b><dd><p>This option specifies global message queue limit thresholds.</p>
160: <p>The default values are 64 and 256.</p>
161:
162: <dt><b><code>set global filter <em>num</em> add <em>fltnum</em> <em>flt</em><br>
163: set global filter <em>num</em> clear</code></b><dd><p>These commands define or clear traffic filters to be used by rules submitted
164: by
165: <A HREF="mpd30.html#radius">AAA</A> during authentication.</p>
166:
167: <dt><b><code>set global enable <em>option ...</em><br>
168: set global disable <em>option ...</em></code></b><dd><p>These commands configure various global options.</p>
169:
170: <p>The <code><b>enable</b></code> and <code><b>disable</b></code> commands
171: determine whether or not we want the corresponding option.</p>
172: <p>The options available are:</p>
173:
174: <dt><b><code>one-shot</code></b><dd><p>This option forces mpd terminate itself after the last link disappear.
175: Link templates are not counted as links.</p>
176: <p>The default is disable.</p>
177:
178: <dt><b><code>tcp-wrapper</code></b><dd><p>With this option mpd uses <code>/etc/hosts.allow</code> everytime a
179: connection is made from the client. This is useful if you would
180: like to restrict access to mpd. This option affects all TCP
181: connections, including PPTP and the TCP device layer.</p>
182: <p>The default is disable.</p>
183:
184: <dt><b><code>agent-cid</code></b><dd><p>Display PPPoE <em>ADSL-Agent-Circuit-Id</em> option in
185: <em>show session</em> command.</p>
186: <p>The default is disable.</p>
187:
188: <dt><b><code>session-time</code></b><dd><p>Display session time in seconds in <em>show session</em>
189: command.</p>
190: <p>The default is disable.</p>
191:
192: <dt><b><code>set user <em>username</em> <em>password</em>
193: [<em>admin</em>|<em>operator</em>|<em>user</em>]</code></b><dd><p>This command configures which users are allowed to connect to the console.
194: It may be invoked multiple times with different usernames.</p>
195:
196: <dt><b><code>set bundle ...</code></b><dd><p>Set bundle layer configuration parameters for the currently active bundle.</p>
197: <dt><b><code>set link ...</code></b><dd><p>Set link layer configuration parameters for the currently active link.</p>
198: <dt><b><code>set iface ...</code></b><dd><p>Set interface layer configuration parameters for the currently active bundle.</p>
199: <dt><b><code>set nat ...</code></b><dd><p>Set NAT configuration parameters for the currently active bundle.</p>
200: <dt><b><code>set ipcp ...</code></b><dd><p>Set IP control protocol configuration parameters
201: for the currently active bundle.</p>
202: <dt><b><code>set ccp ...</code></b><dd><p>Set compression control protocol configuration parameters
203: for the currently active bundle.</p>
204: <dt><b><code>set auth ...</code></b><dd><p>Configures the authentication subsystem.</p>
205: <dt><b><code>set radius ...</code></b><dd><p>Configures RADIUS.</p>
206: <dt><b><code>set eap ...</code></b><dd><p>Configures the EAP.</p>
207: <dt><b><code>set debug ...<em>level</em></code></b><dd><p>Sets the <code>netgraph(3)</code> debugging level. Default is zero.</p>
208: <dt><b><code>set modem ...</code></b><dd><p>Sets device specific configuration parameters
209: for the currently active link, which must have type <b>modem</b>.</p>
210: <dt><b><code>set ng ...</code></b><dd><p>Sets device specific configuration parameters
211: for the currently active link, which must have type <b>netgraph</b>.</p>
212: <dt><b><code>set tcp ...</code></b><dd><p>Sets device specific configuration parameters
213: for the currently active link, which must have type <b>tcp</b>.</p>
214: <dt><b><code>set udp ...</code></b><dd><p>Sets device specific configuration parameters
215: for the currently active link, which must have type <b>udp</b>.</p>
216: <dt><b><code>set pptp ...</code></b><dd><p>Sets device specific configuration parameters
217: for the currently active link, which must have type <b>pptp</b>.</p>
218: <dt><b><code>set l2tp ...</code></b><dd><p>Sets device specific configuration parameters
219: for the currently active link, which must have type <b>l2tp</b>.</p>
220: <dt><b><code>set pppoe ...</code></b><dd><p>Sets device specific configuration parameters
221: for the currently active link, which must have type <b>pppoe</b>.</p>
222: <dt><b><code>set console ...</code></b><dd><p>Sets console specific configuration parameters</p>
223: <dt><b><code>set web ...</code></b><dd><p>Sets web server specific configuration parameters</p>
224: </dl>
225: </p>
226:
227: <dt><b><code>unset ...</code></b><dd>
228: <p>This command allows to unsets some of configuration information set using
229: <code>set</code> command.</p>
230:
231: <dt><b><code>open [ <em>layer</em> ] </code></b><dd><p>This command causes an OPEN event to be sent to the corresponding
232: layer or finite state machine (FSM). The valid layers are:</p>
233: <p>
234: <dl>
235: <dt><b>iface</b><dd><p>Interface layer. Opening this layer configures the interface and
236: installs any routes. If dial-on-demand is enabled, nothing else
237: happens until there is outgoing traffic. If dial-on-demand is disabled
238: there no reason to open this layer manually.</p>
239:
240: <dt><b>bund</b><dd><p>Bundle layer. This layer represents the multi-link bundle ``virtual
241: link'' and is normally opened and closed automatically.</p>
242:
243: <dt><b>ipcp</b><dd><p>IP control protocol FSM. This is normally opened and closed automatically.</p>
244:
245: <dt><b>ccp</b><dd><p>Compression control protocol FSM.
246: This is normally opened and closed automatically.</p>
247:
248: <dt><b>link</b><dd><p>Link control protocol FSM. This is default layer for open/close commands.
249: Opening of this layer initiates outgoing call by this link.</p>
250:
251: <dt><b>device</b><dd><p>Device layer.
252: This is normally opened and closed automatically.</p>
253:
254: </dl>
255: </p>
256: <p>Normally, only the <code>iface</code> and <code>link</code> layers should be explicitly
257: opened or closed. This is because the other layers are programmed
258: to automatically open and close when appropriate. Note that
259: the <b>SIGUSR1</b> and <b>SIGUSR2</b> signals are an alternative
260: way to open and close the first link.</p>
261:
262: <dt><b><code>close [ <em>layer</em> ] </code></b><dd><p>This command causes a CLOSE event to be sent to the corresponding
263: layer or finite state machine (FSM).</p>
264:
265: <dt><b><code>log [ <em>+/-flag ...</em> ] </code></b><dd><p>Mpd supports several different logging flags. Every line logged by mpd is
266: tagged with one (or more) of these flags. By turning the flags on or off,
267: that particular type of logging is enabled or disabled. This allows you
268: to customize logging verbosity.</p>
269: <p>Without any arguments, the <code>log</code> command shows the current
270: set of logging flags.
271: To enable a logging flag, add the <code>+<em>flag</em></code> argument.
272: To disable a logging flag, add the <code>-<em>flag</em></code> argument.</p>
273: <p>These are the various flags supported by mpd and their corresponding
274: categories:</p>
275: <p>
276: <dl>
277: <dt><b>auth*</b><dd><p>Link authentication events</p>
278: <dt><b>bund*</b><dd><p>Bundle layer events</p>
279: <dt><b>ccp*</b><dd><p>Compression events and negotiation</p>
280: <dt><b>chat*</b><dd><p>Modem chat script</p>
281: <dt><b>console*</b><dd><p>Log to the console as well as the log file</p>
282: <dt><b>echo</b><dd><p>Echo/reply packets for all FSM's</p>
283: <dt><b>ecp*</b><dd><p>Encryption events and negotiation</p>
284: <dt><b>frame</b><dd><p>Dump all frames transmitted and received</p>
285: <dt><b>fsm*</b><dd><p>All FSM events (except echo and resets)</p>
286: <dt><b>iface*</b><dd><p>Interface layer events</p>
287: <dt><b>ipcp*</b><dd><p>IP control protocol events and negotiation</p>
288: <dt><b>ipv6cp*</b><dd><p>IPv6 control protocol events and negotiation</p>
289: <dt><b>lcp*</b><dd><p>Link control protocol events and negotiation</p>
290: <dt><b>link*</b><dd><p>Link layer events</p>
291: <dt><b>phys*</b><dd><p>Device layer events</p>
292: <dt><b>radius*</b><dd><p>RADIUS authentication events</p>
293: <dt><b>rep*</b><dd><p>Repeater layer events</p>
294: </dl>
295: </p>
296:
297: <dt><b><code>help [ <em>command</em> ] </code></b><dd><p>This gives a brief description of the supplied command, or if
298: an incomplete command is given, lists the available alternatives.</p>
299:
300: <dt><b><code>exit</code></b><dd><p>This command exits the console, but does not quit the mpd process.
301: This command is useful for disconnecting a telnet connection.</p>
302:
303: <dt><b><code>shutdown</code></b><dd><p>Close down all connections and quit the mpd process.</p>
304:
305: </dl>
306: </p>
307:
308: <HR NOSHADE>
309: <A HREF="mpd.html"><EM>Mpd 5.9 User Manual</EM></A>
310: <b>:</b> <A HREF="mpd17.html"><EM>Configuring Mpd</EM></A>
311: <b>:</b> <EM>General mpd commands</EM><BR>
312: <b>Previous:</b> <A HREF="mpd17.html"><EM>Configuring Mpd</EM></A><BR>
313: <b>Next:</b> <A HREF="mpd19.html"><EM>Mpd Layers</EM></A>
314:
315:
316:
317: </BODY>
318: </HTML>
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>