Uh oh!
There was an error while loading. Please reload this page.
ZEPPELIN-1701: User impersonation not work with SPARK_HOME set. - #1672
ZEPPELIN-1701: User impersonation not work with SPARK_HOME set.#1672prabhjyotsingh wants to merge 8 commits into
Conversation
prabhjyotsingh
commented
Nov 23, 2016
CC: @zjffdu can you help review this. |
zjffdu
commented
Nov 23, 2016
It still doesn't work for me. |
prabhjyotsingh
commented
Nov 23, 2016
can you try
|
zjffdu
commented
Nov 23, 2016
I can do that, but it doesn't make sense to force user to do that. |
prabhjyotsingh
commented
Nov 23, 2016
I assumed this log file should have group permission to log into this file. What do you recommend ? |
zjffdu
commented
Nov 23, 2016
I found another crtitical issue is that all the enviroment variables defined in zeppelin-env.sh (like HADOOP_CONF_DIR) won't be passed to the interpreter process because you use ssh. This will cause interpreter process fail to start. |
prabhjyotsingh
commented
Nov 23, 2016
I think that should be fine; https://github.com/apache/zeppelin/blob/master/bin/interpreter.sh#L171 |
zjffdu
commented
Nov 23, 2016
Actually it doesn't work for spark interpreter if you try that. https://github.com/apache/zeppelin/blob/master/bin/interpreter.sh#L171 is for pig. And it is not safe if we add other enviroment variables that is not in classpath. Could we run zeppelin-env.sh after ssh ? |
prabhjyotsingh
commented
Nov 23, 2016
I see your point, let me check that. |
@zjffdu Here is what I've done
Can you review this and/or suggest more changes. |
felixcheung
commented
Nov 25, 2016
as an aside, I'd update the JIRA/PR - it might not be obvious what "when SPARK_HOME is set" means. If external Spark is broken then I think it is a much much serious problem :) |
This is ready for review, have checked this in few flavours of linux, and it was working as expected. I'll add more documentation in a while. |
zjffdu
commented
Nov 28, 2016
@prabhjyotsingh It works now, but log file permission issue is still here which make the spark interpreter fail to run unless user manually set permission |
prabhjyotsingh
commented
Nov 29, 2016
@zjffdu did you try it again, as this is working for me, or if you can let me know your environment I can try on the same. |
r-kamath
commented
Nov 29, 2016
LGTM 👍 |
Leemoonsoo
commented
Nov 29, 2016
#1704 changes the filename processenduser.md to userimpersonation.md. Could you resolve conflict? |
prabhjyotsingh
commented
Nov 30, 2016
@Leemoonsoo resolved conflict. Thank you for the quick fix. |
| CLASSPATH+=":${ZEPPELIN_INTP_CLASSPATH}" | ||
| if [[ ! -z "$ZEPPELIN_IMPERSONATE_USER" ]]; then | ||
| INTERPRETER_RUN_COMMAND=${ZEPPELIN_IMPERSONATE_RUN_CMD}" '" |
There was a problem hiding this comment.
this seem tricky so maybe I'm missing something, we are appending ' here?
There was a problem hiding this comment.
and this follows immediately with source in L195, so it will be 'source - no space between ' and source?
There was a problem hiding this comment.
Yes the ' starts here (L193) and ends at L206. I can add a space between ' and source but since it was working I didn't do it.
prabhjyotsingh
commented
Dec 1, 2016
Merging this if no more discussion. |
zjffdu
commented
Dec 2, 2016
@prabhjyotsingh I can not run pyspark interpreter. Can you try that in your enviroment ? |
zjffdu
commented
Dec 2, 2016
Please ignore it,I can ran it successfully now. |
prabhjyotsingh
commented
Dec 2, 2016
Thank you for the verification. |
What is this PR for?
User impersonation of front end user does not work with SPARK_HOME set.
What type of PR is it?
[Bug Fix | Hot Fix]
Todos
What is the Jira issue?
How should this be tested?
set SPARK_HOME zeppelin-env.sh and then try to run
Screenshots (if appropriate)
Questions: