Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-11147

MetaTool doesn't update FS root location for partitions with space in name

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.3.0, 2.0.0
    • Metastore
    • None

    Description

      Problem happens when trying to update the FS root location:

      # HIVE_CONF_DIR=/etc/hive/conf.server/ hive --service metatool -dryRun -updateLocation hdfs://mycluster hdfs://c6401.ambari.apache.org:8020
      ...
      Looking for LOCATION_URI field in DBS table to update..
      Dry Run of updateLocation on table DBS..
      old location: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse new location: hdfs://mycluster/apps/hive/warehouse
      Found 1 records in DBS table to update
      Looking for LOCATION field in SDS table to update..
      Dry Run of updateLocation on table SDS..
      old location: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/web_sales/ws_web_site_sk=12 new location: hdfs://mycluster/apps/hive/warehouse/web_sales/ws_web_site_sk=12
      old location: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/web_sales/ws_web_site_sk=13 new location: hdfs://mycluster/apps/hive/warehouse/web_sales/ws_web_site_sk=13
      ...
      Found 143 records in SDS table to update
      Warning: Found records with bad LOCATION in SDS table..
      bad location URI: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/customer_demographics/cd_education_status=Advanced Degree
      bad location URI: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/customer_demographics/cd_education_status=Advanced Degree
      bad location URI: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/customer_demographics/cd_education_status=4 yr Degree
      bad location URI: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/customer_demographics/cd_education_status=4 yr Degree
      bad location URI: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/customer_demographics/cd_education_status=2 yr Degree
      bad location URI: hdfs://c6401.ambari.apache.org:8020/apps/hive/warehouse/customer_demographics/cd_education_status=2 yr Degree
      

      The reason why some entries are marked as bad location is that they have space character in the partition name.

      Attachments

        1. HIVE-11147.01.patch
          3 kB
          Wei Zheng

        Issue Links

          Activity

            People

              wzheng Wei Zheng
              wzheng Wei Zheng
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: