gear
's home directory is /user/gear
yarnclient launch -package /usr/lib/gearpump/gearpump-${version}.zip
If you don't specify package path, it will read default package-path from gear.conf(gearpump.yarn.client.package-path). 5. Before step 4, You can change gear.conf configuration section “gearpump.yarn” to config the cluster. 6. After launching, you can browser the Gearpump UI via YARN resource manager dashboard.
To submit the jar to the Gearpump cluster, we first need to know the Master address, so we need to get a active configuration file first.
There are two ways to get an active configuration file:
yarnclient launch -package /usr/lib/gearpump/gearpump-${version}.zip -output /tmp/mycluster.conf
It will return in console like this:
================================================ ==Application Id: application_1449802454214_0034
yarnclient getconfig -appid <yarn application id> -output /tmp/mycluster.conf
yarn application id can be found from the output of step1 or from YARN dashboard. 3. After you downloaded the configuration file, you can launch application with that config file.
gear app -jar examples/wordcount-${version}.jar -conf /tmp/mycluster.conf
gear info -conf /tmp/mycluster.conf
Gearpump yarn tool allows to dynamically add/remove machines. Here is the steps:
yarnclient query -appid <yarn application id>
The console output will shows how many workers and masters there are. For example, I have output like this:
masters: container_1449802454214_0034_01_000002(IDHV22-01:35712) workers: container_1449802454214_0034_01_000003(IDHV22-01:35712) container_1449802454214_0034_01_000006(IDHV22-01:35712)
yarnclient addworker -appid <yarn application id> -count 2
This will add two new workers machines. Run the command in first step to check whether the change is effective. 3. To remove old machines, use:
yarnclient removeworker -appid <yarn application id> -container <worker container id>
The worker container id can be found from the output of step 1. For example “container_1449802454214_0034_01_000006” is a good container id.
yarnclient kill -appid <yarn application id>
yarnclient version -appid <yarn application id>