ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dmitriu...@apache.org
Subject [1/2] ambari git commit: AMBARI-12391. Rolling upgrade failed on Hive restart for Centos 7 (dlysnichenko)
Date Mon, 13 Jul 2015 09:57:01 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.1 f28c2493e -> e2b2eb349
  refs/heads/trunk 99c5ab336 -> 871b1aaa8


AMBARI-12391. Rolling upgrade failed on Hive restart for Centos 7 (dlysnichenko)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/e2b2eb34
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/e2b2eb34
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/e2b2eb34

Branch: refs/heads/branch-2.1
Commit: e2b2eb3499793e0f4f5a27db93de8d7ae39c8e20
Parents: f28c249
Author: Lisnichenko Dmitro <dlysnichenko@hortonworks.com>
Authored: Mon Jul 13 12:51:16 2015 +0300
Committer: Lisnichenko Dmitro <dlysnichenko@hortonworks.com>
Committed: Mon Jul 13 12:51:16 2015 +0300

----------------------------------------------------------------------
 .../HIVE/0.12.0.2.0/package/scripts/hive_metastore.py           | 5 +++++
 .../src/test/python/stacks/2.1/HIVE/test_hive_metastore.py      | 4 ++++
 2 files changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/e2b2eb34/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_metastore.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_metastore.py
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_metastore.py
index a17ea4f..1a6c6c1 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_metastore.py
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive_metastore.py
@@ -32,6 +32,7 @@ from resource_management.libraries.functions.security_commons import cached_kini
 from resource_management.libraries.functions.security_commons import get_params_from_filesystem
 from resource_management.libraries.functions.security_commons import validate_security_config_properties
 from resource_management.libraries.functions.security_commons import FILE_TYPE_XML
+from resource_management.core.resources.system import File
 
 from hive import hive
 from hive import jdbc_connector
@@ -178,6 +179,10 @@ class HiveMetastoreDefault(HiveMetastore):
       Execute(('cp', params.target, target_directory),
         path=["/bin", "/usr/bin/"], sudo = True)
 
+      File(os.path.join(target_directory, os.path.basename(params.target)),
+        mode = 0644,
+      )
+
     # build the schema tool command
     binary = format("/usr/hdp/{version}/hive/bin/schematool")
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/e2b2eb34/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py b/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
index dc1933b..fab9e54 100644
--- a/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
+++ b/ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
@@ -577,6 +577,10 @@ class TestHiveMetastore(RMFTestCase):
       ('cp', '/usr/hdp/current/hive-server2/lib/mysql-connector-java.jar', '/usr/hdp/2.3.0.0-1234/hive/lib'),
       path = ['/bin', '/usr/bin/'], sudo = True)
 
+    self.assertResourceCalled('File', '/usr/hdp/2.3.0.0-1234/hive/lib/mysql-connector-java.jar',
+      mode = 0644,
+    )
+
     self.assertResourceCalled('Execute', "/usr/hdp/2.3.0.0-1234/hive/bin/schematool -dbType
mysql -upgradeSchema",
      logoutput = True, environment = {'HIVE_CONF_DIR': '/usr/hdp/current/hive-server2/conf/conf.server'},
       tries = 1, user = 'hive')


Mime
View raw message