<?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 Re: Permissions on /var/lib/&amp;lt;directory&amp;gt; causing services to fail. in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Permissions-on-var-lib-lt-directory-gt-causing-services-to/m-p/49826#M52133</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is not an expected condition, it would appear as though you are using a custom umask or SELinux is blocking certain operations performed by the agent. Please note that our documentation specifically states that you must disable SELinux before the deployment of CDH.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you intend to use SELinux you will need to design your own SELinux profiles that secure the envirnoment and allow for the many different types of operations performed across all host in your environment.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_dependencies.html" target="_blank"&gt;http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_dependencies.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_disable_selinux.html" target="_blank"&gt;http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_disable_selinux.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Trying to use SELinux in the hadoop stack is tedious because there are hundreds of tools and widgets which require complex SELinux Policies. Policies which must be revisited frequently when new features or changes occur in the platform.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That means that you can make Hadoop work with SELinux, it's not impossible but it requires a high level of continuous effort from the organization because no single vendor has created nor provides standardized policies which work in all cases. In fact if the apache foundation made standardized policies they still would not be entirely valid for environments managed by Cloudera Manager depending on the specificity of the policies.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunately I do not have a complete list of directories and permissions handy but here is example output from a lab environment.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;# namei -l /var/lib/* |egrep 'zookeeper|sqoop2|sqoop|spark|solr|sentry|oozie|hadoop'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-hdfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x hdfs hdfs hadoop-hdfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-httpfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x httpfs httpfs hadoop-httpfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-kms&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x kms kms hadoop-kms&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-mapreduce&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x mapred mapred hadoop-mapreduce&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-yarn&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x yarn yarn hadoop-yarn&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/oozie&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x oozie oozie oozie&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/sentry&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x sentry sentry sentry&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/solr&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x solr solr solr&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/spark&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x spark spark spark&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/sqoop&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x sqoop sqoop sqoop&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/sqoop2&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x sqoop2 sqoop2 sqoop2&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/zookeeper&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x zookeeper zookeeper zookeeper&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 23 Jan 2017 16:48:54 GMT</pubDate>
    <dc:creator>lhebert</dc:creator>
    <dc:date>2017-01-23T16:48:54Z</dc:date>
    <item>
      <title>Permissions on /var/lib/&lt;directory&gt; causing services to fail.</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Permissions-on-var-lib-lt-directory-gt-causing-services-to/m-p/49777#M52132</link>
      <description>&lt;P&gt;I am setting up a CDH (5.8) Cluster with Cloudera Manager and Parcels. Most of the services are installed and running fine with an exception of HDFS HTTPFS role and Oozie. I am using a custom parcel directory on the agents &amp;nbsp;and also I am running SELinux in Enforcing mode (Please dont ask me to put it to permissive &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; ).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Both has similar isssue where its trying to move some files (related to tomcat) from the parcel's directory to /var/lib/&amp;lt;directory&amp;gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I checked the permissions of the directories in /var/lib I could see that most of the directories are created without any permissions set on them.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;$ ls -l /var/lib/ | grep ^d-
d---------.  2 root         root            6 Jan 13 00:28 flume-ng
d---------.  2 root         root            6 Jan 13 00:28 hadoop-hdfs
d---------.  2 root         root            6 Jan 13 00:28 hadoop-httpfs
d---------.  2 root         root            6 Jan 13 00:28 hadoop-kms
d---------.  2 root         root            6 Jan 13 00:28 hadoop-mapreduce
d---------.  2 root         root            6 Jan 13 00:28 hadoop-yarn
d---------.  2 root         root            6 Jan 13 00:28 hbase
d---------.  2 root         root            6 Jan 13 00:28 hive
d---------.  2 root         root            6 Jan 13 00:28 impala
d---------.  2 root         root            6 Jan 13 00:29 kafka
d---------.  2 root         root            6 Jan 13 00:28 llama
d---------.  2 root         root            6 Jan 13 00:28 oozie
d---------.  2 root         root            6 Jan 13 00:28 sentry
d---------.  2 root         root            6 Jan 13 00:28 solr
d---------.  2 root         root            6 Jan 13 00:28 spark
d---------.  2 root         root            6 Jan 13 00:28 sqoop
d---------.  2 root         root            6 Jan 13 00:28 sqoop2
d---------.  2 root         root            6 Jan 13 00:28 zookeeper&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is this expected?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For Oozie, I changed the permission of /var/lib/oozie to 700 and changed the ownership to oozie:oozie fixed the issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What would be the reason for this permission issue and how could be this fixed.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2022 10:55:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Permissions-on-var-lib-lt-directory-gt-causing-services-to/m-p/49777#M52132</guid>
      <dc:creator>Ranjandas</dc:creator>
      <dc:date>2022-09-16T10:55:40Z</dc:date>
    </item>
    <item>
      <title>Re: Permissions on /var/lib/&lt;directory&gt; causing services to fail.</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Permissions-on-var-lib-lt-directory-gt-causing-services-to/m-p/49826#M52133</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is not an expected condition, it would appear as though you are using a custom umask or SELinux is blocking certain operations performed by the agent. Please note that our documentation specifically states that you must disable SELinux before the deployment of CDH.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you intend to use SELinux you will need to design your own SELinux profiles that secure the envirnoment and allow for the many different types of operations performed across all host in your environment.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_dependencies.html" target="_blank"&gt;http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_dependencies.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_disable_selinux.html" target="_blank"&gt;http://www.cloudera.com/documentation/enterprise/latest/topics/install_cdh_disable_selinux.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Trying to use SELinux in the hadoop stack is tedious because there are hundreds of tools and widgets which require complex SELinux Policies. Policies which must be revisited frequently when new features or changes occur in the platform.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That means that you can make Hadoop work with SELinux, it's not impossible but it requires a high level of continuous effort from the organization because no single vendor has created nor provides standardized policies which work in all cases. In fact if the apache foundation made standardized policies they still would not be entirely valid for environments managed by Cloudera Manager depending on the specificity of the policies.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunately I do not have a complete list of directories and permissions handy but here is example output from a lab environment.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;# namei -l /var/lib/* |egrep 'zookeeper|sqoop2|sqoop|spark|solr|sentry|oozie|hadoop'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-hdfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x hdfs hdfs hadoop-hdfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-httpfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x httpfs httpfs hadoop-httpfs&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-kms&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x kms kms hadoop-kms&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-mapreduce&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x mapred mapred hadoop-mapreduce&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/hadoop-yarn&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x yarn yarn hadoop-yarn&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/oozie&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x oozie oozie oozie&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/sentry&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x sentry sentry sentry&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/solr&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x solr solr solr&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/spark&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x spark spark spark&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/sqoop&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x sqoop sqoop sqoop&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/sqoop2&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x sqoop2 sqoop2 sqoop2&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;f: /var/lib/zookeeper&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;drwxr-xr-x zookeeper zookeeper zookeeper&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Jan 2017 16:48:54 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Permissions-on-var-lib-lt-directory-gt-causing-services-to/m-p/49826#M52133</guid>
      <dc:creator>lhebert</dc:creator>
      <dc:date>2017-01-23T16:48:54Z</dc:date>
    </item>
    <item>
      <title>Re: Permissions on /var/lib/&lt;directory&gt; causing services to fail.</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Permissions-on-var-lib-lt-directory-gt-causing-services-to/m-p/51151#M52134</link>
      <description>&lt;P&gt;Thank you&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/9182"&gt;@lhebert&lt;/a&gt;. Looks like it was actually caused by SELinux, and we now have custom selinux policies to overcome this issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 19 Feb 2017 08:22:20 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Permissions-on-var-lib-lt-directory-gt-causing-services-to/m-p/51151#M52134</guid>
      <dc:creator>Ranjandas</dc:creator>
      <dc:date>2017-02-19T08:22:20Z</dc:date>
    </item>
  </channel>
</rss>

