Skip to content

StreamSrv: Unexpected message : StreamNotFound #414

Closed
@ParanoidRat

Description

@ParanoidRat

Request Type

Bug?

Work Environment

Question Answer
OS version (server) CentOS
OS version (client) Ubuntu
TheHive version / git hash 3.0.3
Package Type Docker
Browser type & version Chromium 63

Problem Description

I see multiple warning notifications in UI (stack of red rectangles in the lower left corner) saying
StreamSrv: Unexpected message : StreamNotFound (class services.StreamActor$StreamNotFound$)
and fading away.

EDIT 1: When Elasticsearch index is deleted and TheHive service is reinitialized in docker (removed, recreated) it seems to create the_hive_X without giving any options to provide admin password.

EDIT 2: When TheHive service is reduced down to one replica (one app instance running in the docker swarm) everything seems to work as expected without any change in configuration (just deletion of ES index)

EDIT 3: When left to its own devices, at some point even one instance of TheHive starts to produce receive dead message in the log and show the 504 Gateway Time-out error from Nginx (has nginx/1.13.8 in the body) in the UI (red notification popups).

Full log could be viewed here

Steps to Reproduce

  1. Deploy Docker Swarm 17.12.0-ce cluster with 2 worker and 3 master nodes
  2. Deploy Nginx 1.13.8 reverse proxy service on both workers to act as a load-balancer and TLS termination (Let's Encrypt certs)
  3. Deploy TheHive as a service replicated to both worker nodes and load-balanced by Nginx
  4. Login to TheHive (data index pre-existed from previous deployment)
  5. Navigate to a case or other UI element or just wait

Complementary information

TheHive config

play.crypto.secret="************"

search {
  index = the_hive
  cluster = ****
  host = ["****0:9300", "****1:9300", "****2:9300", "****3:9300"]
  keepalive = 1m
  pagesize = 50
}

auth {
	type = [local]

	ad {
	}

	ldap {
	}
}

cortex {
}

misp {
  interval = 1h
}

Nginx config

server {
  listen 443;
  server_name *****.org;

  resolver 127.0.0.11 valid=30s;

  ssl on;
  ssl_certificate /etc/letsencrypt/live/*****/fullchain.pem;
  ssl_certificate_key /etc/letsencrypt/live/*****/privkey.pem;

  ssl_stapling on;
  ssl_stapling_verify on;
  ssl_trusted_certificate /etc/letsencrypt/live/*****/chain.pem;

  ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
  ssl_ciphers HIGH:!aNULL:!MD5;

  location / {
    set $docker_service thehive_internal;
    set $docker_port 9000;

    proxy_pass http://$docker_service:$docker_port;

    proxy_http_version 1.1;
    proxy_set_header Connection "Keep-Alive";
    proxy_set_header Proxy-Connection "Keep-Alive";
  }
}

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions