You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hbase.apache.org by "G G (JIRA)" <ji...@apache.org> on 2014/01/20 12:10:19 UTC

[jira] [Created] (HBASE-10381) HBase shell scripts do not handle whitespaces in path names

G G created HBASE-10381:
---------------------------

             Summary: HBase shell scripts do not handle whitespaces in path names
                 Key: HBASE-10381
                 URL: https://issues.apache.org/jira/browse/HBASE-10381
             Project: HBase
          Issue Type: Bug
          Components: scripts
    Affects Versions: 0.96.0
         Environment: Windows, Linux
            Reporter: G G


When setting one of the HBASE_CONF_DIR, HBASE_LOG_DIR, or HBASE_CLASSPATH environment variables to a directory containing a whitespace, the Linux shell scripts to start/stop hbase daemons (bin/start-hbase.sh) resp. the scripts it calls stop working. I tried to create a patch for this but unfortunately my shell-script knowledge does not suffice.
In some lines, escaping the used environment variables seems to do the trick but I was not able to fix the code that builds the command line in bin/hbase which looks like this:
{noformat}
HBASE_OPTS="$HBASE_OPTS -Dhbase.log.dir=$HBASE_LOG_DIR"
...
{noformat}
If HBASE_LOG_DIR is e.g. "/tmp/foo bar" then HBASE_OPTS becomes "... -Dhbase.log.dir=/tmp/foo bar" and when java is started it interprets bar as the main-class argument.

On Windows, HBase would not start unless I escaped the HBASE_CONF_DIR environment variable using double quotes.

If anyone has an idea on how to fix this, I could try to build a patch.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)