Overriding java logging config

0
-rw-r--r--  1 yarn yarn   4.8G Jul 29 04:43 hadoop-yarn-timelineserver-ip-172-31-23-227.out

Jul 29, 2022 4:44:14 AM com.sun.jersey.server.wadl.generators.AbstractWadlGeneratorGrammarGenerator attachTypes
INFO: Couldn't find grammar element for class javax.ws.rs.core.Response
Jul 29, 2022 4:44:14 AM com.sun.jersey.server.wadl.generators.AbstractWadlGeneratorGrammarGenerator attachTypes
INFO: Couldn't find grammar element for class javax.ws.rs.core.Response
Jul 29, 2022 4:44:14 AM com.sun.jersey.server.wadl.generators.AbstractWadlGeneratorGrammarGenerator attachTypes
INFO: Couldn't find grammar element for class javax.ws.rs.core.Response
Jul 29, 2022 4:44:14 AM com.sun.jersey.server.wadl.generators.AbstractWadlGeneratorGrammarGenerator attachTypes
INFO: Couldn't find grammar element for class javax.ws.rs.core.Response
Jul 29, 2022 4:44:14 AM com.sun.jersey.server.wadl.generators.AbstractWadlGeneratorGrammarGenerator attachTypes
INFO: Couldn't find grammar element for class javax.ws.rs.core.Response

I've just found that the .out file of YARN timeline server is abnormally big and it consumes /mnt partition. The file just has tons of useless messages for me written by AbstractWadlGeneratorGrammarGenerator class of jersey-server module.

AbstractWadlGeneratorGrammarGenerator.java


...
import java.util.logging.Logger;
...
private static final Logger LOGGER = Logger.getLogger( AbstractWadlGeneratorGrammarGenerator.class.getName() );
...
LOGGER.info("Couldn't find grammar element for class " + parameterClass.getName());
...

However, AbstractWadlGeneratorGrammarGenerator writes the message by Java logger, not log4j.

Can I override Java logger configuration for EMR servers, especially YARN timeline server?

gefragt vor 2 Jahren295 Aufrufe
1 Antwort
1
Akzeptierte Antwort

This has been an outstanding issue until YARN-9554 which is fixed in Hadoop 3.3.0. However, EMR as of now packages only 3.2.1 in the latest EMR-6.7.0. I can confirm there is work underway to backport this to 3.2.1 for EMR which should be included in the upcoming release of EMR.

As a workaround you can do the following:

Login to the Master node of the EMR cluster to run the below commands or bake them as a bash script to submit it as a scriptrunner - EMR Step using console / CLI / SDK

  1. Add logging properties to JRE
echo 'com.sun.jersey.server.wadl.generators.level = OFF' | sudo tee -a /etc/alternatives/jre/lib/logging.properties > /dev/null
  1. Restart the Timeline Server to apply the changes
sudo systemctl restart hadoop-yarn-timelineserver

Please test the same in your lower environments and reply back if you have additional questions regarding the same.

AWS
SUPPORT-TECHNIKER
beantwortet vor 2 Jahren

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen