log4j:No Appenders could be found for logger for .sh file

Highlighted
Six Stars

log4j:No Appenders could be found for logger for .sh file

Trying to run a talend job on terminal in linux.

I built the job and got .sh file.

Used chmod +x Job.sh and then ./Job.sh

 

I see the error:

log4j:WARN No appenders could be found for logger (net.sf.json.xml.XMLSerializer).

log4j:WARN Please initialize the log4j system properly

 

Can someone help what may have gone wrong and how to rectify?

Eleven Stars

Re: log4j:No Appenders could be found for logger for .sh file

https://stackoverflow.com/questions/1140358/how-to-initialize-log4j-properly

are you able to locate your log4j property file ?
Regards
Abhishek KUMAR
Six Stars

Re: log4j:No Appenders could be found for logger for .sh file

@akumar2301 no. Where would I find it?

Six Stars

Re: log4j:No Appenders could be found for logger for .sh file

Also, the job works fine when I run it in talend software. I built the job and placed it in a different pc and running it via terminal there. This is when it fails.

Eleven Stars

Re: log4j:No Appenders could be found for logger for .sh file

Aah ok , Quick Question Did you build your job with Log4j option.

 

Please follow below link  - search "Custom Log4j level"

 

https://help.talend.com/reader/nXPtKhielAtSqFD6_f7~OQ/V5yP4nItw687WwHLVpxwFQ

https://help.talend.com/reader/nXPtKhielAtSqFD6_f7~OQ/OTiswlhxpERhnYV6Nf6I1g

 

If this doesnot work , try to add as JVM argument

-Dlog4j.configuration=file:C:\xXpathXxxxx\log4j.xml

 

Let me know if it works

Regards
Abhishek KUMAR

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

Tutorial

Introduction to Talend Open Studio for Data Integration.

Watch