stderr: /var/lib/ambari-agent/data/errors-14.txt Traceback (most recent call last): File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py", line 35, in BeforeAnyHook().execute() File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 329, in execute method(env) File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py", line 29, in hook setup_users() File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py", line 51, in setup_users fetch_nonlocal_groups = params.fetch_nonlocal_groups, File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 166, in __init__ self.env.run() File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 160, in run self.run_action(resource, action) File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 124, in run_action provider_action() File "/usr/lib/python2.6/site-packages/resource_management/core/providers/accounts.py", line 84, in action_create shell.checked_call(command, sudo=True) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 72, in inner result = function(command, **kwargs) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 102, in checked_call tries=tries, try_sleep=try_sleep, timeout_kill_strategy=timeout_kill_strategy) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 150, in _call_wrapper result = _call(command, **kwargs_copy) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 303, in _call raise ExecutionFailed(err_msg, code, out, err) resource_management.core.exceptions.ExecutionFailed: Execution of 'useradd -m -u 1015 -G hadoop -g hadoop yarn' returned 12. useradd: cannot create directory /home/yarn Error: Error: Unable to run the custom hook script ['/usr/bin/python', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py', 'ANY', '/var/lib/ambari-agent/data/command-14.json', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY', '/var/lib/ambari-agent/data/structured-out-14.json', 'INFO', '/var/lib/ambari-agent/tmp', 'PROTOCOL_TLSv1', ''] stdout: /var/lib/ambari-agent/data/output-14.txt 2018-05-03 09:53:17,749 - Stack Feature Version Info: Cluster Stack=2.6, Cluster Current Version=None, Command Stack=None, Command Version=None -> 2.6 2018-05-03 09:53:17,761 - Using hadoop conf dir: /usr/hdp/current/hadoop-client/conf User Group mapping (user_group) is missing in the hostLevelParams 2018-05-03 09:53:17,762 - Group['livy'] {} 2018-05-03 09:53:17,765 - Group['spark'] {} 2018-05-03 09:53:17,766 - Group['zeppelin'] {} 2018-05-03 09:53:17,766 - Group['hadoop'] {} 2018-05-03 09:53:17,766 - Group['users'] {} 2018-05-03 09:53:17,766 - Group['knox'] {} 2018-05-03 09:53:17,767 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,770 - Writing File['/var/lib/ambari-agent/tmp/changeUid.sh'] because it doesn't exist 2018-05-03 09:53:17,770 - Changing permission for /var/lib/ambari-agent/tmp/changeUid.sh from 644 to 555 2018-05-03 09:53:17,771 - call['/var/lib/ambari-agent/tmp/changeUid.sh hive'] {} 2018-05-03 09:53:17,787 - call returned (0, '1001') 2018-05-03 09:53:17,787 - User['hive'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1001} 2018-05-03 09:53:17,791 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,793 - call['/var/lib/ambari-agent/tmp/changeUid.sh storm'] {} 2018-05-03 09:53:17,806 - call returned (0, '1002') 2018-05-03 09:53:17,806 - User['storm'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1002} 2018-05-03 09:53:17,809 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,810 - call['/var/lib/ambari-agent/tmp/changeUid.sh zookeeper'] {} 2018-05-03 09:53:17,821 - call returned (0, '1003') 2018-05-03 09:53:17,822 - User['zookeeper'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1003} 2018-05-03 09:53:17,824 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,825 - call['/var/lib/ambari-agent/tmp/changeUid.sh infra-solr'] {} 2018-05-03 09:53:17,838 - call returned (0, '1004') 2018-05-03 09:53:17,838 - User['infra-solr'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1004} 2018-05-03 09:53:17,841 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,843 - call['/var/lib/ambari-agent/tmp/changeUid.sh oozie'] {} 2018-05-03 09:53:17,856 - call returned (0, '1005') 2018-05-03 09:53:17,857 - User['oozie'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'users'], 'uid': 1005} 2018-05-03 09:53:17,861 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,863 - call['/var/lib/ambari-agent/tmp/changeUid.sh ams'] {} 2018-05-03 09:53:17,876 - call returned (0, '1006') 2018-05-03 09:53:17,877 - User['ams'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1006} 2018-05-03 09:53:17,881 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,883 - call['/var/lib/ambari-agent/tmp/changeUid.sh tez'] {} 2018-05-03 09:53:17,895 - call returned (0, '1007') 2018-05-03 09:53:17,896 - User['tez'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'users'], 'uid': 1007} 2018-05-03 09:53:17,898 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,899 - call['/var/lib/ambari-agent/tmp/changeUid.sh zeppelin'] {} 2018-05-03 09:53:17,911 - call returned (0, '1008') 2018-05-03 09:53:17,912 - User['zeppelin'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'zeppelin', u'hadoop'], 'uid': 1008} 2018-05-03 09:53:17,915 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,918 - call['/var/lib/ambari-agent/tmp/changeUid.sh livy'] {} 2018-05-03 09:53:17,929 - call returned (0, '1009') 2018-05-03 09:53:17,930 - User['livy'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1009} 2018-05-03 09:53:17,933 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,936 - call['/var/lib/ambari-agent/tmp/changeUid.sh spark'] {} 2018-05-03 09:53:17,947 - call returned (0, '1010') 2018-05-03 09:53:17,947 - User['spark'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1010} 2018-05-03 09:53:17,949 - User['ambari-qa'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'users'], 'uid': None} 2018-05-03 09:53:17,951 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,953 - call['/var/lib/ambari-agent/tmp/changeUid.sh flume'] {} 2018-05-03 09:53:17,966 - call returned (0, '1011') 2018-05-03 09:53:17,967 - User['flume'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1011} 2018-05-03 09:53:17,971 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,973 - call['/var/lib/ambari-agent/tmp/changeUid.sh kafka'] {} 2018-05-03 09:53:17,985 - call returned (0, '1012') 2018-05-03 09:53:17,986 - User['kafka'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1012} 2018-05-03 09:53:17,990 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:17,992 - call['/var/lib/ambari-agent/tmp/changeUid.sh hdfs'] {} 2018-05-03 09:53:18,005 - call returned (0, '1013') 2018-05-03 09:53:18,005 - User['hdfs'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1013} 2018-05-03 09:53:18,007 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:18,009 - call['/var/lib/ambari-agent/tmp/changeUid.sh sqoop'] {} 2018-05-03 09:53:18,021 - call returned (0, '1014') 2018-05-03 09:53:18,022 - User['sqoop'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1014} 2018-05-03 09:53:18,024 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2018-05-03 09:53:18,025 - call['/var/lib/ambari-agent/tmp/changeUid.sh yarn'] {} 2018-05-03 09:53:18,145 - call returned (0, '1015') 2018-05-03 09:53:18,146 - User['yarn'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': [u'hadoop'], 'uid': 1015} 2018-05-03 09:53:18,146 - Adding user User['yarn'] Error: Error: Unable to run the custom hook script ['/usr/bin/python', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY/scripts/hook.py', 'ANY', '/var/lib/ambari-agent/data/command-14.json', '/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/before-ANY', '/var/lib/ambari-agent/data/structured-out-14.json', 'INFO', '/var/lib/ambari-agent/tmp', 'PROTOCOL_TLSv1', ''] Command failed after 1 tries