08-09-2016 01:00 AM
I am trying to execute a shell script from oozie. The script is used to download a file from a remote server using scp command.
The shell script looks like this:
sudo -u test scp userName@ServerIP:pathToFileONRemoteServer/export_all_products.csv /home/test
Now, I am using sudo - u test because password less ssh has been enabled for test user only. I came across error messages that suggested disabling tty and that's what I did for test user.
However, Now I get:
sudo: no tty present and no askpass program specified Failing Oozie Launcher, Main class [org.apache.oozie.action.hadoop.ShellMain], exit code 
Why is that and how do we fix this? I am using hue and can't seem to enable password less ssh for hue user as it isn't a shell user and isn't a folder under with username under home directory.
Is there a way around this?
08-09-2016 09:19 AM