Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-12291

Insert statement fails even if hdfs ranger policy allows it

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Duplicate
    • None
    • None
    • Frontend, Security
    • None
    • - Impala Version (4.1.0)
      - Ranger admin version (2.0)
      - Hive version (3.1.2)
    • ghx-label-7

    Description

      Apache Ranger is framework for providing security and authorization in hadoop platform.
      Impala can also utilize apache ranger via ranger hive policy.

      The thing is that insert or some other query is not executed even If you enable ranger hdfs plugin and set proper allow condition for impala query excuting.

      you can see error log like below.

      AnalysisException: Unable to INSERT into target table (testdb.testtable) because Impala does not have WRITE access to HDFS location: hdfs://testcluster/warehouse/testdb.db/testtable
      

      This happens when ranger hdfs plugin is enabled but impala doesn't have permission for hdfs POSIX permission.

      For example, In the case that DB file owner, group and permission is set as hdfs:hdfs r-xr-xr-- and ranger plugin policy(hdfs, hive and impala) allows impala to execute query, Insert Query will be fail.

      In my opinion, The main cause is impala fe component doesn't check ranger policy but hdfs POSIX model permissions.

      Similar issue : https://issues.apache.org/jira/browse/IMPALA-10272

      I'm working on resolving this issue by adding hdfs ranger policy checking code.

      Attachments

        Issue Links

          Activity

            People

              khr9603 halim kim
              khr9603 halim kim
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 0.5h
                  0.5h