so I have a alias for hadoop which I defined in bash_aliases which bashrc touches upon I guess.
alias hadoop=/usr/local/hadoop-2.7.2/bin/hadoop
Now the alias works fine when I directly try to run it. But when I try this
ssh aditya@localhost hadoop
I get the following error message
bash: hadoop: command not found
I tried the following too
shopt -s expand_aliases
But that didn't work. Could anyone help me out.
Update:
This question is different from mine, because the ssh command is not generated by me, so the solution to that question does not solve my question. The ssh command is generated and executed by a script inside a library I am using. I do not prefer to modify that script to change the command as I am not completely aware of how that script works.
/usr/local/hadoop-2.7.2/bin
toPATH
. – fkraiem Aug 27 '16 at 04:39