Reconfigurability

Ozone supports dynamic loading of certain properties without restarting the service. If a property is reconfigurable, you can modify it in the configuration file (ozone-site.xml) and then invoke the command to flush it to memory.

command:

ozone admin reconfig --address=<ip:port> start|status|properties

The meaning of command options:

  • –address: RPC address for one server
  • Three operations are provided:
    • start: Execute the reconfig operation asynchronously
    • status: Check reconfig status
    • properties: List reconfigurable properties

Retrieve the reconfigurable properties list

To retrieve all the reconfigurable properties list for a specific component in Ozone, you can use the command: ozone admin reconfig --address=<ip:port> properties. This command will list all the properties that can be dynamically reconfigured at runtime for specific component.

For example, get the Ozone OM reconfigurable properties list.

$ ozone admin reconfig --address=hadoop1:9862 properties
OM: Node [hadoop1:9862] Reconfigurable properties:
ozone.administrators

OM Reconfigurability

For example, modify ozone.administrators in ozone-site.xml and execute:

$ ozone admin reconfig --address=hadoop1:9862 start
OM: Started OM reconfiguration task on node [hadoop1:9862].

$ ozone admin reconfig --address=hadoop1:9862 status
OM: Reconfiguring status for node [hadoop1:9862]: started at Wed Dec 28 19:04:44 CST 2022 and finished at Wed Dec 28 19:04:44 CST 2022.
SUCCESS: Changed property ozone.administrators
From: “hadoop”
To: “hadoop,bigdata”

$ ozone admin reconfig -address=hadoop1:9862 properties
OM: Node [hadoop1:9862] Reconfigurable properties:
ozone.administrators

SCM Reconfigurability

For example, modify ozone.administrators in ozone-site.xml and execute:

$ ozone admin reconfig --address=hadoop1:9860 start
SCM: Started OM reconfiguration task on node [hadoop1:9860].

$ ozone admin reconfig --address=hadoop1:9860 status
SCM: Reconfiguring status for node [hadoop1:9860]: started at Wed Dec 28 19:04:44 CST 2022 and finished at Wed Dec 28 19:04:44 CST 2022.
SUCCESS: Changed property ozone.administrators
From: “hadoop”
To: “hadoop,bigdata”

$ ozone admin reconfig -address=hadoop1:9860 properties
SCM: Node [hadoop1:9860] Reconfigurable properties:
ozone.administrators

Datanode Reconfigurability

For example, modify ozone.example.config in ozone-site.xml and execute:

$ ozone admin reconfig --address=hadoop1:19864 start
Datanode: Started reconfiguration task on node [hadoop1:19864].

$ ozone admin reconfig --address=hadoop1:19864 status
Datanode: Reconfiguring status for node [hadoop1:19864]: started at Wed Dec 28 19:04:44 CST 2022 and finished at Wed Dec 28 19:04:44 CST 2022.
SUCCESS: Changed property ozone.example.config
From: “old”
To: “new”

$ ozone admin reconfig -address=hadoop1:19864 properties
Datanode: Node [hadoop1:19864] Reconfigurable properties:
ozone.example.config

Batch operation

If you want to perform a batch operations on the Datanode, you can set the --in-service-datanodes flag. This will send reconfiguration requests to all available DataNodes in the IN_SERVICEoperational state.
Currently, only Datanode supports batch operations

For example, to list the reconfigurable properties of all Datanodes:
$ ozone admin reconfig --in-service-datanodes properties
Datanode: Node [hadoop1:19864] Reconfigurable properties:
ozone.example.config
Datanode: Node [hadoop2:19864] Reconfigurable properties:
ozone.example.config
Datanode: Node [hadoop3:19864] Reconfigurable properties:
ozone.example.config
Reconfig successfully 3 nodes, failure 0 nodes.

Next >>