reconfigure-node.asciidoc 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. [[reconfigure-node]]
  2. == elasticsearch-reconfigure-node
  3. The `elasticsearch-reconfigure-node` tool reconfigures an {es} node that was installed
  4. through an RPM or DEB package to join an existing cluster with security features enabled.
  5. [discrete]
  6. === Synopsis
  7. [source,shell]
  8. -----------------------------------------------------
  9. bin/elasticsearch-reconfigure-node
  10. [--enrollment-token] [-h, --help] [-E <KeyValuePair>]
  11. [-s, --silent] [-v, --verbose]
  12. -----------------------------------------------------
  13. [discrete]
  14. === Description
  15. When installing {es} with a DEB or RPM package, the current node is assumed to
  16. be the first node in the cluster. {es} enables and configures security
  17. features on the node, generates a password for the `elastic` superuser, and
  18. configures TLS for the HTTP and transport layers.
  19. Rather than form a single-node cluster, you can add a node to an existing
  20. cluster where security features are already enabled and configured. Before
  21. starting your new node, run the
  22. <<create-enrollment-token,`elasticsearch-create-enrollment-token`>> tool
  23. with the `-s node` option to generate an enrollment token on any node in your
  24. existing cluster. On your new node, run the the
  25. `elasticsearch-reconfigure-node` tool and pass the enrollment token as a
  26. parameter.
  27. NOTE: This tool is intended only for use on DEB or RPM distributions of {es}.
  28. You must run this tool with `sudo` so that it can edit the necessary
  29. files in your {es} installation configuration directory that are owned by
  30. `root:elasticsearch`.
  31. [discrete]
  32. [[reconfigure-node-parameters]]
  33. === Parameters
  34. `--enrollment-token`:: The enrollment token, which can be generated on any of the
  35. nodes in an existing, secured cluster.
  36. `-E <KeyValuePair>`:: Configures a standard {es} or {xpack} setting.
  37. `-h, --help`:: Shows help information.
  38. `-s, --silent`:: Shows minimal output.
  39. `-v, --verbose`:: Shows verbose output.
  40. [discrete]
  41. === Examples
  42. The following example reconfigures an installed {es} node so that it can join an existing cluster when it starts for the first time.
  43. [source,shell]
  44. ----
  45. sudo /usr/share/elasticsearch/elasticsearch-reconfigure-node --enrollment-token eyJ2ZXIiOiI4LjAuMCIsImFkciI6WyIxOTIuMTY4LjEuMTY6OTIwMCJdLCJmZ3IiOiI4NGVhYzkyMzAyMWQ1MjcyMmQxNTFhMTQwZmM2ODI5NmE5OWNiNmU0OGVhZjYwYWMxYzljM2I3ZDJjOTg2YTk3Iiwia2V5IjoiUy0yUjFINEJrNlFTMkNEY1dVV1g6QS0wSmJxM3hTRy1haWxoQTdPWVduZyJ9
  46. ----