Browse Source

AMBARI-5511. Misleading hardcoded command in paragraph 2 on step "Manual commands" of "Move Master" wizard (alexantonenko)

Alex Antonenko 11 years ago
parent
commit
0a21401f6a

+ 2 - 2
ambari-web/app/messages.js

@@ -1325,7 +1325,7 @@ Em.I18n.translations = {
       '<ol>' +
       '<ol>' +
       '<li>Copy the contents of <b>{0}</b> on the source host <b>{1}</b> to <b>{0}</b> on the target host <b>{2}</b>.</li>' +
       '<li>Copy the contents of <b>{0}</b> on the source host <b>{1}</b> to <b>{0}</b> on the target host <b>{2}</b>.</li>' +
       '<li>Login to the target host <b>{2}</b> and change permissions for the NameNode dirs by running:' +
       '<li>Login to the target host <b>{2}</b> and change permissions for the NameNode dirs by running:' +
-      '<div class="code-snippet">chown -R {3}:{5} /hadoop/hdfs/namenode/</div></li>' +
+      '<div class="code-snippet">chown -R {3}:{5} {6}</div></li>' +
       '<li>Create marker directory by running:' +
       '<li>Create marker directory by running:' +
       '<div class="code-snippet">mkdir -p /var/run/hadoop/hdfs/namenode/formatted</div></li>' +
       '<div class="code-snippet">mkdir -p /var/run/hadoop/hdfs/namenode/formatted</div></li>' +
       '</ol>' +
       '</ol>' +
@@ -1352,7 +1352,7 @@ Em.I18n.translations = {
       '<ol>' +
       '<ol>' +
       '<li>Copy the contents of <b>{0}</b> on the source host <b>{1}</b> to <b>{0}</b> on the target host <b>{2}</b>.</li>' +
       '<li>Copy the contents of <b>{0}</b> on the source host <b>{1}</b> to <b>{0}</b> on the target host <b>{2}</b>.</li>' +
       '<li>Login to the target host <b>{2}</b> and change permissions for the SNameNode dirs by running:' +
       '<li>Login to the target host <b>{2}</b> and change permissions for the SNameNode dirs by running:' +
-      '<div class="code-snippet">chown -R {3}:{5} /hadoop/hdfs/namesecondary/</div></li>' +
+      '<div class="code-snippet">chown -R {3}:{5} {6}</div></li>' +
       '</ol>' +
       '</ol>' +
       '</div>',
       '</div>',
   'services.reassign.step5.body.securityNotice': '<div class="alert alert-info"> <div class="alert alert-warn"> <strong>Note: </strong> Secure cluster' +
   'services.reassign.step5.body.securityNotice': '<div class="alert alert-info"> <div class="alert alert-warn"> <strong>Note: </strong> Secure cluster' +

+ 2 - 1
ambari-web/app/views/main/service/reassign/step5_view.js

@@ -28,6 +28,7 @@ App.ReassignMasterWizardStep5View = Em.View.extend({
       return '';
       return '';
     }
     }
     var componentDir = this.get('controller.content.componentDir');
     var componentDir = this.get('controller.content.componentDir');
+    var componentDirCmd = componentDir.replace(/,/g, ' ');
     var sourceHost = this.get('controller.content.reassignHosts.source');
     var sourceHost = this.get('controller.content.reassignHosts.source');
     var targetHost = this.get('controller.content.reassignHosts.target');
     var targetHost = this.get('controller.content.reassignHosts.target');
     var ha = '';
     var ha = '';
@@ -35,7 +36,7 @@ App.ReassignMasterWizardStep5View = Em.View.extend({
       ha = '_ha';
       ha = '_ha';
       var nnStartedHost = this.get('controller.content.masterComponentHosts').filterProperty('component', 'NAMENODE').mapProperty('hostName').without(this.get('controller.content.reassignHosts.target'));
       var nnStartedHost = this.get('controller.content.masterComponentHosts').filterProperty('component', 'NAMENODE').mapProperty('hostName').without(this.get('controller.content.reassignHosts.target'));
     }
     }
-    return  Em.I18n.t('services.reassign.step5.body.' + this.get('controller.content.reassign.component_name').toLowerCase() + ha).format(componentDir, sourceHost, targetHost, this.get('controller.content.hdfsUser'), nnStartedHost,this.get('controller.content.group'));
+    return Em.I18n.t('services.reassign.step5.body.' + this.get('controller.content.reassign.component_name').toLowerCase() + ha).format(componentDir, sourceHost, targetHost, this.get('controller.content.hdfsUser'), nnStartedHost,this.get('controller.content.group'), componentDirCmd);
   }.property('controller.content.reassign.component_name', 'controller.content.componentDir', 'controller.content.masterComponentHosts', 'controller.content.reassign.host_id', 'controller.content.hdfsUser'),
   }.property('controller.content.reassign.component_name', 'controller.content.componentDir', 'controller.content.masterComponentHosts', 'controller.content.reassign.host_id', 'controller.content.hdfsUser'),
 
 
   securityNotice: function () {
   securityNotice: function () {