You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@ambari.apache.org by Sebastian Toader <st...@hortonworks.com> on 2017/01/29 20:43:10 UTC

Review Request 56064: Format ZKFC commands failing while enabling NameNode HA

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/56064/
-----------------------------------------------------------

Review request for Ambari, Attila Magyar, Laszlo Puskas, and Robert Levas.


Bugs: AMBARI-19736
    https://issues.apache.org/jira/browse/AMBARI-19736


Repository: ambari


Description
-------

Format ZKFC commands failing while enabling NameNode HA at Initializa Metadata step.

```
Caused by: org.apache.zookeeper.KeeperException$NoAuthException: KeeperErrorCode = NoAuth for /hadoop-ha/nameservice
	at org.apache.zookeeper.KeeperException.create(KeeperException.java:113)
	at org.apache.zookeeper.KeeperException.create(KeeperException.java:51)
	at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:783)
	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:1000)
	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:997)
	at org.apache.hadoop.ha.ActiveStandbyElector.zkDoWithRetries(ActiveStandbyElector.java:1041)
	at org.apache.hadoop.ha.ActiveStandbyElector.createWithRetries(ActiveStandbyElector.java:997)
	at org.apache.hadoop.ha.ActiveStandbyElector.ensureParentZNode(ActiveStandbyElector.java:344)
	... 11 more
```
 
The reason for the failure is that the `hdfs_jaas.conf` file is generated during ZKFC component configuration. When NN HA is enabled via UI the ZKFC is not added yet to the cluster thus the `hdfs_jaas.conf` file is not generated yet, this leading the format ZKFC commands to fail as this require the jaas file.

The solution is to move the creation of `hdfs_jaas.conf` file into the NN configuration.


Diffs
-----

  ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py a2edf38 
  ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/utils.py 03aba7b 
  ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py bfc9429 
  ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/hdfs_namenode.py 7fae57f 
  ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/utils.py 9eebe63 
  ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/zkfc_slave.py f2ea6ad 
  ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py 8e0e783 
  ambari-server/src/main/resources/stacks/HDP/3.0/hooks/before-ANY/scripts/params.py 8e5d210 

Diff: https://reviews.apache.org/r/56064/diff/


Testing
-------

Manual testing using both wizzard and blueprints.

Unit tests:
```
mvn test -DskipSurefireTests -am -pl ambari-server


[INFO] Reactor Summary:
[INFO] 
[INFO] Ambari Main ....................................... SUCCESS [11.634s]
[INFO] Apache Ambari Project POM ......................... SUCCESS [0.045s]
[INFO] Ambari Views ...................................... SUCCESS [2.086s]
[INFO] utility ........................................... SUCCESS [1.175s]
[INFO] ambari-metrics .................................... SUCCESS [0.608s]
[INFO] Ambari Metrics Common ............................. SUCCESS [0.352s]
[INFO] Ambari Server ..................................... SUCCESS [2:25.628s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
```


Thanks,

Sebastian Toader


Re: Review Request 56064: Format ZKFC commands failing while enabling NameNode HA

Posted by Robert Levas <rl...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/56064/#review163517
-----------------------------------------------------------


Ship it!




Ship It!

- Robert Levas


