-- Auto-maintain root TA
trust_anchors.add_file('.local/etc/knot-resolver/root.keys')
--- Large cache size, so we don't need to flush often
--- This can be larger than available RAM, least frequently accessed
--- records will be paged out
cache.size = 1024 * MB
-- Load Useful modules
For large deployments we recommend to run Knot Resolver on a dedicated machine,
and to allocate 90% of machine's free memory for resolver's cache.
+.. note:: Choosing a cache size that can fit into RAM is important even if the
+ cache is stored on disk (default). Otherwise, the extra I/O caused by disk
+ access for missing pages can cause performance issues.
+
For example, imagine you have a machine with 16 GB of memory.
After machine restart you use command ``free -m`` to determine
amount of free memory (without swap):
net.listen('127.0.0.1', 853, { kind = 'tls' })
net.listen('::1', 853, { kind = 'tls' })
--- Large cache size, so we don't need to flush ever
--- This can be larger than available RAM, least frequently accessed
--- records will be paged out as long as there's enough disk space to back it
-cache.size = 100 * GB
+-- Refer to manual for optimal cache size
+cache.size = 16 * GB
-- Load Useful modules
modules = {
net.listen('127.0.0.1', 853, { kind = 'tls' })
net.listen('::1', 853, { kind = 'tls' })
--- Large cache size, so we don't need to flush often
--- This can be larger than available RAM, least frequently accessed
--- records will be paged out
+-- Refer to manual for optimal cache size
cache.size = 4 * GB
-- load modules
dns64 = 'fe80::21b:77ff:0:0',
}
--- Large cache size, so we don't need to flush often
--- This can be larger than available RAM, least frequently accessed
--- records will be paged out
+-- Refer to manual for optimal cache size
cache.size = 4 * GB
-- Forward everything below `company.cz` to `192.168.1.3`