spark-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jerryshao <>
Subject [GitHub] spark pull request: [SPARK-2960][Deploy] Support executing Spark f...
Date Wed, 09 Sep 2015 14:18:09 GMT
GitHub user jerryshao opened a pull request:

    [SPARK-2960][Deploy] Support executing Spark from symlinks (reopen)

    This PR is based on the work of @roji to support running Spark scripts from symlinks.
Thanks for the great work @roji . Would you mind taking a look at this PR, thanks a lot.
    For releases like HDP and others, normally it will expose the Spark executables as symlinks
and put in `PATH`, but current Spark's scripts do not support finding real path from symlink
recursively, this will make spark fail to execute from symlink. This PR try to solve this
issue by finding the absolute path from symlink.
    Instead of using `readlink -f` like what this PR (
implemented is that `-f` is not support for Mac, so here manually seeking the path through
    I've tested with Mac and Linux (Cent OS), looks fine. 
    This PR did not fix the scripts under `sbin` folder, not sure if it needs to be fixed
    Please help to review, any comment is greatly appreciated.

You can merge this pull request into a Git repository by running:

    $ git pull SPARK-2960

Alternatively you can review and apply these changes as the patch at:

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #8669
commit 3cd2487ae651caeb081482e8b3f01592d9a38c9a
Author: Shay Rojansky <>
Date:   2014-08-10T08:04:45Z

    Support executing Spark from symlinks
    The current scripts (e.g. pyspark) fail to run when they are
    executed via symlinks. A common Linux scenario would be to have Spark
    installed somewhere (e.g. /opt) and have a symlink to it in /usr/bin.
    Fixed the scripts to traverse symlinks until reaching the actual binary.

commit 4fb2a0a8f5bb1d87fbe65726a51a15b7862a44c1
Author: jerryshao <>
Date:   2015-09-09T09:08:40Z

    :Make Spark script work with symlink

commit 69bde5ca9235f2bc90c73e2ff4177acf93eb03d1
Author: jerryshao <>
Date:   2015-09-09T13:53:22Z

    recover the comment


If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message