summaryrefslogtreecommitdiffstats
path: root/doc/man/knsupdate.1in
blob: 10c0b87f8c196f64e28f740300931ac6ddbc8a32 (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
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
.\" Man page generated from reStructuredText.
.
.TH "KNSUPDATE" "1" "@RELEASE_DATE@" "@VERSION@" "Knot DNS"
.SH NAME
knsupdate \- Dynamic DNS update utility
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.SH SYNOPSIS
.sp
\fBknsupdate\fP [\fIoptions\fP] [\fIfilename\fP]
.SH DESCRIPTION
.sp
This utility sends Dynamic DNS update messages to a DNS server. Update content
is read from a file (if the parameter \fIfilename\fP is given) or from the standard
input.
.sp
The format of updates is textual and is made up of commands. Every command is
placed on the separate line of the input. Lines starting with a semicolon are
comments and are not processed.
.SS Options
.INDENT 0.0
.TP
\fB\-d\fP
Enable debug messages.
.TP
\fB\-h\fP, \fB\-\-help\fP
Print the program help.
.TP
\fB\-k\fP \fIkeyfile\fP
Use the TSIG key stored in a file \fIkeyfile\fP to authenticate the request. The
file should contain the key in the same format, which is accepted by the
\fB\-y\fP option.
.TP
\fB\-p\fP \fIport\fP
Set the port to use for connections to the server (if not explicitly specified
in the update). The default is 53.
.TP
\fB\-r\fP \fIretries\fP
The number of retries for UDP requests. The default is 3.
.TP
\fB\-t\fP \fItimeout\fP
The total timeout (for all UDP update tries) of the update request in seconds.
The default is 12. If set to zero, the timeout is infinite.
.TP
\fB\-v\fP
Use a TCP connection.
.TP
\fB\-V\fP, \fB\-\-version\fP
Print the program version.
.TP
\fB\-y\fP [\fIalg\fP:]\fIname\fP:\fIkey\fP
Use the TSIG key with a name \fIname\fP to authenticate the request. The \fIalg\fP
part specifies the algorithm (the default is hmac\-sha256) and \fIkey\fP specifies
the shared secret encoded in Base64.
.UNINDENT
.SS Commands
.INDENT 0.0
.TP
\fBserver\fP \fIname\fP [\fIport\fP]
Specifies a receiving server of the dynamic update message. The \fIname\fP parameter
can be either a host name or an IP address. If the \fIport\fP is not specified,
the default port is used. The default port value can be controlled using
the \fB\-p\fP program option.
.TP
\fBlocal\fP \fIaddress\fP [\fIport\fP]
Specifies outgoing \fIaddress\fP and \fIport\fP\&. If no local is specified, the
address and port are set by the system automatically. The default port number
is 0.
.TP
\fBzone\fP \fIname\fP
Specifies that all updates are done within a zone \fIname\fP\&. If not used,
the default zone is the root zone.
.TP
\fBorigin\fP \fIname\fP
Specifies fully qualified domain name suffix which is appended to non\-fqd
owners in update commands. The default origin is the root zone.
.TP
\fBclass\fP \fIname\fP
Sets \fIname\fP as the default class for all updates. If not used, the default
class is IN.
.TP
\fBttl\fP \fIvalue\fP
Sets \fIvalue\fP as the default TTL (in seconds). If not used, the default value
is 0.
.TP
\fBkey\fP [\fIalg\fP:]\fIname\fP \fIkey\fP
Specifies the TSIG \fIkey\fP named \fIname\fP to authenticate the request. An optional
\fIalg\fP algorithm can be specified. This command has the same effect as
the program option \fB\-y\fP\&.
.TP
[\fBprereq\fP] \fBnxdomain\fP \fIname\fP
Adds a prerequisite for a non\-existing record owned by \fIname\fP\&.
.TP
[\fBprereq\fP] \fByxdomain\fP \fIname\fP
Adds a prerequisite for an existing record owned by \fIname\fP\&.
.TP
[\fBprereq\fP] \fBnxrrset\fP \fIname\fP [\fIclass\fP] \fItype\fP
Adds a prerequisite for a non\-existing record of the \fItype\fP owned by \fIname\fP\&.
Internet \fIclass\fP is expected.
.TP
[\fBprereq\fP] \fByxrrset\fP \fIname\fP [\fIclass\fP] \fItype\fP [\fIdata\fP]
Adds a prerequisite for an existing record of the \fItype\fP owned by \fIname\fP
with optional \fIdata\fP\&. Internet \fIclass\fP is expected.
.TP
[\fBupdate\fP] \fBadd\fP \fIname\fP [\fIttl\fP] [\fIclass\fP] \fItype\fP \fIdata\fP
Adds a request to add a new resource record into the zone.
Please note that if the \fIname\fP is not fully qualified domain name, the
current origin name is appended to it.
.TP
[\fBupdate\fP] \fBdel\fP[\fBete\fP] \fIname\fP [\fIttl\fP] [\fIclass\fP] [\fItype\fP] [\fIdata\fP]
Adds a request to remove all (or matching \fIclass\fP, \fItype\fP or \fIdata\fP)
resource records from the zone. There is the same requirement for the \fIname\fP
parameter as in \fBupdate add\fP command. The \fIttl\fP item is ignored.
.TP
\fBshow\fP
Displays current content of the update message.
.TP
\fBsend\fP
Sends the current update message and cleans the list of updates.
.TP
\fBanswer\fP
Displays the last answer from the server.
.TP
\fBdebug\fP
Enable debugging. This command has the same meaning as the \fB\-d\fP program option.
.TP
\fBquit\fP
Quit the program.
.UNINDENT
.SH NOTES
.sp
Options \fB\-k\fP and \fB\-y\fP can not be used simultaneously.
.sp
Dnssec\-keygen keyfile format is not supported. Use \fBkeymgr(8)\fP instead.
.sp
Zone name/server guessing is not supported if the zone name/server is not specified.
.sp
Empty line doesn\(aqt send the update.
.SH EXAMPLES
.INDENT 0.0
.IP 1. 3
Send one update of the zone example.com to the server 192.168.1.1. The update
contains two new records:
.INDENT 3.0
.INDENT 3.5
.sp
.nf
.ft C
$ knsupdate
> server 192.168.1.1
> zone example.com.
> origin example.com.
> ttl 3600
> add test1.example.com. 7200 A 192.168.2.2
> add test2 TXT "hello"
> show
> send
> answer
> quit
.ft P
.fi
.UNINDENT
.UNINDENT
.UNINDENT
.SH SEE ALSO
.sp
\fBkdig(1)\fP, \fBkhost(1)\fP, \fBkeymgr(8)\fP\&.
.SH AUTHOR
CZ.NIC Labs <https://www.knot-dns.cz>
.SH COPYRIGHT
Copyright 2010–2019, CZ.NIC, z.s.p.o.
.\" Generated by docutils manpage writer.
.