<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Manage Ambari user roles in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173244#M58021</link>
    <description>&lt;P&gt;Dear community,&lt;/P&gt;&lt;P&gt;Is it possible to manage user roles not only from Ambari GUI? Blueprints? Some configs?&lt;/P&gt;</description>
    <pubDate>Fri, 24 Mar 2017 16:32:54 GMT</pubDate>
    <dc:creator>vladislav_falfu</dc:creator>
    <dc:date>2017-03-24T16:32:54Z</dc:date>
    <item>
      <title>Manage Ambari user roles</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173244#M58021</link>
      <description>&lt;P&gt;Dear community,&lt;/P&gt;&lt;P&gt;Is it possible to manage user roles not only from Ambari GUI? Blueprints? Some configs?&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2017 16:32:54 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173244#M58021</guid>
      <dc:creator>vladislav_falfu</dc:creator>
      <dc:date>2017-03-24T16:32:54Z</dc:date>
    </item>
    <item>
      <title>Re: Manage Ambari user roles</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173245#M58022</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/3296/vladislavfalfushinsky.html" nodeid="3296"&gt;@Vladislav Falfushinsky&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Do you want to use Ambari APIs to manage user roles/groups/users.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.hortonworks.com/content/supportkb/49416/managing-ambari-users-and-groups-with-the-rest-api.html" target="_blank"&gt;https://community.hortonworks.com/content/supportkb/49416/managing-ambari-users-and-groups-with-the-rest-api.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2017 16:42:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173245#M58022</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2017-03-24T16:42:07Z</dc:date>
    </item>
    <item>
      <title>Re: Manage Ambari user roles</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173246#M58023</link>
      <description>&lt;P&gt;Thanks &lt;A rel="user" href="https://community.cloudera.com/users/3418/jsensharma.html" nodeid="3418"&gt;@Jay SenSharma&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Ambari API is also ok. Is there a possibility to use Blueprints or ambari-server setup utility for this? Looked both but had not found proper option.
&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2017 16:51:44 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173246#M58023</guid>
      <dc:creator>vladislav_falfu</dc:creator>
      <dc:date>2017-03-24T16:51:44Z</dc:date>
    </item>
    <item>
      <title>Re: Manage Ambari user roles</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173247#M58024</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/3296/vladislavfalfushinsky.html" nodeid="3296"&gt;@Vladislav Falfushinsky&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Ambari Blueprints are a declarative definition of a cluster. It does not contain any ambari DB users/group related information's. With a Blueprint, you specify a stack the Component layout and the Configurations to materialize a Hadoop cluster instance (via a REST API)&lt;STRONG&gt; &lt;/STRONG&gt;without having to use the Ambari Cluster Install Wizard.  &lt;A href="https://cwiki.apache.org/confluence/display/AMBARI/Blueprints#Blueprints-Introduction" target="_blank"&gt;https://cwiki.apache.org/confluence/display/AMBARI/Blueprints#Blueprints-Introduction&lt;/A&gt;&lt;/P&gt;&lt;P&gt;- "ambari-server setup" also does not have any feature to create users/groups. But if you have LDAP / Active Directory configured then you can sync users/groups using   ldap-sync option. &lt;A href="https://docs.hortonworks.com/HDPDocuments/Ambari-2.4.0.0/bk_ambari-security/content/synchronizing_ldap_users_and_groups.html" target="_blank"&gt;https://docs.hortonworks.com/HDPDocuments/Ambari-2.4.0.0/bk_ambari-security/content/synchronizing_ldap_users_and_groups.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2017 16:56:20 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173247#M58024</guid>
      <dc:creator>jsensharma</dc:creator>
      <dc:date>2017-03-24T16:56:20Z</dc:date>
    </item>
    <item>
      <title>Re: Manage Ambari user roles</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173248#M58025</link>
      <description>&lt;P&gt;Thanks for answers. Will try to use API. However had not found any possibility to manage cluster roles with that tool.&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2017 17:04:21 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173248#M58025</guid>
      <dc:creator>vladislav_falfu</dc:creator>
      <dc:date>2017-03-24T17:04:21Z</dc:date>
    </item>
    <item>
      <title>Re: Manage Ambari user roles</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173249#M58026</link>
      <description>&lt;P&gt;To manage user role (aka privileges) through the API, there are several entry point that can be used.  &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;To set an Ambari administrator:&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;/api/v1/clusters/privileges
