YARN node labels allow you to group nodes with similar characteristics in order to
balance resources and specify where applications run.
Before you begin
You must have Big SQL installed with the Hortonworks Data Platform. For details see Installing IBM Big SQL.
Procedure
To configure YARN node labels:
-
In Ambari, navigate to . Under YARN Features set Node Labels to
Enabled.
-
Under the Advanced tab, under Advanced yarn-site,
update yarn.node-labels.fs-store.root-dir to the desired root directory. It
is recommended to use an HDFS directory rather than a local directory. In case the
c is not present, you can create the value under
Custom-yarn-site.
-
Save your changes and restart the YARN service.
-
If you are using an HDFS directory for
yarn.node-labels.fs-store.root-dir (recommended), create the directory in
HDFS and make sure that it is owned by <yarn:hadoop. If you use a local
directory (not recommended), create the directory on the ResourceManager(s) with the same
ownership.
-
On the Big SQL service page, under the Configs tab, you can customize
the YARN queue and YARN node label that Big SQL will use. You can use an existing queue and existing
label, or define a new one that you will create. Save any changes that you make but do not restart
the Big SQL service yet.
-
If the queue and/or label that you specified do not exist yet, create them manually and
associate them with each other:
- Create the YARN label by running the
command:
'yarn rmadmin -addToClusterNodeLabels "<label name>(exclusive=<true/false>)"
For
details about the node label configuration and the <Exclusive parameter, see
the Apache topic YARN Node Labels. Use false if you aren't
sure.
- You must apply the label to all nodes that host a Big SQL Worker
component:
yarn rmadmin -replaceLabelsOnNode “node1=[label] node2=[label]”
- Create the YARN queue in the YARN Queue Manager, which can be accessed
from an Ambari drop-down menu:
- Associate the queue with the chosen node label. Select Node Labels Access
for the queue that Big SQL will use, and make sure that the capacity assigned to all queues adds up
to 100% for each label (Ambari will prompt you if you haven't done this).
- From the Ambari Actions drop-down menu, select Save and
Refresh Queues to apply your changes.
-
Enable YARN for Big SQL as usual, or if YARN is already enabled simply restart the Big SQL
service.