File: doveadm-kick.1

package info (click to toggle)
dovecot 1%3A2.4.1%2Bdfsg1-6
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 46,224 kB
  • sloc: ansic: 596,204; makefile: 7,825; sh: 6,005; cpp: 1,866; perl: 487; yacc: 412; lex: 320; python: 253; xml: 232
file content (214 lines) | stat: -rw-r--r-- 5,316 bytes parent folder | download
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
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
.TH "DOVEADM-KICK" "1" "March 2025" "78ffb79" "Dovecot"
.SH "NAME"
\fBdoveadm-kick\fR - Disconnect users by user name and/or IP address
.SH "SYNOPSIS"
.P
\fBdoveadm\fR \[lB]\fIGLOBAL OPTIONS\fR\[rB] \fBkick\fR \[lB]\fB-a\fR \fIanvil_socket_path\fR\[rB] \[lB]\fB-f\fR \fIpassdb_field\fR\[rB] \[lB]\fB-h\fR \fIdest_host\fR\[rB] \fIuser_mask\fR
.P
\fBdoveadm\fR \[lB]\fIGLOBAL OPTIONS\fR\[rB] \fBkick\fR \[lB]\fB-a\fR \fIanvil_socket_path\fR\[rB] \[lB]\fB-f\fR \fIpassdb_field\fR\[rB] \[lB]\fB-h\fR \fIdest_host\fR\[rB] \fIip\fR \[lB]\fB/\fR \fIbits\fR\[rB]
.P
\fBdoveadm\fR \[lB]\fIGLOBAL OPTIONS\fR\[rB] \fBkick\fR \[lB]\fB-a\fR \fIanvil_socket_path\fR\[rB] \[lB]\fB-f\fR \fIpassdb_field\fR\[rB] \[lB]\fB-h\fR \fIdest_host\fR\[rB] \fIuser_mask\fR \fIip\fR \[lB]\fB/\fR \fIbits\fR\[rB]
.P
\fBdoveadm\fR \[lB]\fIGLOBAL OPTIONS\fR\[rB] \fBkick\fR \[lB]\fB-a\fR \fIanvil_socket_path\fR\[rB] \[lB]\fB-f\fR \fIpassdb_field\fR\[rB] \fB-h\fR \fIdest_host\fR
.SH "DESCRIPTION"
.P
\fBdoveadm\fR's \fBkick\fR command is used to disconnect users by \fIuser_mask\fR and/or the \fIip\fR address, from which they are connected.
.P
In the first form, all users, whose login name matches the \fIuser_mask\fR argument, will be disconnected.
.P
In the second form, all users, connected from the given IP address or network range, will be disconnected.
.P
In the third form, only users connected from the given IP address or networks range and a matching login name will be disconnected.
.P
In the last form, all proxy connections to the given destination host are disconnected.
.SH "GLOBAL OPTIONS"
.P
Global doveadm(1) 
.P
\fB-D\fR
.RS 0
.RS 4
.P
Enables \fIverbosity\fR and debug messages.
.RE 0

.RE 0

.P
\fB-O\fR
.RS 0
.RS 4
.P
Do not read any config file, just use defaults. The \fBdovecot_storage_version\fR setting defaults to the latest version, but can be overridden with 
.RE 0

.RE 0

.P
\fB-k\fR
.RS 0
.RS 4
.P
Preserve entire environment for doveadm, not just \fBimport_environment\fR setting.
.RE 0

.RE 0

.P
\fB-v\fR
.RS 0
.RS 4
.P
Enables verbosity, including progress counter.
.RE 0

.RE 0

.P
\fB-i\fR \fIinstance-name\fR
.RS 0
.RS 4
.P
If using multiple Dovecot instances, choose the config file based on this instance name.
.P
See \fBinstance_name\fR setting for more information.
.RE 0

.RE 0

.P
\fB-c\fR \fIconfig-file\fR
.RS 0
.RS 4
.P
Read configuration from the given \fIconfig-file\fR. By default it first reads config socket, and then falls back to \fI/etc/dovecot/dovecot.conf\fR. You can also point this to config socket of some instance running compatible version.
.RE 0

.RE 0

.P
\fB-o\fR \fIsetting\fR\fB=\fR\fIvalue\fR
.RS 0
.RS 4
.P
Overrides the configuration \fIsetting\fR from \fI/etc/dovecot/dovecot.conf\fR and from the userdb with the given \fIvalue\fR. In order to override multiple settings, the \fB-o\fR option may be specified multiple times.
.RE 0

.RE 0

.SH "OPTIONS"
.P
\fB-a\fR \fIanvil_socket_path\fR
.RS 0
.RS 4
.P
This option is used to specify an absolute path to an alternative UNIX domain socket.
.P
By default doveadm(1) will use the socket 
.RE 0

.RE 0

.P
\fB-f\fR \fIpassdb_field\fR
.RS 0
.RS 4
.P
Alternative username field to use for kicking, as returned by passdb. Only the passdb fields beginning with the \fIuser_\fR prefix are tracked.
.RE 0

.RE 0

.P
\fB-h\fR \fIdest_host\fR
.RS 0
.RS 4
.P
Disconnect proxy connections to the given \fIdest_host\fR.
.RE 0

.RE 0

.SH "ARGUMENTS"
.P
\fIip\fR \[lB]/\fIbits\fR\[rB]
.RS 0
.RS 4
.P
\fIip\fR or \fIip\fR \fB/\fR \fIbits\fR is the host or network, from which the users are connected.
.RE 0

.RE 0

.P
\fIuser_mask\fR
.RS 0
.RS 4
.P
Is a user's login name, or the alternative username (user_* field) if the \fB-f\fR parameter is used. Depending on the configuration, a login name may be for example \fBjane\fR or \fBjohn@example.com\fR. It's also possible to use '*\fB\fB' and '\fB?\fR' wildcards (e.g. -u *@example.org).
.RE 0

.RE 0

.SH "EXAMPLE"
.P
If you don't want to disconnect all users at once, you can check who's currently logged in. The first example demonstrates how to disconnect all users whose login name is 3 characters long and begins with \fBba\fR:
.P
.RS 2
.nf
doveadm who -1 ja\[rs]*
.fi
.RE
.P
.RS 2
.nf
username                      service pid ip
jane                          imap   8192 ::1
jano                          imap   8196 ::2
james                         imap   8203 2001:db8:543:2::1
.fi
.RE
.P
.RS 2
.nf
doveadm kick jan?
# The connections for jane and jano are kicked.
.fi
.RE
.P
The next example shows how to kick user foo's connections from 192.0.2.*:
.P
.RS 2
.nf
doveadm who -1 foo
.fi
.RE
.P
.RS 2
.nf
username                     service pid ip
foo                          imap   8135 fd95:4eed:38ba::25
foo                          imap   9112 192.0.2.53
foo                          imap   8216 192.0.2.111
.fi
.RE
.P
.RS 2
.nf
doveadm kick foo 192.0.2.0/24
doveadm who f\[rs]*
.fi
.RE
.P
.RS 2
.nf
username                  # service (pids) (ips)
foo                       1 imap    (8135) (fd95:4eed:38ba::25)
.fi
.RE
.SH "REPORTING BUGS"
.P
Report bugs, including \fIdoveconf -n\fR output, to the Dovecot Mailing List \fI\(ladovecot@dovecot.org\(ra\fR. Information about reporting bugs is available at: https://dovecot.org/bugreport.html
.SH "SEE ALSO"
.P
doveadm(1)