advanced.json 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. # This is an example configuration file for DHCPv6 server in Kea.
  2. # It attempts to showcase some of the more advanced features.
  3. # Topology wise, it's a basic scenario with one IPv6 subnet configured.
  4. # It is assumed that one subnet (2001:db8:1::/64) is available directly
  5. # over ethX interface.
  6. #
  7. # The following features are currently showcased here:
  8. # 1. Configuration of MAC/hardware address sources in DHCPv6
  9. { "Dhcp6":
  10. {
  11. # Kea is told to listen on ethX network interface only.
  12. "interfaces-config": {
  13. "interfaces": [ "ethX" ]
  14. },
  15. # We need to specify the the database used to store leases. As of
  16. # September 2016, four database backends are supported: MySQL,
  17. # PostgreSQL, Cassandra, and the in-memory database, Memfile.
  18. # We'll use memfile because it doesn't require any prior set up.
  19. "lease-database": {
  20. "type": "memfile"
  21. },
  22. # Kea 0.9.1 introduced MAC/hardware addresses support in DHCPv6. There is
  23. # no single reliable method of getting MAC address information in DHCPv6.
  24. # Kea supports several methods. Depending on your network set up, some
  25. # methods may be more preferable than others, hence the configuration
  26. # parameter. 'mac-sources' is a list of methods. Allowed parameters are:
  27. # any, raw, duid, ipv6-link-local, client-link-addr-option, rfc6939 (which
  28. # is an alias for client-link-addr-option), remote-id, rfc4649 (which is an
  29. # alias for remote-id, subscriber-id, rfc4580 (which is an alias for
  30. # subscriber-id) and docsis.
  31. #
  32. # Note that the order matters. Methods are attempted one by one in the order
  33. # specified until hardware address is obtained. If you don't care which method
  34. # is used, using 'any' is marginally faster than enumerating them all.
  35. #
  36. # If mac-sources are not specified, a default value of 'any' is used.
  37. "mac-sources": [ "client-link-addr-option", "duid", "ipv6-link-local" ],
  38. # RFC6422 defines a mechanism called relay-supplied options option. The relay
  39. # agent may insert certain options that the server will echo back to the
  40. # client, if certain criteria are met. One condition is that the option must
  41. # be RSOO-enabled (i.e. allowed to be echoed back). IANA maintains a list
  42. # of those options here:
  43. # http://www.iana.org/assignments/dhcpv6-parameters/dhcpv6-parameters.xhtml#options-relay-supplied
  44. # However, it is possible to allow the server to echo back additional options.
  45. # This entry marks options 110, 120 and 130 as RSOO-enabled.
  46. "relay-supplied-options": [ "110", "120", "130" ],
  47. # Addresses will be assigned with preferred and valid lifetimes
  48. # being 3000 and 4000, respectively. Client is told to start
  49. # renewing after 1000 seconds. If the server does not respond
  50. # after 2000 seconds since the lease was granted, client is supposed
  51. # to start REBIND procedure (emergency renewal that allows switching
  52. # to a different server).
  53. "preferred-lifetime": 3000,
  54. "valid-lifetime": 4000,
  55. "renew-timer": 1000,
  56. "rebind-timer": 2000,
  57. # The following list defines subnets. Each subnet consists of at
  58. # least subnet and pool entries.
  59. "subnet6": [
  60. {
  61. "pools": [ { "pool": "2001:db8:1::/80" } ],
  62. # This defines PD (prefix delegation) pools. In this case
  63. # we have only one pool. That consists of /64 prefixes
  64. # being delegated out of large /48 pool. Each delegated
  65. # prefix will contain an excluded-prefix option.
  66. "pd-pools": [
  67. {
  68. "prefix": "2001:db8:abcd::",
  69. "prefix-len": 48,
  70. "delegated-len": 64,
  71. "excluded-prefix": "2001:db8:abcd:1234::",
  72. "excluded-prefix-len": 62
  73. }
  74. ],
  75. "subnet": "2001:db8:1::/64",
  76. "interface": "ethX"
  77. }
  78. ]
  79. },
  80. # The following configures logging. It assumes that messages with at least
  81. # informational level (info, warn, error and fatal) should be logged to stdout.
  82. "Logging": {
  83. "loggers": [
  84. {
  85. "name": "kea-dhcp6",
  86. "output_options": [
  87. {
  88. "output": "stdout"
  89. }
  90. ],
  91. "debuglevel": 0,
  92. "severity": "INFO"
  93. }
  94. ]
  95. }
  96. }