Skip to content

Commit 963bfd8

Browse files
committed
Change MQTT tuning procedure to a "custom-hiera"-based one
That way the configuration file won't be deleted when `foreman-installer` is run again and won't be needed to reload or restart services manually.
1 parent 8343cf4 commit 963bfd8

File tree

1 file changed

+17
-20
lines changed

1 file changed

+17
-20
lines changed

guides/common/modules/proc_increasing-host-limit-for-pull-based-rex-transport.adoc

Lines changed: 17 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -3,32 +3,29 @@
33
[id="Increasing_host_limit_for_pull_based_REX_transport_{context}"]
44
= Increasing host limit for pull-based REX transport
55

6-
You can tune the `mosquitto` MQTT server and increase the number of hosts connected to it.
6+
You can tune the `mosquitto` MQTT server and increase the maximum number of hosts connected to it.
7+
By default, {SmartProxies} support a maximum of 1014 connected hosts.
78

8-
.Procedure
9-
. Enable pull-based remote execution on your {ProjectServer} or {SmartProxyServer}:
10-
+
11-
[options="nowrap", subs="+quotes,verbatim,attributes"]
12-
----
13-
# {foreman-installer} --foreman-proxy-plugin-remote-execution-script-mode pull-mqtt
14-
----
9+
This example configures the `mosquitto` service on a {ProjectServer} or {SmartProxyServer} to handle up to 5000 hosts.
10+
11+
.Prerequisites
12+
* You have enabled pull-based remove execution on your {SmartProxy}.
1513
+
16-
Note that your {ProjectServer} or {SmartProxyServer} can only use one transport mode, either SSH or MQTT.
17-
. Create a config file to increase the default number of hosts accepted by the MQTT service:
14+
For more information, see {InstallingSmartProxyDocURL}configuring-pull-based-transport-for-remote-execution_{smart-proxy-context}[Configuring pull-based transport for remote execution] in _{InstallingSmartProxyDocTitle}_.
15+
16+
.Procedure
17+
. On your {SmartProxy}, set the upper limit of connected hosts for pull-based remote execution in `/etc/foreman-installer/custom-hiera.yaml`:
1818
+
1919
[options="nowrap", subs="+quotes,verbatim,attributes"]
2020
----
21-
cat >/etc/systemd/system/mosquitto.service.d/limits.conf <<__EOF__
22-
[Service]
23-
LimitNOFILE=5000
24-
__EOF__
21+
systemd::dropin_files:
22+
limits.conf:
23+
unit: mosquitto.service
24+
content: "[Service]\nLimitNOFILE=5000\n"
2525
----
26-
+
27-
This example sets the limit to allow the `mosquitto` service to handle 5000 hosts.
28-
. Apply your changes:
26+
. Re-run the installer for the changes to take effect:
2927
+
3028
[options="nowrap", subs="+quotes,verbatim,attributes"]
3129
----
32-
# systemctl daemon-reload
33-
# systemctl restart mosquitto.service
34-
----
30+
# {foreman-installer}
31+
----

0 commit comments

Comments
 (0)