https://questdb.io logo
Title
p

Prashanthb

03/11/2023, 4:48 PM
Hi there, Is it possible to launch multiple instances of Questdb on a single baremetal machine ? I created two root directories (qdb1 & qdb2) and did :
./questdb.sh start -d /mnt/zpool/qdb1 -t tag1
and then
./questdb.sh start -d /mnt/zpool/qdb2 -t tag2
The first instance starts fine, but the second instance complains of
could not bind socket
, i.e a clash of port numbers. I edited the port numbers in server.conf file of second questdb instance but to no avail. It stops/hangs with errors at
could not bind socket ....
pg-server,bindTo=0.0.0.0:8812
The documentation says => "Each new service should have its own config file or should be started with separate port and root directory options." How to pass separate port numbers at launch ? Please give any link to read further. Thanks. EDIT : I am on Debian Bullseye & Questdb 7.0.1
s

Steven Sklar

03/11/2023, 5:09 PM
Hi! We bind to 3 ports, so maybe you missed one in your config? Based on the error, it looks like you may have missed the
<http://pg.net.bind.to|pg.net.bind.to>
setting, which defaults to
<http://pg.net.bind.to|pg.net.bind.to>=0.0.0.0:8812
. There’s also
<http://line.tcp.net.bind.to|line.tcp.net.bind.to>
and
<http://http.bind.to|http.bind.to>
that need to be changed.
All possible settings can be found here: https://questdb.io/docs/reference/configuration/
p

Prashanthb

03/11/2023, 5:38 PM
Hey Steve, thanks a lot for the pointer. I edited the following details in server.conf and now both instances are up and running. I can see them on htop.
http.enabled=true
<http://http.net.bind.to|http.net.bind.to>=0.0.0.0:9001
http.min.enabled=true
<http://http.min.net.bind.to|http.min.net.bind.to>=0.0.0.0:9004
<http://line.udp.bind.to|line.udp.bind.to>=0.0.0.0:9011
line.tcp.enabled=true
<http://line.tcp.net.bind.to|line.tcp.net.bind.to>=0.0.0.0:9010
pg.enabled=true
<http://pg.net.bind.to|pg.net.bind.to>=0.0.0.0:8813
Thanks again 👏