On Jan. 29, 2017, 3:43 p.m., Sebastian Toader wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/56064/
> -----------------------------------------------------------
> 
> (Updated Jan. 29, 2017, 3:43 p.m.)
> 
> 
> Review request for Ambari, Attila Magyar, Laszlo Puskas, and Robert Levas.
> 
> 
> Bugs: AMBARI-19736
>     https://issues.apache.org/jira/browse/AMBARI-19736
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Format ZKFC commands failing while enabling NameNode HA at Initializa Metadata step.
> 
> ```
> Caused by: org.apache.zookeeper.KeeperException$NoAuthException: KeeperErrorCode = NoAuth for /hadoop-ha/nameservice
> 	at org.apache.zookeeper.KeeperException.create(KeeperException.java:113)
> 	at org.apache.zookeeper.KeeperException.create(KeeperException.java:51)
> 	at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:783)
> 	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:1000)
> 	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:997)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.zkDoWithRetries(ActiveStandbyElector.java:1041)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.createWithRetries(ActiveStandbyElector.java:997)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.ensureParentZNode(ActiveStandbyElector.java:344)
> 	... 11 more
> ```
>  
> The reason for the failure is that the `hdfs_jaas.conf` file is generated during ZKFC component configuration. When NN HA is enabled via UI the ZKFC is not added yet to the cluster thus the `hdfs_jaas.conf` file is not generated yet, this leading the format ZKFC commands to fail as this require the jaas file.
> 
> The solution is to move the creation of `hdfs_jaas.conf` file into the NN configuration.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py a2edf38 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/utils.py 03aba7b 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py bfc9429 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/hdfs_namenode.py 7fae57f 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/utils.py 9eebe63 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/zkfc_slave.py f2ea6ad 
>   ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py 8e0e783 
>   ambari-server/src/main/resources/stacks/HDP/3.0/hooks/before-ANY/scripts/params.py 8e5d210 
> 
> Diff: https://reviews.apache.org/r/56064/diff/
> 
> 
> Testing
> -------
> 
> Manual testing using both wizzard and blueprints.
> 
> Unit tests:
> ```
> mvn test -DskipSurefireTests -am -pl ambari-server
> 
> 
> [INFO] Reactor Summary:
> [INFO] 
> [INFO] Ambari Main ....................................... SUCCESS [11.634s]
> [INFO] Apache Ambari Project POM ......................... SUCCESS [0.045s]
> [INFO] Ambari Views ...................................... SUCCESS [2.086s]
> [INFO] utility ........................................... SUCCESS [1.175s]
> [INFO] ambari-metrics .................................... SUCCESS [0.608s]
> [INFO] Ambari Metrics Common ............................. SUCCESS [0.352s]
> [INFO] Ambari Server ..................................... SUCCESS [2:25.628s]
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> ```
> 
> 
> Thanks,
> 
> Sebastian Toader
> 
>


Re: Review Request 56064: Format ZKFC commands failing while enabling NameNode HA

Posted by Attila Magyar <am...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/56064/#review163482
-----------------------------------------------------------


Ship it!




Ship It!

- Attila Magyar


On Jan. 29, 2017, 8:43 p.m., Sebastian Toader wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/56064/
> -----------------------------------------------------------
> 
> (Updated Jan. 29, 2017, 8:43 p.m.)
> 
> 
> Review request for Ambari, Attila Magyar, Laszlo Puskas, and Robert Levas.
> 
> 
> Bugs: AMBARI-19736
>     https://issues.apache.org/jira/browse/AMBARI-19736
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Format ZKFC commands failing while enabling NameNode HA at Initializa Metadata step.
> 
> ```
> Caused by: org.apache.zookeeper.KeeperException$NoAuthException: KeeperErrorCode = NoAuth for /hadoop-ha/nameservice
> 	at org.apache.zookeeper.KeeperException.create(KeeperException.java:113)
> 	at org.apache.zookeeper.KeeperException.create(KeeperException.java:51)
> 	at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:783)
> 	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:1000)
> 	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:997)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.zkDoWithRetries(ActiveStandbyElector.java:1041)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.createWithRetries(ActiveStandbyElector.java:997)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.ensureParentZNode(ActiveStandbyElector.java:344)
> 	... 11 more
> ```
>  
> The reason for the failure is that the `hdfs_jaas.conf` file is generated during ZKFC component configuration. When NN HA is enabled via UI the ZKFC is not added yet to the cluster thus the `hdfs_jaas.conf` file is not generated yet, this leading the format ZKFC commands to fail as this require the jaas file.
> 
> The solution is to move the creation of `hdfs_jaas.conf` file into the NN configuration.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py a2edf38 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/utils.py 03aba7b 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py bfc9429 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/hdfs_namenode.py 7fae57f 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/utils.py 9eebe63 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/zkfc_slave.py f2ea6ad 
>   ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py 8e0e783 
>   ambari-server/src/main/resources/stacks/HDP/3.0/hooks/before-ANY/scripts/params.py 8e5d210 
> 
> Diff: https://reviews.apache.org/r/56064/diff/
> 
> 
> Testing
> -------
> 
> Manual testing using both wizzard and blueprints.
> 
> Unit tests:
> ```
> mvn test -DskipSurefireTests -am -pl ambari-server
> 
> 
> [INFO] Reactor Summary:
> [INFO] 
> [INFO] Ambari Main ....................................... SUCCESS [11.634s]
> [INFO] Apache Ambari Project POM ......................... SUCCESS [0.045s]
> [INFO] Ambari Views ...................................... SUCCESS [2.086s]
> [INFO] utility ........................................... SUCCESS [1.175s]
> [INFO] ambari-metrics .................................... SUCCESS [0.608s]
> [INFO] Ambari Metrics Common ............................. SUCCESS [0.352s]
> [INFO] Ambari Server ..................................... SUCCESS [2:25.628s]
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> ```
> 
> 
> Thanks,
> 
> Sebastian Toader
> 
>


Re: Review Request 56064: Format ZKFC commands failing while enabling NameNode HA

Posted by Laszlo Puskas <lp...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/56064/#review163483
-----------------------------------------------------------


Ship it!




Ship It!

- Laszlo Puskas


On Jan. 29, 2017, 8:43 p.m., Sebastian Toader wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/56064/
> -----------------------------------------------------------
> 
> (Updated Jan. 29, 2017, 8:43 p.m.)
> 
> 
> Review request for Ambari, Attila Magyar, Laszlo Puskas, and Robert Levas.
> 
> 
> Bugs: AMBARI-19736
>     https://issues.apache.org/jira/browse/AMBARI-19736
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Format ZKFC commands failing while enabling NameNode HA at Initializa Metadata step.
> 
> ```
> Caused by: org.apache.zookeeper.KeeperException$NoAuthException: KeeperErrorCode = NoAuth for /hadoop-ha/nameservice
> 	at org.apache.zookeeper.KeeperException.create(KeeperException.java:113)
> 	at org.apache.zookeeper.KeeperException.create(KeeperException.java:51)
> 	at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:783)
> 	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:1000)
> 	at org.apache.hadoop.ha.ActiveStandbyElector$3.run(ActiveStandbyElector.java:997)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.zkDoWithRetries(ActiveStandbyElector.java:1041)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.createWithRetries(ActiveStandbyElector.java:997)
> 	at org.apache.hadoop.ha.ActiveStandbyElector.ensureParentZNode(ActiveStandbyElector.java:344)
> 	... 11 more
> ```
>  
> The reason for the failure is that the `hdfs_jaas.conf` file is generated during ZKFC component configuration. When NN HA is enabled via UI the ZKFC is not added yet to the cluster thus the `hdfs_jaas.conf` file is not generated yet, this leading the format ZKFC commands to fail as this require the jaas file.
> 
> The solution is to move the creation of `hdfs_jaas.conf` file into the NN configuration.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py a2edf38 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/utils.py 03aba7b 
>   ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py bfc9429 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/hdfs_namenode.py 7fae57f 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/utils.py 9eebe63 
>   ambari-server/src/main/resources/common-services/HDFS/3.0.0.3.0/package/scripts/zkfc_slave.py f2ea6ad 
>   ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py 8e0e783 
>   ambari-server/src/main/resources/stacks/HDP/3.0/hooks/before-ANY/scripts/params.py 8e5d210 
> 
> Diff: https://reviews.apache.org/r/56064/diff/
> 
> 
> Testing
> -------
> 
> Manual testing using both wizzard and blueprints.
> 
> Unit tests:
> ```
> mvn test -DskipSurefireTests -am -pl ambari-server
> 
> 
> [INFO] Reactor Summary:
> [INFO] 
> [INFO] Ambari Main ....................................... SUCCESS [11.634s]
> [INFO] Apache Ambari Project POM ......................... SUCCESS [0.045s]
> [INFO] Ambari Views ...................................... SUCCESS [2.086s]
> [INFO] utility ........................................... SUCCESS [1.175s]
> [INFO] ambari-metrics .................................... SUCCESS [0.608s]
> [INFO] Ambari Metrics Common ............................. SUCCESS [0.352s]
> [INFO] Ambari Server ..................................... SUCCESS [2:25.628s]
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> ```
> 
> 
> Thanks,
> 
> Sebastian Toader
> 
>