&lt;/PRE&gt;&lt;P&gt;Payload:&lt;/P&gt;&lt;PRE&gt;[
  {
    "PrivilegeInfo": {
      "type": "AMBARI",
      "permission_name": "AMBARI.ADMINISTRATOR",
      "principal_name": "username",
      "principal_type": "USER"
    }
  }
]&lt;/PRE&gt;&lt;P&gt;Notes: &lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Change the &lt;B&gt;&lt;EM&gt;principal_name&lt;/EM&gt;&lt;/B&gt; (in the payload) value to the relevant username&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;To set a cluster role:&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;/api/v1/clusters/:CLUSTER_NAME/privileges&lt;/PRE&gt;&lt;P&gt;Payload:&lt;/P&gt;&lt;PRE&gt;[
  {
    "PrivilegeInfo": {
      "permission_name": "PERMISSION_NAME",
      "principal_name": "username",
      "principal_type": "USER"
    }
  }
]&lt;/PRE&gt;&lt;P&gt;Notes: &lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Change &lt;STRONG&gt;&lt;EM&gt;:CLUSTER_NAME&lt;/EM&gt;&lt;/STRONG&gt; (in the URL) to the relevant cluster's name&lt;/LI&gt;&lt;LI&gt;Change the &lt;STRONG&gt;&lt;EM&gt;permission_name&lt;/EM&gt;&lt;/STRONG&gt; (in the payload) value to the relevant permission name&lt;UL&gt;&lt;LI&gt;CLUSTER.ADMINISTRATOR&lt;/LI&gt;&lt;LI&gt;CLUSTER.OPERATOR&lt;/LI&gt;&lt;LI&gt;SERVICE.ADMINISTRATOR&lt;/LI&gt;&lt;LI&gt;SERVICE.OPERATOR&lt;/LI&gt;&lt;LI&gt;CLUSTER.USER&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;Change the &lt;STRONG&gt;&lt;EM&gt;principal_name&lt;/EM&gt;&lt;/STRONG&gt; (in the payload) value to the relevant username&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;To give access to a view:&lt;/STRONG&gt;&lt;/P&gt;&lt;PRE&gt;/api/v1/views/:VIEW_TYPE/versions/:VIEW_VERSION/instances/:VIEW_INSTANCE/privileges&lt;/PRE&gt;&lt;P&gt;Payload:&lt;/P&gt;&lt;PRE&gt;[
  {
    "PrivilegeInfo": {
      "permission_name": "VIEW.USER",
      "principal_name": "username",
      "principal_type": "USER"
    }
  }
]&lt;/PRE&gt;&lt;P&gt;Notes: &lt;/P&gt;&lt;UL&gt;
&lt;LI&gt;Change &lt;STRONG&gt;&lt;EM&gt;:VIEW_TYPE&lt;/EM&gt;&lt;/STRONG&gt; (in the URL) to the relevant view type (i.e., FILES)&lt;/LI&gt;&lt;LI&gt;Change &lt;STRONG&gt;&lt;EM&gt;:VIEW_VERSION&lt;/EM&gt;&lt;/STRONG&gt; (in the URL) to the relevant view type's version (i.e., 1.0.0) &lt;/LI&gt;&lt;LI&gt;Change &lt;STRONG&gt;&lt;EM&gt;:VIEW_INSTANCE&lt;/EM&gt;&lt;/STRONG&gt; (in the URL) to the relevant view type's version instance (i.e., MyFilesView) &lt;/LI&gt;&lt;LI&gt;Change the &lt;STRONG&gt;&lt;EM&gt;principal_name&lt;/EM&gt;&lt;/STRONG&gt; (in the payload) value to the relevant username&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Fri, 24 Mar 2017 18:24:42 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173249#M58026</guid>
      <dc:creator>rlevas</dc:creator>
      <dc:date>2017-03-24T18:24:42Z</dc:date>
    </item>
    <item>
      <title>Re: Manage Ambari user roles</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173250#M58027</link>
      <description>&lt;P&gt;That I was looking into. May thanks!!!!&lt;/P&gt;&lt;P&gt;According to the above reply:&lt;/P&gt;&lt;P&gt;1) To delete privileges:&lt;/P&gt;&lt;P&gt;curl -H "X-Requested-By: ambari" -X DELETE -u admin:admin "https://yourcluster.com:8443/api/v1/clusters/yourclustername/privileges/1"&lt;/P&gt;&lt;P&gt;2) To add:&lt;/P&gt;&lt;P&gt;curl -H "X-Requested-By: ambari" -X POST --data-binary "@your_privileges_file.json" -u admin:admin "https:///yourcluster.com:8443/api/v1/clusters/yourclustername/privileges/"&lt;/P&gt;&lt;P&gt;Privilege example:&lt;/P&gt;&lt;PRE&gt;{
"PrivilegeInfo" : {
    "permission_name" : "CLUSTER.USER",
    "principal_name" : "your-group",
    "principal_type" : "GROUP"
  }
}&lt;/PRE&gt;</description>
      <pubDate>Fri, 24 Mar 2017 19:00:12 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Manage-Ambari-user-roles/m-p/173250#M58027</guid>
      <dc:creator>vladislav_falfu</dc:creator>
      <dc:date>2017-03-24T19:00:12Z</dc:date>
    </item>
  </channel>
</rss>

