I\'m running hadoop in a single-machine, local-only setup, and I\'m looking for a nice, painless way to debug mappers and reducers in eclipse. Eclipse has no probl
Make changes in /bin/hadoop
(hadoop-env.sh
) script. Check to see what command has been fired. If the command is jar
, then only add remote debug configuration.
if [ "$COMMAND" = "jar" ] ; then
exec "$JAVA" -Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=8999 $JAVA_HEAP_MAX $HADOOP_OPTS $CLASS "$@"
else
exec "$JAVA" $JAVA_HEAP_MAX $HADOOP_OPTS $CLASS "$@"
fi