summaryrefslogtreecommitdiff
path: root/usr.sbin/smtpd/smtpctl.8
blob: 638aafc791e7c3980e166a6f9fda52b3d4ff2bdb (plain)
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
.\" $OpenBSD: smtpctl.8,v 1.31 2012/10/14 13:22:33 gilles Exp $
.\"
.\" Copyright (c) 2006 Pierre-Yves Ritschard <pyr@openbsd.org>
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
.Dd $Mdocdate: October 14 2012 $
.Dt SMTPCTL 8
.Os
.Sh NAME
.Nm smtpctl
.Nd control the Simple Mail Transfer Protocol daemon
.Sh SYNOPSIS
.Nm
.Ar command
.Op Ar argument ...
.Sh DESCRIPTION
The
.Nm
program controls
.Xr smtpd 8 .
Commands may be abbreviated to the minimum unambiguous prefix; for example,
.Cm sh s
for
.Cm show stats .
.Pp
The following commands are available:
.Bl -tag -width Ds
.It Cm log brief
Disable verbose debug logging.
.It Cm log verbose
Enable verbose debug logging.
.It Cm pause mda
Temporarily stop deliveries to local users.
.It Cm pause mta
Temporarily stop relaying and deliveries to
remote users.
.It Cm pause smtp
Temporarily stop accepting incoming sessions.
.It Cm remove Ar envelope-id | message-id
Removes a single envelope, or all envelopes with the same message ID.
.It Cm resume mda
Resume deliveries to local users.
.It Cm resume mta
Resume relaying and deliveries to remote users.
.It Cm resume smtp
Resume accepting incoming sessions.
.It Cm schedule-all
Marks all envelopes as ready for immediate delivery.
.It Cm schedule-id Ar envelope-id | message-id
Marks a single envelope, or all envelopes with the same message ID,
as ready for immediate delivery.
.It Cm show envelope Ar envelope-id
Displays envelope's content for the given ID.
.It Cm show message Ar envelope-id
Displays message content for the given ID.
.It Cm show queue
Displays information concerning envelopes
that are currently in a queue.
.It Cm show stats
Displays runtime statistics concerning
.Xr smtpd 8 .
.It Cm update map Ar name
For map backends that provide caching, causes
.Xr smtpd 8
to update the cache.
.El
.Pp
When
.Nm smtpd
receives a message, it generates a
.Ar message-id
for the message, and one
.Ar envelope-id
per recipient.
The
.Ar message-id
is a 32-bit random identifier that is guaranteed to be
unique on the host system.
The
.Ar envelope-id
is a 64-bit unique identifier that encodes the
.Ar message-id
in the 32 upper bits and a random envelope identifier
in the 32 lower bits.
.Pp
A command which specifies a
.Ar message-id
applies to all recipients of a message;
a command which specifies an
.Ar envelope-uid
applies to a specific recipient of a message.
.Sh FILES
.Bl -tag -width "/var/run/smtpd.sockXX" -compact
.It /var/run/smtpd.sock
.Ux Ns -domain
socket used for communication with
.Xr smtpd 8 .
.El
.Sh SEE ALSO
.Xr smtpd 8
.Sh HISTORY
The
.Nm
program first appeared in
.Ox 4.6 .