Tune Workers via CLI


#1

I am trying to do some tuning on workers processes across a large environment, is it possible to manage this via the CLI with Ansible or similar?

Thanks,
Ron


#2

What type of tuning are you describing? If it’s configuring memory thresholds, restart intervals, etc. for servers, you can take a look at tools/configure_server_settings.rb. See here.

I haven’t run it in a while, but you can configure each server by miq_servers table id for any server setting.

I had this in my history, I don’t know if this is completely correct but gives you an idea of what you can do:

vmdb # cd to vmdb directory;
./tools/configure_server_settings.rb -s 1000000000001 -p workers/worker_base/queue_worker_base/generic_worker/memory_threshold -v 1.gigabyte

#3

This is exactly what I was looking for. I pulled this down from upstream into the CloudForms vmdb approot and got it working. Thanks!


#4

So I ran into a bit of trouble using configure_server_settings.rb today.

Running the following converted an integer into a string and stopped all metrics collections from occurring.

./tools/configure_server_settings.rb -s 1 -p workers/worker_base/queue_worker_base/ems_metrics_collector_worker/defaults/count -v 4

#5

@deadnull thanks for reporting that. This should fix it.


#6

Thanks for the fix, we’re on similar pages, had opened this: https://github.com/ManageIQ/manageiq/pull/17039

Either way its a solid fix.

Thanks!

-Ron


#7

To others who may see this thread, we went with the pull request mentioned above. It’s been merged on the master branch so please try it out and report any problems. Thanks!