How to create a session cluster in Yarn in Hadoop?

Creating a YARN session cluster in Hadoop can be achieved by following these steps:

  1. Firstly, it is necessary to install and configure YARN in the Hadoop cluster. Make sure that the relevant parameters are correctly set in the configuration file of YARN, such as yarn-site.xml.
  2. Start the Master node of the YARN Session cluster on a node in the Hadoop cluster. You can use the following command to start the Master node:
$ start-yarn-session.sh
  1. After the Master node is started, you can use the following command to start the Worker nodes of the Session cluster.
$ start-yarn-session.sh -n <numWorkers>

Among them, is the number of Worker nodes to be started.

  1. You can use the following command to check the status of the Session cluster:
$ yarn-session.sh -s
  1. When you need to use a YARN Session cluster for computing tasks, you can submit jobs to YARN. You can submit jobs using the following command:
$ yarn-session.sh -f <jobFile>

Among them, is the homework file to be submitted.

By following the steps above, you can create and use a YARN Session cluster in Hadoop for computing tasks.

Leave a Reply 0

Your email address will not be published. Required fields are marked *


广告
Closing in 10 seconds
bannerAds