Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
On this page

Submitting Other Tasks Using the Oozie Client

Updated on 2024-10-08 GMT+08:00

Scenario

In addition to Hive, Spark2x, and Loader jobs, MapReduce, Java, Shell, HDFS, SSH, SubWorkflow, Streaming, and scheduled jobs can be submitted using the Oozie client.

NOTE:

You are advised to download the latest client.

Prerequisites

  • The Oozie component and its client have been installed and are running properly.
  • You have created or obtained the human-machine account and password for accessing the Oozie service.
    NOTE:
    • Shell job:

      This user must belong to the hadoop and supergroup groups and be assigned the Oozie role operation permission. The Shell script must have the execution permission on each NodeManager.

    • SSH job:

      This user must belong to the hadoop and supergroup groups and be assigned the Oozie role operation permission. The mutual trust configuration is complete.

    • Other jobs:

      This user must belong to the hadoop and supergroup groups and be assigned the Oozie role operation permission and other required permissions.

    • This user must also be assigned the manager_viewer role at least.
  • You have obtained the URL of the Oozie server (any instance) in the running state, for example, https://10.1.130.10:21003/oozie.
  • You have obtained the name of the Oozie server, for example, 10-1-130-10.
  • You have obtained the IP address of the active Yarn ResourceManager, for example, 10.1.130.11.

Procedure

  1. Log in to the node where the Oozie client is installed as the client installation user.
  2. Run the following command to obtain the installation environment. /opt/client is an example client installation path.

    source /opt/client/bigdata_env

  3. Check the cluster authentication mode.

    • If the cluster is in security mode, run the kinit command to authenticate users.

      For example, the oozieuser user is authenticated using the following command:

      kinit oozieuser

    • If the cluster is in normal mode, go to 4.

  4. Go to the example directory based on the type of the task you submit.

    Table 1 List of example directories

    Job Type

    Example Directory

    MapReduce job

    Client installation directory/Oozie/oozie-client-*/examples/apps/map-reduce

    Java job

    Client installation directory/Oozie/oozie-client-*/examples/apps/java-main

    Shell job

    Client installation directory/Oozie/oozie-client-*/examples/apps/shell

    Streaming job

    Client installation directory/Oozie/oozie-client-*/examples/apps/shell

    SubWorkflow job

    Client installation directory/Oozie/oozie-client-*/examples/apps/subwf

    SSH job

    Client installation directory/Oozie/oozie-client-*/examples/apps/ssh

    Scheduled job

    Client installation directory/Oozie/oozie-client-*/examples/apps/cron

    NOTE:

    The examples of other jobs contain HDFS job examples.

    Table 2 lists the files that you need to pay attention to in the example directory.

    Table 2 File description

    File

    Description

    job.properties

    Parameter definition file of a workflow

    workflow.xml

    Rule definition file of a workflow

    lib

    Directory of the JAR file on which a workflow depends

    coordinator.xml

    Scheduled job configuration file which can be used to set a scheduled policy. The file is in the cron directory.

    oozie_shell.sh

    Shell script file required for submitting shell jobs. The file is in the shell directory.

  5. Run the following command to edit the job.properties file:

    vi job.properties

    Perform the following modifications:

    Change the value of userName to the name of the human-machine user who submits the job, for example, userName=oozieuser.

  6. Run the oozie job command to run the workflow file:

    oozie job -oozie https://Host name of the oozie role:21003/oozie -config File path of job.properties -run

    Example:

    oozie job -oozie https://10-1-130-10:21003/oozie -config

    /opt/client/Oozie/oozie-client-*/examples/apps/map-reduce/job.properties -run

    NOTE:
    • The command parameters are described as follows:

      -oozie: URL of the Oozie server that executes a job

      -config: Workflow property file

      -run: Executing a workflow

    • If a job ID, for example, job: 0000021-140222101051722-oozie-omm-W, is displayed after the workflow file is executed, the job is successfully submitted. You can view the execution results on the Oozie management page.

      Log in to the Oozie web UI at https://IP address of the Oozie role:21003/oozie as user oozieuser.

      On the Oozie web UI, you can view the submitted workflow information based on the job ID in the table on the page.

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback