hi, im using fleet 3.5.1 and i have 3 fleet server...
# fleet
j
hi, im using fleet 3.5.1 and i have 3 fleet servers, and for some reason my load balancer gives the queries only to the two first servers, and i looked at yaml file of the fleet service that doesn't get queries and he is the same like the other fleet service that getting queries. and when I use fleetctl the third fleet works. do you have any solution?
l
Hi @jimmy! Fleet is unaware of how it get requests or if there are other Fleet instances running as part of the deployment. So, this is most likely a configuration/network issue between the load balancer and the hosts running your Fleet instances. Here's a guide on how to deploy Fleet: https://fleetdm.com/docs/deploying/server-installation#deploying-the-load-balancer (with a section on deploying a load balancer)
If possible, we advise users to upgrade to Fleet's latest version,
4.14.0
(there have been several performance improvements since
3.5.1
).
and when I use fleetctl the third fleet works. do you have any solution?
1.
fleetctl
--> 3rd Fleet Server 2.
fleetctl
--> load balancer --> 3rd Fleet Server If you are doing (1) then I'd suggest you try with (2) to test that the request is really going through the load balancer.
j
hi @Lucas Rodriguez the section of the load balancer is only with kubectl, and my server doesn't have kubernetes. and its
fleetctl
--> 3rd Fleet Server
@Lucas Rodriguez "If you are doing (1) then I'd suggest you try with (2) to test that the request is really going through the load balancer." how can i check this
@Lucas Rodriguez and thanks for the help 🙂
l
how can i check this
So if I understood correctly, your devices will connect to Fleet through the load balancer (via some defined URL). Have
fleetctl
use the same URL as the osquery hosts. To be sure that you are connecting to Fleet the same way as your devices.
j
@Lucas Rodriguez I don't think that the fleetctl go threw the load balancer
@Lucas Rodriguez but how can i check this to be sure?
l
fleetctl config get address
will return the URL it's using to connect to Fleet. Such URL should match the one your devices use to connect to Fleet. E.g. in my development setup:
Copy code
$ fleetctl config get address
  default.address => <https://localhost:8080>
but how can i check this to be sure?
A way to check this would be to run the third Fleet server in debug mode (
FLEET_LOGGING_DEBUG
var or
--logging_debug
cli argument) and see if it's getting any requests (Fleet logs one line per request when
--logging_debug
is set)
Oh same question was asked here 🙂: https://osquery.slack.com/archives/C01DXJL16D8/p1652726641378669
j
@Lucas Rodriguez thanks for the help, "fleetctl config get address" i did this command and my server gave me wrong ip of the load balancer.
@Lucas Rodriguez so what should i do now?
l
You can configure
fleetctl
address with:
fleetctl config set --address https://$LOAD_BALANCER_IP:$LOAD_BALANCER_PORT
j
i did this but sadly it still doesn't get queries from the load balancer
should i maybe restart the load balancer after that?
l
i did this but sadly it still doesn't get queries from the load balancer
What do you mean by this?
fleetctl config set --address https://$LOAD_BALANCER_IP:$LOAD_BALANCER_PORT
This command is only configuring
fleetctl
to connect to Fleet via the load balancer.
j
"hi, im using fleet 3.5.1 and i have 3 fleet servers, and for some reason my load balancer gives the queries only to the two first servers, and i looked at yaml file of the fleet service that doesn't get queries and he is the same like the other fleet service that getting queries. and when I use fleetctl the third fleet works. do you have any solution?" I mean that I still have that problem
l
OK, we are just trying to connect via
fleetctl
via the load balancer to be able to troubleshoot.
https://osquery.slack.com/archives/C01DXJL16D8/p1652729790761829?thread_ts=1652726641.378669&amp;cid=C01DXJL16D8 this should also help troubleshooting. Basically have your load balancer use Fleet's healthz endpoint.