How to install GrayLog Docker image

Louis2

Contributor
Joined
Sep 7, 2019
Messages
177
I would like to run GrayLog on my scale system, which should not be a big deal since GrayLog does provide Docker images. However I have zero experiences with Docker and did not manage. I am using the very latest scale release.

- I did pull the container 'graylog/graylog' that worked
- I created a data set to store the Docker data
- I went to 'Lauch Docker Image' where I used 'Only pull image if not present on host'
- I did try with and without adding password_secret = xyz under 'Container Args'
- under host interface I choose the intended vlan
- ipam type I choose dhcp for the moment to keep it simple (it should be a static address, but lets try this first)
- under storage I refer to the earlier created data-set
- as mount path I did defined /mnt/GrayLog
- web portal name 'My GrayLog Server'

So started the container
= > deploying (however it never reaches the state 'running'
=> opening the shell shows 'error: unable to upgrade connection: container not found ("ix-chart")'

So it does not work, so I am doing the wrong things :grin:

I hope some one has GrayLog running and/or can tell how to fix the problem!
 

jaharmi

Cadet
Joined
Apr 25, 2019
Messages
5
It's been a while since your message, but I'm trying to do the same thing. I found that if I set the following environment variables from the Graylog documentation (mentioned in their Docker documentation), I got a bit farther along.
  • GRAYLOG_PASSWORD_SECRET
  • GRAYLOG_ROOT_PASSWORD_SHA2
  • GRAYLOG_HTTP_BIND_ADDRESS

I had also tried to set the Java options, as per the Docker Compose mentioned in this thread (which you might also have been involved with). That did not work for me so I removed them.

I'm farther along, yes, but I still get this error in the logs for the Docker container in TrueNAS:

Code:
2023-07-04 23:28:52.416201+00:002023-07-04 23:28:52,415 INFO : org.mongodb.driver.cluster - Cluster description not yet available. Waiting for 30000 ms before timing out
2023-07-04 23:28:52.424390+00:002023-07-04 23:28:52,409 INFO : org.mongodb.driver.cluster - Exception in monitor thread while connecting to server mongo:27017
2023-07-04 23:28:52.424439+00:00com.mongodb.MongoSocketException: mongo
2023-07-04 23:28:52.424461+00:00at com.mongodb.ServerAddress.getSocketAddresses(ServerAddress.java:217) ~[graylog.jar:?]
2023-07-04 23:28:52.424492+00:00at com.mongodb.internal.connection.SocketStream.initializeSocket(SocketStream.java:78) ~[graylog.jar:?]
2023-07-04 23:28:52.424505+00:00at com.mongodb.internal.connection.SocketStream.open(SocketStream.java:68) ~[graylog.jar:?]
2023-07-04 23:28:52.424517+00:00at com.mongodb.internal.connection.InternalStreamConnection.open(InternalStreamConnection.java:183) ~[graylog.jar:?]
2023-07-04 23:28:52.424537+00:00at com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.lookupServerDescription(DefaultServerMonitor.java:198) [graylog.jar:?]
2023-07-04 23:28:52.424550+00:00at com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.run(DefaultServerMonitor.java:158) [graylog.jar:?]
2023-07-04 23:28:52.424572+00:00at java.lang.Thread.run(Unknown Source) [?:?]
2023-07-04 23:28:52.424585+00:00Caused by: java.net.UnknownHostException: mongo
2023-07-04 23:28:52.424596+00:00at java.net.InetAddress$CachedAddresses.get(Unknown Source) ~[?:?]
2023-07-04 23:28:52.424608+00:00at java.net.InetAddress$NameServiceAddresses.get(Unknown Source) ~[?:?]
2023-07-04 23:28:52.424628+00:00at java.net.InetAddress.getAllByName0(Unknown Source) ~[?:?]
2023-07-04 23:28:52.424641+00:00at java.net.InetAddress.getAllByName(Unknown Source) ~[?:?]
2023-07-04 23:28:52.424652+00:00at java.net.InetAddress.getAllByName(Unknown Source) ~[?:?]
2023-07-04 23:28:52.424664+00:00at com.mongodb.ServerAddress.getSocketAddresses(ServerAddress.java:209) ~[graylog.jar:?]
2023-07-04 23:28:52.424682+00:00... 6 more
2023-07-04 23:29:22.417617+00:002023-07-04 23:29:22,417 INFO : org.graylog2.bootstrap.preflight.MongoDBPreflightCheck - MongoDB is not available. Retry #1
2023-07-04 23:29:24.418848+00:002023-07-04 23:29:24,418 INFO : org.mongodb.driver.cluster - Cluster description not yet available. Waiting for 30000 ms before timing out
 

jaharmi

Cadet
Joined
Apr 25, 2019
Messages
5
I also had to specify “5.1” instead of “latest” for the Graylog Docker image tag.
 

thnessum

Cadet
Joined
Aug 31, 2023
Messages
1
Seems to be a slight older post but did do you have mongoDB running? And you also need either Elasticsearch or Opensearch.
Did you follow the install guide for Graylog?
 

bigjohns97

Dabbler
Joined
Aug 30, 2023
Messages
10
I've been trying to get this to work as well, this is the only reason I still have to run a VM.
 
Top