Skip to content

Samza application start and stop

kaliraja edited this page Jun 8, 2021 · 8 revisions

1. To list the running node(yarn-slaves):

/usr/local/hadoop/bin/yarn node -list -states RUNNING

2. To list the running samza application(jobs):

/usr/local/hadoop/bin/yarn application --list | awk '{print $1 " " $2 " " $6 " " $7 " " $9}'

3. To kill the samza application:

/usr/local/hadoop/bin/yarn application -kill <application id>
(i.e) /usr/local/hadoop/bin/yarn application -kill application_1533552119356_0040

4. To start the samza application:

  1. Switch to hduser

    ii.  cd samza-jobs/{{env}}/extract/application-name-version-distribution.tar.gz
    iii.  Run the below command by  replacinng the properties file name with specific to samza application(jobs).
    bin/run-job.sh --config-factory=org.apache.samza.config.factories.PropertiesConfigFactory --config-path= config/<properties file name>
    (i.e) Below is the example command to start the telemetry-validator samza application:
    cd samza-jobs/ntpprod/extract/telemetry-validator-<version>-distribution.tar.gz
    bin/run-job.sh --config-factory=org.apache.samza.config.factories.PropertiesConfigFactory --config-path= config/telemetry-validator.properties

5. Log path:

/usr/local/hadoop/logs/userlogs/<AppID>
Get the app id from 2nd step

6. To stop and start the nodemanager:

switch to hduser,
/usr/local/hadoop/sbin/yarn-daemon.sh stop nodemanager
/usr/local/hadoop/sbin/yarn-daemon.sh start nodemanager

7. To stop and start the resourcemanager:

switch to hduser,
/usr/local/hadoop/sbin/yarn-daemon.sh stop resourcemanager
/usr/local/hadoop/sbin/yarn-daemon.sh start resourcemanager
Clone this wiki locally