Hadoop service restarts apply configuration changes but can interrupt HDFS access, YARN scheduling, or running application logs. Restart the smallest daemon set that needs the change instead of bouncing the entire cluster by habit.
Apache archive installs commonly use hdfs –daemon, yarn –daemon, and the start-* or stop-* scripts. Packaged distributions may wrap those daemons in systemd units, so confirm the local service model first.
For configuration changes, stop or restart services only after the XML files are distributed to the hosts that load them. Verify HDFS and YARN state after the restart.
$ command -v hdfs /opt/hadoop/bin/hdfs
$ hdfs --daemon stop datanode Stopping datanode
$ hdfs --daemon start datanode
$ stop-yarn.sh Stopping resourcemanager Stopping nodemanagers
$ start-yarn.sh Starting resourcemanager Starting nodemanagers
$ hdfs dfsadmin -report Live datanodes (3): Dead datanodes (0):
Related: How to check HDFS cluster health
$ yarn application -list Total number of applications (application-types: [] and states: [SUBMITTED, ACCEPTED, RUNNING]):0