Traditional Contact Method (osad)
OSAD is an alternative contact method between Uyuni and its clients.
By default, Uyuni uses rhnsd, which contacts the server every four hours to execute scheduled actions.
OSAD allows registered client systems to execute scheduled actions immediately.
OSAD has several distinct components:
-
The
osa-dispatcherservice runs on the server, and uses database checks to determine if clients need to be pinged, or if actions need to be executed. -
The
osadservice runs on the client. It responds to pings fromosa-dispatcherand runsmgr_checkto execute actions when directed to do so. -
The
jabberdservice is a daemon that uses theXMPPprotocol for communication between the client and the server. Thejabberdservice also handles authentication. -
The
mgr_checktool runs on the client to execute actions. It is triggered by communication from theosa-dispatcherservice.
The osa-dispatcher periodically runs a query to check when clients last showed network activity.
If it finds a client that has not shown activity recently, it will use jabberd to ping all osad instances running on all clients registered with your Uyuni server.
The osad instances respond to the ping using jabberd, which is running in the background on the server.
When the osa-dispatcher receives the response, it marks the client as online.
If the osa-dispatcher fails to receive a response within a certain period of time, it marks the client as offline.
When you schedule actions on an OSAD-enabled system, the task will be carried out immediately.
The osa-dispatcher periodically checks clients for actions that need to be executed.
If an outstanding action is found, it uses jabberd to execute mgr_check on the client, which will then execute the action.
Enabling and Configuring OSAD
This section covers enabling the osa-dispatcher and osad services, and performing initial setup.
OSAD clients use the fully qualified domain name (FQDN) of the server to communicate with the osa-dispatcher service.
SSL is required for osad communication.
If SSL certificates are not available, the daemon on your client systems will fail to connect.
Make sure your firewall rules are set to allow the required ports.
For more information, see xref:tab.install.ports.server[Server Ports].
-
On your Uyuni server, as the root user, start the
osa-dispatcherservice:systemctl start osa-dispatcher
-
On each client machine, install the
mgr-osadpackage from theToolschild channel. Themgr-osadpackage should be installed on clients only. If you install themgr-osadpackage on your Uyuni Server, it will conflict with theosa-dispatcherpackage. -
On the client systems, as the root user, start the
osadservice:systemctl start osad
Because
osadandosa-dispatcherare run as services, you can use standard commands to manage them, includingstop,restart, andstatus.
Each OSAD component is configured by local configuration files. We recommend you keep the default configuration parameters for all OSAD components.
| Component | Location | Path to Configuration File |
|---|---|---|
|
Server |
|
|
Client |
|
|
Client |
|
|
Both |
|
If your OSAD clients cannot connect to the server, or if the jabberd service takes a lot of time responding to port 5552, it could be because you have exceeded the open file count.
Every client needs one always-open TCP connection to the server, which consumes a single file handler.
If the number of file handlers currently open exceeds the maximum number of files that jabberd is allowed to use, jabberd will queue the requests, and refuse connections.
To resolve this issue, you can increase the file limits for jabberd by editing the /etc/security/limits.conf configuration file and adding these lines:
jabbersoftnofile5100 jabberhardnofile6000
Calculate the limits required for your environment by adding 100 to the number of clients for the soft limit, and 1000 to the current number of clients for the soft limit. In the example above, we have assumed 500 current clients, so the soft limit is 5100, and the hard limit is 6000.
You will also need to update the max_fds parameter in the /etc/jabberd/c2s.xml file with your chosen hard limit:
<max_fds>6000</max_fds>