Error when i try to execute a jon in Linux using Crontab

Highlighted
Five Stars

Error when i try to execute a jon in Linux using Crontab

Hi guys.

 

I need your help.

I builded a job , then unzip the file in the linux server. I can execute the .sh . It's works.

So now, i must add this .sh in the crontab with crontab -e. But it's not work. The crontab  logs:

 

line 4: java: command not found

 

When i inspect the line 4 in the .sh :

 

java -Xms256M -Xmx1024M -cp .:$ROOT_PATH:$ROOT_PATH/../lib/routines.jar:$ROOT_PATH/../lib/commons-collections-3.2.2.jar:$ROOT_PATH/../lib/commons-lang-2.6.jar:$ROOT_PATH/../lib/log4j-1.2.16.jar:$ROOT_PATH/../lib/log4j-1.2.17.jar:$ROOT_PATH/../lib/slf4j-api-1.7.5.jar:$ROOT_PATH/../lib/slf4j-log4j12-1.7.5.jar:$ROOT_PATH/../lib/dom4j-1.6.1.jar:$ROOT_PATH/../lib/jackson-xc-1.8.8.jar:$ROOT_PATH/../lib/hadoop-conf-NEW.jar:$ROOT_PATH/../lib/hadoop-yarn-api-2.6.0-cdh5.8.1.jar:$ROOT_PATH/../lib/httpclient-4.2.5.jar:$ROOT_PATH/../lib/jackson-mapper-asl-1.8.8.jar:$ROOT_PATH/../lib/hadoop-auth-2.6.0-cdh5.8.1.jar:$ROOT_PATH/../lib/jersey-client-1.9.jar:$ROOT_PATH/...

 

I don't know how resolve this error. I need execute that .sh with crontab. Thank you for your help.

Five Stars

Re: Error when i try to execute a jon in Linux using Crontab

Hi. Somebody can help me? My job not work when i execute with crontab

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

Definitive Guide to Data Integration

Practical steps to developing your data integration strategy.

Download