The maxscale service will be restarted only if the process is down because
a signal was caught or the process times out. If the process would be restarted
when it exits with a non-zero value, this would lead to infinite loops when
there is a configuration error.
On systems where the systemd directories exist but not the systemctl command,
installation of MaxScale would cause systemctl to be called. This would print
an error when the package is being installed.
Pre-1.2.0 configuration scripts are no longer copied and renamed.
Init scripts, ldconfig files and systemd service files are only removed if
they are found.
The postinstall script tried to create a group for the maxscale even if the
useradd command had created one. This fix removes the warning messages by
creating the group while the user is being created.
If the systemd folder wasn't located at /usr/lib/systemd/ but at /lib/systemd/
the postinstall script would not copy the file.
Also added error messages if some of the files could not be located.
The fact that the maxscale process exits only after all services have been
started means that systemd will kill the maxscale process if starting the
services takes too long. Since the user authentication data is loaded on
startup and can take up a long time, there needs to be a longer than
default timeout for systems that use systemd.
Template config file is copied as maxscale.cnf if no configuration file is found.
If /etc/maxscale.cnf is not found, the /etc/maxscale.cnf.template will be copied as /etc/maxscale.cnf.
This allows MaxScale to start right after installation if combined with a running and properly configured server.
Log, lib, cache and run directories are created on start if they do not exist.
The ownership of the directories is changed to maxscale and the permissions are set to 0755.
Binlogrouter: Switched hard-coded maximum path values to PATH_MAX and used cache directory instead of MAXSCALE_HOME
Scripts: Updated with new executable file paths