Re: Review Request 49596: ambari-server update-host-name failing

2016-07-04 Thread Dmitro Lisnichenko

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


Ship it!




Ship It!

- Dmitro Lisnichenko


On July 4, 2016, 6:47 p.m., Vitalyi Brodetskyi wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/49596/
> ---
> 
> (Updated July 4, 2016, 6:47 p.m.)
> 
> 
> Review request for Ambari, Andrew Onischuk, Dmitro Lisnichenko, and Dmytro 
> Sen.
> 
> 
> Bugs: AMBARI-17554
> https://issues.apache.org/jira/browse/AMBARI-17554
> 
> 
> Repository: ambari
> 
> 
> Description
> ---
> 
> Steps to reproduce :
> 
> 1) Run the following command on one of the hosts (which is not the ambari 
> server) in the cluster : 
> {code}
> hostname renamedHost-0
> {code}
> 2) On the ambari-server change the host name in the /etc/hosts for the host 
> whose name was changed in step1
> 3) Create a file like the following to indicate the host changed :
> {code}
> {
>   "cl1" : {
>   "renamedHost-0.openstacklocal" : 
> "rerenamedhost-0.openstacklocal"
>   }
> }
> {code}
> 
> 4) Run ambari-server update-host-name 
> The error shown :
> {code}
> 03 Jul 2016 07:24:31,914  INFO [main] Configuration:1022 - Reading password 
> from existing file
> 03 Jul 2016 07:24:31,931  INFO [main] Configuration:1491 - Hosts Mapping File 
> null
> 03 Jul 2016 07:24:31,932  INFO [main] HostsMap:60 - Using hostsmap file null
> 03 Jul 2016 07:24:32,742  INFO [main] ControllerModule:199 - Detected ORACLE 
> as the database type from the JDBC URL
> 03 Jul 2016 07:24:34,884  INFO [main] ControllerModule:607 - Binding and 
> registering notification dispatcher class 
> org.apache.ambari.server.notifications.dispatchers.SNMPDispatcher
> 03 Jul 2016 07:24:34,895  INFO [main] ControllerModule:607 - Binding and 
> registering notification dispatcher class 
> org.apache.ambari.server.notifications.dispatchers.EmailDispatcher
> 03 Jul 2016 07:24:34,905  INFO [main] ControllerModule:607 - Binding and 
> registering notification dispatcher class 
> org.apache.ambari.server.notifications.dispatchers.AlertScriptDispatcher
> 03 Jul 2016 07:24:38,223 ERROR [main] HostUpdateHelper:545 - Unexpected 
> error, host names update failed
> com.google.inject.CreationException: Guice creation errors:
> 
> 1) No implementation for org.apache.ambari.server.audit.AuditLogger was bound.
>   while locating org.apache.ambari.server.audit.AuditLogger
> for field at 
> org.apache.ambari.server.actionmanager.ActionDBAccessorImpl.auditLogger(ActionDBAccessorImpl.java:86)
>   at 
> org.apache.ambari.server.controller.ControllerModule.configure(ControllerModule.java:324)
> 
> 2) No implementation for org.apache.ambari.server.audit.AuditLogger was bound.
>   while locating org.apache.ambari.server.audit.AuditLogger
> for field at 
> org.apache.ambari.server.api.services.LogoutService.auditLogger(LogoutService.java:41)
>   at 
> org.apache.ambari.server.controller.ControllerModule.bindByAnnotation(ControllerModule.java:525)
> 
> 2 errors
> at 
> com.google.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:435)
> at 
> com.google.inject.internal.InternalInjectorCreator.initializeStatically(InternalInjectorCreator.java:154)
> at 
> com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:106)
> at com.google.inject.Guice.createInjector(Guice.java:95)
> at com.google.inject.Guice.createInjector(Guice.java:72)
> at com.google.inject.Guice.createInjector(Guice.java:62)
> at 
> org.apache.ambari.server.update.HostUpdateHelper.main(HostUpdateHelper.java:516)
> {code}
> 
> 
> Diffs
> -
> 
>   
> ambari-server/src/main/java/org/apache/ambari/server/update/HostUpdateHelper.java
>  0178f07 
> 
> Diff: https://reviews.apache.org/r/49596/diff/
> 
> 
> Testing
> ---
> 
> mvn clean test
> 
> 
> Thanks,
> 
> Vitalyi Brodetskyi
> 
>



Review Request 49596: ambari-server update-host-name failing

2016-07-04 Thread Vitalyi Brodetskyi

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

Review request for Ambari, Andrew Onischuk, Dmitro Lisnichenko, and Dmytro Sen.


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


Repository: ambari


Description
---

Steps to reproduce :

1) Run the following command on one of the hosts (which is not the ambari 
server) in the cluster : 
{code}
hostname renamedHost-0
{code}
2) On the ambari-server change the host name in the /etc/hosts for the host 
whose name was changed in step1
3) Create a file like the following to indicate the host changed :
{code}
{
"cl1" : {
"renamedHost-0.openstacklocal" : 
"rerenamedhost-0.openstacklocal"
}
}
{code}

4) Run ambari-server update-host-name 
The error shown :
{code}
03 Jul 2016 07:24:31,914  INFO [main] Configuration:1022 - Reading password 
from existing file
03 Jul 2016 07:24:31,931  INFO [main] Configuration:1491 - Hosts Mapping File 
null
03 Jul 2016 07:24:31,932  INFO [main] HostsMap:60 - Using hostsmap file null
03 Jul 2016 07:24:32,742  INFO [main] ControllerModule:199 - Detected ORACLE as 
the database type from the JDBC URL
03 Jul 2016 07:24:34,884  INFO [main] ControllerModule:607 - Binding and 
registering notification dispatcher class 
org.apache.ambari.server.notifications.dispatchers.SNMPDispatcher
03 Jul 2016 07:24:34,895  INFO [main] ControllerModule:607 - Binding and 
registering notification dispatcher class 
org.apache.ambari.server.notifications.dispatchers.EmailDispatcher
03 Jul 2016 07:24:34,905  INFO [main] ControllerModule:607 - Binding and 
registering notification dispatcher class 
org.apache.ambari.server.notifications.dispatchers.AlertScriptDispatcher
03 Jul 2016 07:24:38,223 ERROR [main] HostUpdateHelper:545 - Unexpected error, 
host names update failed
com.google.inject.CreationException: Guice creation errors:

1) No implementation for org.apache.ambari.server.audit.AuditLogger was bound.
  while locating org.apache.ambari.server.audit.AuditLogger
for field at 
org.apache.ambari.server.actionmanager.ActionDBAccessorImpl.auditLogger(ActionDBAccessorImpl.java:86)
  at 
org.apache.ambari.server.controller.ControllerModule.configure(ControllerModule.java:324)

2) No implementation for org.apache.ambari.server.audit.AuditLogger was bound.
  while locating org.apache.ambari.server.audit.AuditLogger
for field at 
org.apache.ambari.server.api.services.LogoutService.auditLogger(LogoutService.java:41)
  at 
org.apache.ambari.server.controller.ControllerModule.bindByAnnotation(ControllerModule.java:525)

2 errors
at 
com.google.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:435)
at 
com.google.inject.internal.InternalInjectorCreator.initializeStatically(InternalInjectorCreator.java:154)
at 
com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:106)
at com.google.inject.Guice.createInjector(Guice.java:95)
at com.google.inject.Guice.createInjector(Guice.java:72)
at com.google.inject.Guice.createInjector(Guice.java:62)
at 
org.apache.ambari.server.update.HostUpdateHelper.main(HostUpdateHelper.java:516)
{code}


Diffs
-

  
ambari-server/src/main/java/org/apache/ambari/server/update/HostUpdateHelper.java
 0178f07 

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


Testing
---

mvn clean test


Thanks,

Vitalyi Brodetskyi