[ 
https://issues.apache.org/jira/browse/DRILL-5539?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16024975#comment-16024975
 ] 

Paul Rogers commented on DRILL-5539:
------------------------------------

On the surface, this looks pretty easy: just put quotes where needed. As it 
turns out, {{drillbit.sh}} calls {{drill-config.sh}} to do all the heavy 
lifting, and that drill-config.sh is called by many of our scripts. And, it 
does lots of path work to find the config files, find directories, find Java 
and so on.

The scripts do presently assume no spaces in directory names. Spaceless names 
is the general rule on Linux, but obviously Windows often uses spaces, most 
notably in the {{C:\Program Files}} directory.

Further, we have a unit test (not yet checked in) for the scripts that should 
be modified to test for the case you found. See DRILL-5540 for a request to 
check the shell script unit tests into Apache Drill master.

> drillbit.sh script breaks if the working directory contains spaces
> ------------------------------------------------------------------
>
>                 Key: DRILL-5539
>                 URL: https://issues.apache.org/jira/browse/DRILL-5539
>             Project: Apache Drill
>          Issue Type: Bug
>         Environment: Linux
>            Reporter: Muhammad Gelbana
>
> The following output occurred when we tried running the drillbit.sh script in 
> a path that contains spaces: */home/folder1/Folder Name/drill/bin*
> {noformat}
> [mgelbana@regression-sysops bin]$ ./drillbit.sh start
> ./drillbit.sh: line 114: [: /home/folder1/Folder: binary operator expected
> Starting drillbit, logging to /home/folder1/Folder Name/drill/log/drillbit.out
> ./drillbit.sh: line 147: $pid: ambiguous redirect
> [mgelbana@regression-sysops bin]$ pwd
> /home/folder1/Folder Name/drill/bin
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to