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

Error during systemctl start thehive #94

Closed
mathgirl26 opened this issue Jan 18, 2017 · 9 comments
Closed

Error during systemctl start thehive #94

mathgirl26 opened this issue Jan 18, 2017 · 9 comments
Labels

Comments

@mathgirl26
Copy link

mathgirl26 commented Jan 18, 2017

Request Type

Bug / Feature Request

Work Environment

Question Answer
OS version (server) CentOS
https://github.com/CERT-BDF/TheHive/issues/new
TheHive version / git hash 2.x, hash of the commit
Package Type From source
Browser type & version If applicable

Problem Description

Hello, my log file of the service "thehive" hangs after the line :
"p.c.s.NettyServer - Listening for HTTP on /0:0:0:0:0:0:0:0:9000"
The output of the comand "curl -v http://127.0.0.1:9000" is:

About to connect() to 127.0.0.1 port 9000 (#0)
Trying 127.0.0.1...
Connected to 127.0.0.1 (127.0.0.1) port 9000 (#0)
GET / HTTP/1.1
User-Agent: curl/7.29.0
Host: 127.0.0.1:9000
Accept: /
HTTP/1.1 303 See Other
Location: /index.html
Content-Length: 0
Date: Wed, 18 Jan 2017 08:40:25 GMT
Connection #0 to host 127.0.0.1 left intact

And I have any error message in ElasticSearch!

Thank you for your help!

Complementary information

Log file:

>Jan 18 08:54:45 localhost systemd: Started TheHive.
Jan 18 08:54:45 localhost systemd: Starting TheHive...
Jan 18 08:54:54 localhost thehive: [info] o.r.Reflections - Reflections took 4177 ms to scan 122 urls, producing 7228 keys and 74304 values
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class org.elastic4play.services.DBListModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.CaseModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.ReportTemplateModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.ArtifactModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.JobModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.CaseTemplateModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class connectors.misp.MispModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.TaskModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.AuditModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.AnalyzerModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.UserModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class org.elastic4play.services.AttachmentModel
Jan 18 08:54:54 localhost thehive: [info] module - Loading model class models.LogModel
Jan 18 08:54:57 localhost thehive: [info] o.r.Reflections - Reflections took 3383 ms to scan 122 urls, producing 7228 keys and 74304 values
Jan 18 08:55:01 localhost thehive: [info] o.r.Reflections - Reflections took 3376 ms to scan 122 urls, producing 7228 keys and 74304 values
Jan 18 08:55:02 localhost thehive: [info] a.e.s.Slf4jLogger - Slf4jLogger started
Jan 18 08:55:02 localhost thehive: [info] o.e.plugins - [Nick Fury] modules [], plugins [], sites []
Jan 18 08:55:03 localhost thehive: [info] c.misp.MispSrv - Update of MISP events is starting ...
Jan 18 08:55:03 localhost thehive: [info] c.misp.MispSrv - 0 MISP event(s) updated
Jan 18 08:55:04 localhost thehive: [info] play.api.Play - Application started (Prod)
Jan 18 08:55:04 localhost thehive: [info] p.c.s.NettyServer - Listening for HTTP on /0:0:0:0:0:0:0:0:9000
@ghost
Copy link

ghost commented Jan 18, 2017

Hi !
There is no problem, type the access url in a browser, it will work

@mathgirl26
Copy link
Author

Thank you for your prompt reply!

Unfortunately, it doesn't work which is why i created this issue :(

Thank you for your help!

@ghost
Copy link

ghost commented Jan 18, 2017

Bizarre, I had the same "error" at the beginning, with the same message from the "curl ..." command but going to thehive's url, the logs continued

@mathgirl26
Copy link
Author

mathgirl26 commented Jan 18, 2017

Thank you for your help conmial!

I tried a "wget 127.0.0.1:9000" and I got this output:

--2017-01-18 11:12:31-- http://127.0.0.1:9000/
Connexion vers 127.0.0.1:9000...connecté.
requête HTTP transmise, en attente de la réponse...303 See Other
Emplacement: /index.html [suivant]
--2017-01-18 11:12:31-- http://127.0.0.1:9000/index.html
Réutilisation de la connexion existante vers 127.0.0.1:9000.
requête HTTP transmise, en attente de la réponse...404 Not Found
2017-01-18 11:12:31 ERREUR 404: Not Found.

So I think there is a problem with this index.html.

Someone does know how to fix that?

Thank you for your help!

@To-om
Copy link
Contributor

To-om commented Jan 18, 2017

Hi,
Have you followed the build guide ?
If index.html is not present, it means that front-end haven't been built correctly. Please check that all dependencies are met, in particular NodeJS, Bower and Grunt.
Regards

@fl0wc0ntr0l
Copy link

fl0wc0ntr0l commented Jan 18, 2017

I also have this issue when building from source in a fresh Ubuntu 16.04 install. I'm working off the 2.9.1 release and followed the build guide to the letter - but upon starting thehive as a service, I'm met with a blank webpage. curl and wget get the same results as mathgirl26.

The build guide mentions building the front-end out manually, which I have done, but there is no mention of where to put the resulting files - only a vague "ready for import into the http server" statement, which doesn't help much. It seems as though the automated build (bin/activator clean stage) does not correctly build out the front-end.

Edit: in addition, my URL automatically redirects to http://localhost:9000/index.html#!/main/ (not sure if that is intended or not).

@fl0wc0ntr0l
Copy link

After reading another issue I've found that my problem is related to #95 as I have that error in my browser console. After checking my version of Angular I do indeed have the 1.6.1 requirement. Utilizing the bower.json from the release/2.10.0 branch before executing bin/activatior clean stage solved my issue.

@mathgirl26
Copy link
Author

Me too, amateur-professional.
Anyway, I restarted the installation from the begining, but this time I followed the guide of "run from binaries" than " build&run from binaries" and it worked.

Thank you all of you for your help!

@nadouani
Copy link
Contributor

Thank you guys for finding the cause issue. I personnaly didn't spot that the it was related to the angular version.
We are working on speeding the 2.10.0 release or provide a hotfix with a 2.9.2 version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants