SNAS / docker

Docker files for docker installs
Eclipse Public License 1.0
20 stars 28 forks source link

Database empty #26

Open broonu opened 4 years ago

broonu commented 4 years ago

Hello,

I followed instructions for a docker deploy, but when I run the openbmp_psql conteiner I got some errors in log. I can see in kafka consumer that there is some topics from collector, but the databse itself is completely empty.

root@snas:~# docker logs openbmp_psql
===> Updating /etc/hosts
===> Performing Kafka check
===> Checking Kafka bootstrap server connection
Metadata for all topics (from broker -1: kafka.domain:9092/bootstrap):
 1 brokers:
  broker 0 at 172.17.0.3:9092
===> Checking if we can successfully consume messages
===> Configuring PostgreSQL
===> Enabling RPKI
===> Downloading and Installing ARIN TAL
[ warn ] JAVA_HOME is not set, will try to find java on path.
[ info ] Starting rpki-validator...
[ info ] writing logs under log directory
[ info ] Web user interface is available on port 8080
[ info ] Routers can connect on port 8282
[ info ] Writing PID 96 to validator.pid
===> Enabling IRR
Loading IRR data
Starting enhanced syslogd: rsyslogd.
Starting periodic command scheduler: cron.
Starting PostgreSQL 10 database server: main.
    Waiting for PostgreSQL to start...
===> Postgres ready
===> Starting consumer
===> Now running!!!
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
  File "/usr/local/openbmp/gen_whois_route.py", line 345, in <module>
    main()
  File "/usr/local/openbmp/gen_whois_route.py", line 331, in main
    download_data_file()
  File "/usr/local/openbmp/gen_whois_route.py", line 226, in download_data_file
    traceback.print_stack()
netyook commented 4 years ago

I have a same issue.

How could you solve that..?

huangkun41 commented 4 years ago

I have a same issue.

How could you solve that..?

netyook commented 4 years ago

I solve that problem.

  1. You shoud restart that docker again.
  2. and you have to set same ip address as a hostname for postgres and other docker. Then you will fix it
kbmanseau commented 3 years ago

Thanks @netyook, just wanted to clarify the behavior and solution I had in case others stumble across this.

I am working on migrating from the snas kafka image to the bitnami kafka image.

The FQDN specified in BOTH the collector AND the psql db need to match, even if they both resolve properly to the kafka broker. Couldn't figure out why even though both could individually connect to the broker, it wasn't until I matched it on both ends that data started showing up in the DB.