Search code examples
apache-pighadoop-yarn

PIG - SET yarn garbage collection


I am trying to set following properties in a Pig script:

mapreduce.reduce.java.opts="-Xmx6114m  -XX:+UseG1GC -verbose:gc -XX:+PrintGC -XX:+PrintGCDateStamps"

yarn.app.mapreduce.am.command-opts="-Xmx6114m  -XX:+UseG1GC -verbose:gc -XX:+PrintGC -XX:+PrintGCDateStamps"

As

SET mapreduce.reduce.java.opts -Xmx6114m  -XX:+UseG1GC -verbose:gc -XX:+PrintGC -XX:+PrintGCDateStamps;

SET yarn.app.mapreduce.am.command-opts -Xmx6114m  -XX:+UseG1GC -verbose:gc -XX:+PrintGC -XX:+PrintGCDateStamps;

But it throws an error ERROR org.apache.pig.tools.grunt.Grunt - ERROR 1200: null

Is this the wrong way to set param while SET yarn.app.mapreduce.am.command-opts -Xmx6114m; works


Solution

  • Please enclose them with single quote.

    SET yarn.app.mapreduce.am.command-opts '-Xmx6114m  -XX:+UseG1GC -verbose:gc -XX:+PrintGC -XX:+PrintGCDateStamps'