[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13467669#comment-13467669 ] Hudson commented on HADOOP-8386: Integrated in Hadoop-Hdfs-0.23-Build #392 (See [https://builds.apache.org/job/Hadoop-Hdfs-0.23-Build/392/]) svn merge -c 1391780 FIXES: HADOOP-8386. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu). Contributed by Christopher Berner and Andy Isaacson. (harsh) (Revision 1392368) Result = UNSTABLE bobby : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1392368 Files : * /hadoop/common/branches/branch-0.23/hadoop-common-project/hadoop-common/CHANGES.txt * /hadoop/common/branches/branch-0.23/hadoop-common-project/hadoop-common/src/main/bin/hadoop * /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/bin/hdfs * /hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/bin/mapred * /hadoop/common/branches/branch-0.23/hadoop-yarn-project/hadoop-yarn/bin/yarn hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Assignee: Christopher Berner Fix For: 1.2.0, 3.0.0, 0.23.5 Attachments: hadoop-8386-1.diff, hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13466177#comment-13466177 ] Hudson commented on HADOOP-8386: Integrated in Hadoop-Hdfs-trunk-Commit #2852 (See [https://builds.apache.org/job/Hadoop-Hdfs-trunk-Commit/2852/]) HADOOP-8386. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu). Contributed by Christopher Berner and Andy Isaacson. (harsh) (Revision 1391780) Result = SUCCESS harsh : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1391780 Files : * /hadoop/common/trunk/hadoop-common-project/hadoop-common/CHANGES.txt * /hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/bin/hadoop * /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/bin/hdfs * /hadoop/common/trunk/hadoop-mapreduce-project/bin/mapred * /hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/bin/yarn hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Assignee: Christopher Berner Attachments: hadoop-8386-1.diff, hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13466179#comment-13466179 ] Hudson commented on HADOOP-8386: Integrated in Hadoop-Common-trunk-Commit #2789 (See [https://builds.apache.org/job/Hadoop-Common-trunk-Commit/2789/]) HADOOP-8386. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu). Contributed by Christopher Berner and Andy Isaacson. (harsh) (Revision 1391780) Result = SUCCESS harsh : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1391780 Files : * /hadoop/common/trunk/hadoop-common-project/hadoop-common/CHANGES.txt * /hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/bin/hadoop * /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/bin/hdfs * /hadoop/common/trunk/hadoop-mapreduce-project/bin/mapred * /hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/bin/yarn hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Assignee: Christopher Berner Fix For: 1.2.0, 3.0.0 Attachments: hadoop-8386-1.diff, hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13466180#comment-13466180 ] Hudson commented on HADOOP-8386: Integrated in Hadoop-Mapreduce-trunk-Commit #2811 (See [https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Commit/2811/]) HADOOP-8386. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu). Contributed by Christopher Berner and Andy Isaacson. (harsh) (Revision 1391780) Result = FAILURE harsh : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1391780 Files : * /hadoop/common/trunk/hadoop-common-project/hadoop-common/CHANGES.txt * /hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/bin/hadoop * /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/bin/hdfs * /hadoop/common/trunk/hadoop-mapreduce-project/bin/mapred * /hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/bin/yarn hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Assignee: Christopher Berner Fix For: 1.2.0, 3.0.0 Attachments: hadoop-8386-1.diff, hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13466210#comment-13466210 ] Hudson commented on HADOOP-8386: Integrated in Hadoop-Hdfs-trunk #1180 (See [https://builds.apache.org/job/Hadoop-Hdfs-trunk/1180/]) HADOOP-8386. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu). Contributed by Christopher Berner and Andy Isaacson. (harsh) (Revision 1391780) Result = SUCCESS harsh : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1391780 Files : * /hadoop/common/trunk/hadoop-common-project/hadoop-common/CHANGES.txt * /hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/bin/hadoop * /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/bin/hdfs * /hadoop/common/trunk/hadoop-mapreduce-project/bin/mapred * /hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/bin/yarn hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Assignee: Christopher Berner Fix For: 1.2.0, 3.0.0 Attachments: hadoop-8386-1.diff, hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13466227#comment-13466227 ] Hudson commented on HADOOP-8386: Integrated in Hadoop-Mapreduce-trunk #1211 (See [https://builds.apache.org/job/Hadoop-Mapreduce-trunk/1211/]) HADOOP-8386. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu). Contributed by Christopher Berner and Andy Isaacson. (harsh) (Revision 1391780) Result = FAILURE harsh : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVNview=revrev=1391780 Files : * /hadoop/common/trunk/hadoop-common-project/hadoop-common/CHANGES.txt * /hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/bin/hadoop * /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/bin/hdfs * /hadoop/common/trunk/hadoop-mapreduce-project/bin/mapred * /hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/bin/yarn hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Assignee: Christopher Berner Fix For: 1.2.0, 3.0.0 Attachments: hadoop-8386-1.diff, hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13465921#comment-13465921 ] Christopher Berner commented on HADOOP-8386: I didn't run into any other scripts that had this issue, but yes it would need to be handled everywhere as far as I can tell. I think another option (besides explicitly ignoring the output) would be to just add unset CDPATH at the beginning of the script. I've used that in scripts that had issues with environment variables before, and it works just fine. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13465962#comment-13465962 ] Andy Isaacson commented on HADOOP-8386: --- The Gnu Autoconf manual has this to say: http://www.gnu.org/software/autoconf/manual/autoconf-2.67/html_node/Special-Shell-Variables.html {quote} CDPATH When this variable is set it specifies a list of directories to search when invoking cd with a relative file name that did not start with ‘./’ or ‘../’. Posix 1003.1-2001 says that if a nonempty directory name from CDPATH is used successfully, cd prints the resulting absolute file name. Unfortunately this output can break idioms like ‘abs=`cd src pwd`’ because abs receives the name twice. Also, many shells do not conform to this part of Posix; for example, zsh prints the result only if a directory name other than . was chosen from CDPATH. In practice the shells that have this problem also support unset, so you can work around the problem as follows: (unset CDPATH) /dev/null 21 unset CDPATH You can also avoid output by ensuring that your directory name is absolute or anchored at ‘./’, as in ‘abs=`cd ./src pwd`’. {quote} So the Bash behavior is specified by Posix, alas. It is specified to write to stdout not stderr, so the patch is correct in that regard (I was concerned we might also need {{21}} or similar). So, LGTM. I'll upload a patch that conforms to test-patch expectations. Thanks for the contribution, Christopher! hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13465969#comment-13465969 ] Hadoop QA commented on HADOOP-8386: --- {color:red}-1 overall{color}. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12547060/hadoop-8386.diff against trunk revision . {color:red}-1 patch{color}. The patch command could not apply the patch. Console output: https://builds.apache.org/job/PreCommit-HADOOP-Build/1543//console This message is automatically generated. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13466016#comment-13466016 ] Hadoop QA commented on HADOOP-8386: --- {color:red}-1 overall{color}. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12547070/hadoop-8386-1.diff against trunk revision . {color:green}+1 @author{color}. The patch does not contain any @author tags. {color:red}-1 tests included{color}. The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. {color:green}+1 javac{color}. The applied patch does not increase the total number of javac compiler warnings. {color:green}+1 javadoc{color}. The javadoc tool did not generate any warning messages. {color:green}+1 eclipse:eclipse{color}. The patch built with eclipse:eclipse. {color:green}+1 findbugs{color}. The patch does not introduce any new Findbugs (version 1.3.9) warnings. {color:green}+1 release audit{color}. The applied patch does not increase the total number of release audit warnings. {color:red}-1 core tests{color}. The patch failed these unit tests in hadoop-common-project/hadoop-common: org.apache.hadoop.ha.TestZKFailoverController org.apache.hadoop.metrics2.impl.TestMetricsSystemImpl {color:green}+1 contrib tests{color}. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-HADOOP-Build/1544//testReport/ Console output: https://builds.apache.org/job/PreCommit-HADOOP-Build/1544//console This message is automatically generated. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13466053#comment-13466053 ] Christopher Berner commented on HADOOP-8386: Awesome, thanks Andy! Glad to see this fixed :) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop-8386-1.diff, hadoop-8386.diff, hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13464503#comment-13464503 ] Harsh J commented on HADOOP-8386: - Interesting, thanks! This is from my zsh instance (CDPATH is preset to . in it already): {code} ➜ ~ echo $CDPATH . ➜ ~ cd / ➜ / cd etc ➜ /etc cd ➜ ~ unset CDPATH ➜ ~ cd / ➜ / cd etc ➜ /etc cd ➜ ~ {code} And from bash: {code} ➜ ~ bash bash-3.2$ echo $CDPATH bash-3.2$ cd / bash-3.2$ cd etc bash-3.2$ export CDPATH=. bash-3.2$ cd / bash-3.2$ cd etc /etc bash-3.2$ {code} hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13464518#comment-13464518 ] Harsh J commented on HADOOP-8386: - Chris, So should we be handling this for all forms of cd use where we rely on no outputs to be transmitted? Or just this fix would do? Do you see any other instances we'll need to fix as well? Or maybe if there's a way to unset the behavior for our script runs alone, that'd work too. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13464385#comment-13464385 ] Andy Isaacson commented on HADOOP-8386: --- If it's not an alias, cd hackery almost always is done using a shell function. Also, a /bin/cd command cannot work -- running it would fork a child process, change directory of the child process, and then exit, having no impact on the parent shell process. To figure out what your cd is doing, in bash use type cd. {noformat} # first, define a function foo $ foo() { echo bar; } # now, run it $ foo bar $ type foo foo is a function foo () { echo bar } $ {noformat} In dash, {{type}} just says {{foo is a shell function}}. I bet the original user is using bash though. bq. Fixes the 'hadoop' script to work on Ubuntu distro and others where the 'cd' command prints to stdout My ubuntu 12.04 install doesn't have any aliases or functions defined for cd, can you find out what package is installing the evil settings in /etc/bash_completion.d (most likely) and file an upstream bug? {code} ubuntu@ubu-cdh-0:~$ type cd cd is a shell builtin {code} hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13464391#comment-13464391 ] Christopher Berner commented on HADOOP-8386: Just checked my installation and I'm using bash and the output of type cd says cd is a shell builtin. Will try and test this on a fresh install of 12.04 and see if I can reproduce it. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13464432#comment-13464432 ] Christopher Berner commented on HADOOP-8386: Ok, I tracked down the problem here. This only happens when you have the CDPATH environment variable set, and is the same issue noticed by the GIT team (http://lists-archives.com/git/623754-installation-failure-caused-by-cdpath-environment-variable.html). With more information available here: http://fvue.nl/wiki/Bash:_cd_sometimes_echoing_current_directory Let me know if I can help with anything else! hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13461453#comment-13461453 ] Harsh J commented on HADOOP-8386: - Hi Christopher, Is it cause the default Ubuntu shell is dash (http://manpages.ubuntu.com/manpages/lucid/man1/dash.1.html doesn't prove it though)? We try to make sure the hadoop script runs as a bash script (via a shebang…), and rely on bash's default cd behavior to not cause this. Perhaps some environment specific item on your desktop has overriden the default behavior? The cd builtin of bash does not print, nor has an option to do so (has -L and -P AFAIK, but neither enforces such a behavior). Must be some odd function wrapper, you can probably detect via which cd or type cd? What does it say? hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (HADOOP-8386) hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu)
[ https://issues.apache.org/jira/browse/HADOOP-8386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13272110#comment-13272110 ] Hadoop QA commented on HADOOP-8386: --- -1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12526303/hadoop.diff against trunk revision . +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. -1 patch. The patch command could not apply the patch. Console output: https://builds.apache.org/job/PreCommit-HADOOP-Build/977//console This message is automatically generated. hadoop script doesn't work if 'cd' prints to stdout (default behavior in Ubuntu) Key: HADOOP-8386 URL: https://issues.apache.org/jira/browse/HADOOP-8386 Project: Hadoop Common Issue Type: Bug Components: scripts Affects Versions: 0.20.205.0, 1.0.2 Environment: Ubuntu Reporter: Christopher Berner Attachments: hadoop.diff if the 'hadoop' script is run as 'bin/hadoop' on a distro where the 'cd' command prints to stdout, the script will fail due to this line: 'bin=`cd $bin; pwd`' Workaround: execute from the bin/ directory as './hadoop' Fix: change that line to 'bin=`cd $bin /dev/null; pwd`' -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira