Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Issue with Migration 3.5.1 -> 4.1.6 #2089

Closed
fonk0rn opened this issue Jun 18, 2021 · 0 comments
Closed

[Bug] Issue with Migration 3.5.1 -> 4.1.6 #2089

fonk0rn opened this issue Jun 18, 2021 · 0 comments
Assignees
Labels
Milestone

Comments

@fonk0rn
Copy link

fonk0rn commented Jun 18, 2021

Request Type

Bug Migration 3.5.1 -> 4.1.6

Work Environment

Question Answer
OS version (server) Ubuntu, 20.40
Virtualized Env. True
Dedicated RAM 24 GB
vCPU 8
TheHive version / git hash 4.1.6
Package Type DEB
Database Cassandra
Index type Elasticsearch
Attachments storage Local
Browser type & version If applicable

Problem Description

When try to migrate from 3.5.1 to last (4.1.6) got errors:

root@hive-tmp2:/etc/thehive# /opt/thehive/bin/migrate -no-version-check --output /etc/thehive/application.conf --main-organisation Playtech --es-uri http://elastic:92000 --es-index the_hive_17
09:44:20.451 [TheHiveMigration-akka.actor.default-dispatcher-4] INFO akka.event.slf4j.Slf4jLogger - Slf4jLogger started
09:44:20.465 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.event.EventStream - logger log1-Slf4jLogger started
09:44:20.467 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.event.EventStream - Default Loggers started
09:44:20.518 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.remote.artery.tcp.ArteryTcpTransport - Using flight recorder NoOpRemotingFlightRecorder
09:44:20.762 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.io.TcpListener - Successfully bound to /127.0.0.1:44349
09:44:20.878 [TheHiveMigration-akka.actor.default-dispatcher-4] INFO akka.remote.artery.tcp.ArteryTcpTransport - Remoting started with transport [Artery tcp]; listening on address [akka://[email protected]:44349] with UID [4678353142700616078]
09:44:20.903 [TheHiveMigration-akka.actor.default-dispatcher-4] INFO akka.cluster.Cluster - Cluster Node [akka://[email protected]:44349] - Starting up, Akka version [2.6.10] ...
09:44:21.041 [TheHiveMigration-akka.actor.default-dispatcher-4] INFO akka.cluster.Cluster - Cluster Node [akka://[email protected]:44349] - Registered cluster JMX MBean [akka:type=Cluster]
09:44:21.041 [TheHiveMigration-akka.actor.default-dispatcher-4] INFO akka.cluster.Cluster - Cluster Node [akka://[email protected]:44349] - Started up successfully
09:44:21.088 [TheHiveMigration-akka.actor.default-dispatcher-13] INFO akka.cluster.Cluster - Cluster Node [akka://[email protected]:44349] - No seed-nodes configured, manual cluster join required, see https://doc.akka.io/docs/akka/current/typed/cluster.html#joining
09:44:21.094 [TheHiveMigration-akka.actor.default-dispatcher-13] INFO akka.cluster.sbr.SplitBrainResolver - SBR started. Config: strategy [KeepMajority], stable-after [20 seconds], down-all-when-unstable [15 seconds], selfUniqueAddress [akka://[email protected]:44349#4678353142700616078], selfDc [default].
09:44:21.818 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaJacksonModule]
09:44:21.818 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaTypedJacksonModule]
09:44:21.818 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaStreamJacksonModule]
09:44:21.820 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.module.paramnames.ParameterNamesModule]
09:44:21.824 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.datatype.jdk8.Jdk8Module]
09:44:21.825 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.datatype.jsr310.JavaTimeModule]
09:44:21.926 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.module.scala.DefaultScalaModule]
09:44:21.966 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaJacksonModule]
09:44:21.966 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaTypedJacksonModule]
09:44:21.966 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaStreamJacksonModule]
09:44:21.966 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.module.paramnames.ParameterNamesModule]
09:44:21.966 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.datatype.jdk8.Jdk8Module]
09:44:21.966 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.datatype.jsr310.JavaTimeModule]
09:44:21.971 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.module.scala.DefaultScalaModule]
09:44:21.973 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.Serialization(akka://TheHiveMigration) - Replacing JavaSerializer with DisabledJavaSerializer, due to `akka.actor.allow-java-serialization = off`.
09:44:22.045 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaJacksonModule]
09:44:22.045 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaTypedJacksonModule]
09:44:22.045 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [akka.serialization.jackson.AkkaStreamJacksonModule]
09:44:22.046 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.module.paramnames.ParameterNamesModule]
09:44:22.046 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.datatype.jdk8.Jdk8Module]
09:44:22.046 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.datatype.jsr310.JavaTimeModule]
09:44:22.050 [TheHiveMigration-akka.actor.default-dispatcher-4] DEBUG akka.serialization.jackson.JacksonObjectMapperProvider$ - Registered Jackson module [com.fasterxml.jackson.module.scala.DefaultScalaModule]
[info] Initialising cluster
[info] Member is Up: akka://[email protected]:44349
[error] Migration failed
com.google.inject.ConfigurationException: Guice configuration errors:

1) No implementation for akka.actor.typed.ActorRef<org.thp.thehive.services.CaseNumberActor$Request> annotated with @com.google.inject.name.Named(value=case-number-actor) was bound.
  while locating akka.actor.typed.ActorRef<org.thp.thehive.services.CaseNumberActor$Request> annotated with @com.google.inject.name.Named(value=case-number-actor)
    for the 15th parameter of org.thp.thehive.services.CaseSrv.<init>(CaseSrv.scala:42)
  while locating org.thp.thehive.services.CaseSrv
    for the 4th parameter of org.thp.thehive.migration.th4.Output.<init>(Output.scala:90)
  while locating org.thp.thehive.migration.th4.Output

2) No implementation for akka.actor.typed.ActorRef<org.thp.thehive.services.CaseNumberActor$Request> annotated with @com.google.inject.name.Named(value=case-number-actor) was bound.
  while locating akka.actor.typed.ActorRef<org.thp.thehive.services.CaseNumberActor$Request> annotated with @com.google.inject.name.Named(value=case-number-actor)
    for the 15th parameter of org.thp.thehive.services.CaseSrv.<init>(CaseSrv.scala:42)
  while locating org.thp.thehive.services.CaseSrv
    for the 1st parameter of org.thp.thehive.connector.cortex.services.ActionOperationSrv.<init>(ActionOperationSrv.scala:20)
  while locating org.thp.thehive.connector.cortex.services.ActionOperationSrv
    for the 2nd parameter of org.thp.thehive.connector.cortex.services.ActionSrv.<init>(ActionSrv.scala:34)
  while locating org.thp.thehive.connector.cortex.services.ActionSrv
    for the 23rd parameter of org.thp.thehive.migration.th4.Output.<init>(Output.scala:90)
  while locating org.thp.thehive.migration.th4.Output

3) No implementation for akka.actor.typed.ActorRef<org.thp.thehive.services.CaseNumberActor$Request> annotated with @com.google.inject.name.Named(value=case-number-actor) was bound.
  while locating akka.actor.typed.ActorRef<org.thp.thehive.services.CaseNumberActor$Request> annotated with @com.google.inject.name.Named(value=case-number-actor)
    for the 15th parameter of org.thp.thehive.services.CaseSrv.<init>(CaseSrv.scala:42)
  while locating com.google.inject.Provider<org.thp.thehive.services.CaseSrv>
    for the 1st parameter of org.thp.thehive.services.TaskSrv.<init>(TaskSrv.scala:28)
  while locating org.thp.thehive.services.TaskSrv
    for the 1st parameter of org.thp.thehive.connector.cortex.services.EntityHelper.<init>(EntityHelper.scala:22)
  while locating org.thp.thehive.connector.cortex.services.EntityHelper
    for the 3rd parameter of org.thp.thehive.connector.cortex.services.ActionSrv.<init>(ActionSrv.scala:34)
  while locating org.thp.thehive.connector.cortex.services.ActionSrv
    for the 23rd parameter of org.thp.thehive.migration.th4.Output.<init>(Output.scala:90)
  while locating org.thp.thehive.migration.th4.Output

3 errors
        at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:1120)
        at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:1078)
        at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1131)
        at org.thp.thehive.migration.th4.Output$.apply(Output.scala:83)
        at org.thp.thehive.migration.Migrate$.$anonfun$new$1(Migrate.scala:198)
        at org.thp.thehive.migration.Migrate$.$anonfun$new$1$adapted(Migrate.scala:182)
        at scala.Option.foreach(Option.scala:407)
        at org.thp.thehive.migration.Migrate$.delayedEndpoint$org$thp$thehive$migration$Migrate$1(Migrate.scala:182)
        at org.thp.thehive.migration.Migrate$delayedInit$body.apply(Migrate.scala:16)
        at scala.Function0.apply$mcV$sp(Function0.scala:39)
[info] Member is Removed: akka://[email protected]:44349 after Exiting
[info] Stage: initialisation
@fonk0rn fonk0rn added bug TheHive4 TheHive4 related issues labels Jun 18, 2021
@To-om To-om added this to the 4.1.7 milestone Jun 30, 2021
vdebergue added a commit to vdebergue/TheHive that referenced this issue Jun 30, 2021
@nadouani nadouani changed the title [Bug] [Bug] Issue with Migration 3.5.1 -> 4.1.6 Jul 1, 2021
@nadouani nadouani linked a pull request Jul 1, 2021 that will close this issue
To-om added a commit that referenced this issue Jul 1, 2021
@To-om To-om closed this as completed Jul 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants