when i try creating instances using Ambari for the first time, the process is failing, and the error message I see is pasted below. Where can I specify to use ec2-user and not root?
PLease note - I am using AWS and running redhat linux.
ambari version is 18.104.22.168
Thanks in advance
========================== Creating target directory... ========================== Command start time 2017-05-10 06:54:17 Please login as the user "ec2-user" rather than the user "root". Connection to ip-10-0-0-202.eu-west-2.compute.internal closed. SSH command execution finished host=ip-10-0-0-202.eu-west-2.compute.internal, exitcode=0 Command end time 2017-05-10 06:54:27 ========================== Copying common functions script... ========================== Command start time 2017-05-10 06:54:27 Please login as the user "ec2-user" rather than the user "root". scp /usr/lib/python2.6/site-packages/ambari_commons host=ip-10-0-0-202.eu-west-2.compute.internal, exitcode=1 Command end time 2017-05-10 06:54:37 ========================== Copying OS type check script... ========================== Command start time 2017-05-10 06:54:37 Please login as the user "ec2-user" rather than the user "root". scp /usr/lib/python2.6/site-packages/ambari_server/os_check_type.py host=ip-10-0-0-202.eu-west-2.compute.internal, exitcode=1 Command end time 2017-05-10 06:54:48 ERROR: Bootstrap of host ip-10-0-0-202.eu-west-2.compute.internal fails because previous action finished with non-zero exit code (1) ERROR MESSAGE: Please login as the user "ec2-user" rather than the user "root". STDOUT: Please login as the user "ec2-user" rather than the user "root".
You can setup ambari-server to run as a non-root user.
Please refer to the following doc: http://docs.hortonworks.com/HDPDocuments/Ambari-22.214.171.124/bk_ambari-security/content/configuring_ambar...
During the ambari-server setup
process, when prompted to
Customize user account for ambari-server daemon?,
No you do not need to uninstall ambari.
Just try the following stop ambari and then do the setup again.
# ambari-server stop # ambari-server setup
Later you should also configure the ambari-agents as well to run as non root:
Thanks @Jay SenSharma, I am still getting the same error message. what i did is,
stopped the server and initiated set up and used "hadoop" user. I then started the server and tried again in ambari. I got the same error message.
To verify, I again ran the setup command, and I could see that ambari has understood the "hadoop" user as you can see below.
[root@ip-10-0-0-60 etc]# ambari-server setup
Using python /usr/bin/python2 Setup ambari-server Checking SELinux... SELinux status is 'enabled' SELinux mode is 'permissive' WARNING: SELinux is set to 'permissive' mode and temporarily disabled. OK to continue [y/n] (y)? y
Ambari-server daemon is configured to run under user 'hadoop'. Change this setting [y/n] (n)?
There is a good article available on Setting Ambari Based HAdoop Cluster on EC2 .. may be you can compare the steps once to see any step is missing:
Thanks, that was the article I was following indeed and I think I have followed all the steps listed in there - as far as I can say. Is there any other way to perhaps see the config file, of ambari? where I can see if it is hardcoded as "root"?