-
Notifications
You must be signed in to change notification settings - Fork 946
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
[platform] Initialization done after error #1445
Comments
Seems like this is related to #1363 |
Hello @nor3th, We've rebuilt 4.5.5 several times after the release to avoid this problem. can you check your Docker image checksum against the Docker hub latest 4.5.5? Kind regards, |
By the way, the error:
Is pretty clear :) |
So maybe just because your ElasticSearch has not been fully purged. |
In theory I totally agree with you, but I have no clue why this resource would already exist. I even used a new index creation pattern which I have never used before and the error still appeared.
How do you verify that elastic has fully purged the indices? I usually then check with
To be honest I am not able to produce an answer to this. I was able to pull an update for the 4.5.5 image, however I wasn't able to find a match between the checksum of https://hub.docker.com/layers/opencti/platform/4.5.5/images/sha256-2e327f5b57e1b34e883ebb3b00552d0c1fbfc0719268d8c1c4a1daa65aa9c919?context=explore and my output from
I just tried again with the newest 4.5.5 image and the error persists. I now even restarted and updated the elastic cluster, but still the same problem. |
Does it maybe have anything to do with the usage of the aliases? |
So I played around with my setup a bit and it seems more like an OpenCTI issue. In command #1 I checked that there are no more opencti indices present, in #2 I created a new opencti-history index, in #3 I tried the same thing again and elastic returned that the index already exists. In #4 I deleted the index and in #5 (a few seconds later) I created again an index with the same name. This behaviour at least indicates that elastic seems to purge indices quite fast.
Is OpenCTI trying to create the same index twice maybe? Another thing speaking for OpenCTI is that the index seems to be initiated during the initialization phase. Here I also used an index pattern I have never used before. As expected, the the "index already created" error is thrown right aftwards.
Another thing with the error log which I am a bit confused about is that OpenCTI says the initialization phase went well even though it didn't. Is that maybe due to the asynchronous way of how JavaScript operates? The
|
Alright I give up. I have no idea what the reason for this behavior is exactly. I tried:
I am starting OpenCTI using the docker compose files and with
And then starting the docker-compose setup worked without any issues. It still bugs me though, that the "Platform initialization done" message appears AFTER the ConfigurationError shows up. This MUST NOT happen. Is it possible due the the amount of different docker containers starting at the same time, the system has too much to do and a race condition fucks everything up? From what I understand is that OpenCTI is trying twice to create the same index, for what ever reason... |
Hello @nor3th, Can you please provide me with the Kind regards, |
Hello @SamuelHassine Here are the docker-compose.yml.txt (rename to docker-compose.yml) |
Hello @nor3th, Thanks for sharing your exact configuration (careful to the included password which is now burnt). I've just tried your configuration on my local machine (Ubuntu 20.04), here is what I've done:
Then put your 2 files in a directory and then: Everything is working fine, no indices problem, platform is starting: Kind regards, |
Thanks for the hint. I created the .env file with that script anyways, so it's not the one on my own machine :) What happens if you add even more connectors? I don't think that the config for the connectors even has to be valid as long as they start a docker container and consume memory. |
Im getting the same issue. I tried this and many other suggestions I found and nothing seems to work |
Description
After cleaning up an old opencti docker instance and creating a new one, there are issues with recreating the indices.
Environment
Reproducible Steps
Steps to create the smallest reproducible scenario:
docker-compose -up -d
(opencti docker container)docker-compose down -v
curl -XDELETE http://elastic.local:9200/opencti\*
(#delete all opencti incides)docker-compose up -d
(#start a new and clean opencti instance)Expected Output
I would expect either expect the initialization to succeed or fail entirely, but not the "Plattform initialization done" message after an error.
Actual Output
Additional information
I have no clue why elastic fails in the first place, since all opencti indices removed from the cluster. The elastic logs show no errors at all. I had this error previously and the only way to get rid of the "index already exists" error was to remove the elastic cluster and then start everything fresh again.
I also changed the index creation pattern (1,2,3), but no difference.
The text was updated successfully, but these errors were encountered: