ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From srihar...@apache.org
Subject ambari git commit: AMBARI-19860: Ambari upgrade to HDP 2.5 from earlier versions does not update storm worker log directory.
Date Tue, 07 Feb 2017 18:12:59 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 7a072aafc -> 1adf27d18


AMBARI-19860: Ambari upgrade to HDP 2.5 from earlier versions does not update storm worker
log directory.


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

Branch: refs/heads/trunk
Commit: 1adf27d1866aac2293c6708d911c0124abe18f69
Parents: 7a072aa
Author: Arun Mahadevan <aiyer@hortonworks.com>
Authored: Tue Feb 7 10:12:30 2017 -0800
Committer: Sriharsha Chintalapani <harsha@hortonworks.com>
Committed: Tue Feb 7 10:12:30 2017 -0800

----------------------------------------------------------------------
 .../resources/stacks/HDP/2.3/upgrades/config-upgrade.xml     | 2 ++
 .../resources/stacks/HDP/2.4/upgrades/config-upgrade.xml     | 2 ++
 .../resources/stacks/HDP/2.5/upgrades/config-upgrade.xml     | 7 +++++++
 .../stacks/HDP/2.5/upgrades/nonrolling-upgrade-2.5.xml       | 8 +++++++-
 .../main/resources/stacks/HDP/2.5/upgrades/upgrade-2.5.xml   | 2 +-
 5 files changed, 19 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/1adf27d1/ambari-server/src/main/resources/stacks/HDP/2.3/upgrades/config-upgrade.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.3/upgrades/config-upgrade.xml b/ambari-server/src/main/resources/stacks/HDP/2.3/upgrades/config-upgrade.xml
index 0277a4e..eac318e 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.3/upgrades/config-upgrade.xml
+++ b/ambari-server/src/main/resources/stacks/HDP/2.3/upgrades/config-upgrade.xml
@@ -598,6 +598,8 @@
             <set key="storm_wrkr_out_maxbackupindex" value="4"/>
             <set key="storm_wrkr_err_maxfilesize" value="100"/>
             <set key="storm_wrkr_err_maxbackupindex" value="4"/>
+            <regex-replace key="content" find="\$\{sys:storm.log.dir}/\$\{sys:logfile.name}"
+                           replace-with="${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}"/>
             <regex-replace key="content" find="A1&quot;&#xA;&#009;&#009;fileName=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}&quot;&#xA;&#009;&#009;filePattern=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;\$\{pattern}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;(?:[0-9]+) MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;([0-9]+)"
                            replace-with="A1&quot;&#xA;&#009;&#009;fileName=&quot;${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}&quot;&#xA;&#009;&#009;filePattern=&quot;${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;${pattern}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;{{storm_wrkr_a1_maxfilesize}} MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;{{storm_wrkr_a1_maxbackupindex}}"/>
             <regex-replace key="content" find="STDOUT&quot;&#xA;&#009;&#009;fileName=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.out&quot;&#xA;&#009;&#009;filePattern=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.out.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;\$\{patternNoTime}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;(?:[0-9]+) MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;([0-9]+)"

http://git-wip-us.apache.org/repos/asf/ambari/blob/1adf27d1/ambari-server/src/main/resources/stacks/HDP/2.4/upgrades/config-upgrade.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.4/upgrades/config-upgrade.xml b/ambari-server/src/main/resources/stacks/HDP/2.4/upgrades/config-upgrade.xml
index 7cb727f..cc50ac5 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.4/upgrades/config-upgrade.xml
+++ b/ambari-server/src/main/resources/stacks/HDP/2.4/upgrades/config-upgrade.xml
@@ -428,6 +428,8 @@
             <set key="storm_wrkr_out_maxbackupindex" value="4"/>
             <set key="storm_wrkr_err_maxfilesize" value="100"/>
             <set key="storm_wrkr_err_maxbackupindex" value="4"/>
+            <regex-replace key="content" find="\$\{sys:storm.log.dir}/\$\{sys:logfile.name}"
+                           replace-with="${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}"/>
             <regex-replace key="content" find="A1&quot;&#xA;&#009;&#009;fileName=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}&quot;&#xA;&#009;&#009;filePattern=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;\$\{pattern}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;(?:[0-9]+) MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;([0-9]+)"
                            replace-with="A1&quot;&#xA;&#009;&#009;fileName=&quot;${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}&quot;&#xA;&#009;&#009;filePattern=&quot;${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;${pattern}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;{{storm_wrkr_a1_maxfilesize}} MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;{{storm_wrkr_a1_maxbackupindex}}"/>
             <regex-replace key="content" find="STDOUT&quot;&#xA;&#009;&#009;fileName=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.out&quot;&#xA;&#009;&#009;filePattern=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.out.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;\$\{patternNoTime}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;(?:[0-9]+) MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;([0-9]+)"

http://git-wip-us.apache.org/repos/asf/ambari/blob/1adf27d1/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/config-upgrade.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/config-upgrade.xml b/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/config-upgrade.xml
index 54a824d..a5bfcf6 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/config-upgrade.xml
+++ b/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/config-upgrade.xml
@@ -41,6 +41,11 @@
                  if-type="storm-site"
                  if-value="15000" />
           </definition>
+          <definition xsi:type="configure" id="storm_worker_log4j_update_path" summary="Updating
Storm Worker Log4J Path">
+            <type>storm-worker-log4j</type>
+            <regex-replace key="content" find="\$\{sys:storm.log.dir}/\$\{sys:logfile.name}"
+                           replace-with="${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}"/>
+          </definition>
           <definition xsi:type="configure" id="storm_worker_log4j_parameterize" summary="Parameterizing
Storm Worker Log4J Properties">
             <type>storm-worker-log4j</type>
             <set key="storm_wrkr_a1_maxfilesize" value="100"/>
@@ -49,6 +54,8 @@
             <set key="storm_wrkr_out_maxbackupindex" value="4"/>
             <set key="storm_wrkr_err_maxfilesize" value="100"/>
             <set key="storm_wrkr_err_maxbackupindex" value="4"/>
+            <regex-replace key="content" find="\$\{sys:storm.log.dir}/\$\{sys:logfile.name}"
+                           replace-with="${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}"/>
             <regex-replace key="content" find="A1&quot;&#xA;&#009;&#009;fileName=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}&quot;&#xA;&#009;&#009;filePattern=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;\$\{pattern}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;(?:[0-9]+) MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;([0-9]+)"
                                          replace-with="A1&quot;&#xA;&#009;&#009;fileName=&quot;${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}&quot;&#xA;&#009;&#009;filePattern=&quot;${sys:workers.artifacts}/${sys:storm.id}/${sys:worker.port}/${sys:logfile.name}.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;${pattern}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;{{storm_wrkr_a1_maxfilesize}} MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;{{storm_wrkr_a1_maxbackupindex}}"/>
             <regex-replace key="content" find="STDOUT&quot;&#xA;&#009;&#009;fileName=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.out&quot;&#xA;&#009;&#009;filePattern=&quot;\$\{sys:workers.artifacts}/\$\{sys:storm.id}/\$\{sys:worker.port}/\$\{sys:logfile.name}.out.%i.gz&quot;&gt;&#xA;
       &lt;PatternLayout&gt;&#xA;            &lt;pattern&gt;\$\{patternNoTime}&lt;/pattern&gt;&#xA;
       &lt;/PatternLayout&gt;&#xA;        &lt;Policies&gt;&#xA;  
         &lt;SizeBasedTriggeringPolicy size=&quot;(?:[0-9]+) MB&quot;/&gt;
&lt;!-- Or every 100 MB --&gt;&#xA;        &lt;/Policies&gt;&#xA;
       &lt;DefaultRolloverStrategy max=&quot;([0-9]+)"

http://git-wip-us.apache.org/repos/asf/ambari/blob/1adf27d1/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/nonrolling-upgrade-2.5.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/nonrolling-upgrade-2.5.xml
b/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/nonrolling-upgrade-2.5.xml
index a1c9a16..607f444 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/nonrolling-upgrade-2.5.xml
+++ b/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/nonrolling-upgrade-2.5.xml
@@ -299,10 +299,16 @@
       <execute-stage service="STORM" component="NIMBUS" title="Apply config changes for
Storm">
         <task xsi:type="configure" id="hdp_2_5_0_0_remove_empty_storm_topology_submission_notifier_plugin_class"/>
       </execute-stage>
-
       <execute-stage service="STORM" component="NIMBUS" title="Apply config changes for
Nimbus">
         <task xsi:type="configure" id="increase_storm_zookeeper_timeouts"/>
       </execute-stage>
+
+      <execute-stage service="STORM" component="NIMBUS" title="Updating Storm Worker Log4J
Path">
+        <task xsi:type="configure" id="storm_worker_log4j_update_path">
+          <summary>Updating the Storm worker Log4J path</summary>
+        </task>
+      </execute-stage>
+
     </group>
 
     <!--

http://git-wip-us.apache.org/repos/asf/ambari/blob/1adf27d1/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/upgrade-2.5.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/upgrade-2.5.xml b/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/upgrade-2.5.xml
index 7205924..b1bbe16 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/upgrade-2.5.xml
+++ b/ambari-server/src/main/resources/stacks/HDP/2.5/upgrades/upgrade-2.5.xml
@@ -868,8 +868,8 @@
       <component name="NIMBUS">
         <pre-upgrade>
           <task xsi:type="configure" id="hdp_2_5_0_0_remove_empty_storm_topology_submission_notifier_plugin_class"/>
-
           <task xsi:type="configure" id="increase_storm_zookeeper_timeouts"/>
+          <task xsi:type="configure" id="storm_worker_log4j_update_path" />
         </pre-upgrade>
         
         <pre-downgrade />


Mime
View raw message