Sometimes we see that mirrorlist-server processes are not running and it
just needs to be restarted. Let the script try it twice before erroring
out.
The most common reason for non running mirrorlist-server processes seems
to be incomplete or truncated input files which is usually fixed the
next time the data is synced.
Signed-off-by: Adrian Reber <adrian@lisas.de>
Remove everything which is related to running the mirrorlist server
process as a container. This has not been used for the last few months.
Also remove the 3 mirrorlist process setup for IAD2 as it is no longer
necessary and removing it also simplifies the configuration.
Signed-off-by: Adrian Reber <adrian@lisas.de>
The new mirrorlist-server is a single binary and can easily be run as a
service without a container. There have been problems running the
mirrorlist container rootless, especially the combination of running it
as a systemd server and rootless often failed during container
stop/removal.
With this change, starting with Fedora 31, the mirrorlist-server package
is installed and started via systemd to answer haproxy requests. Without
any container.
Signed-off-by: Adrian Reber <adrian@lisas.de>
If stopping of the mirrorlist container fails, systemd usually kills all
processes in the same control group which means that the usual Podman
cleanup steps will not be able to run. Setting KillMode=none gives
Podman a chance to correctly remove the container.
Signed-off-by: Adrian Reber <adrian@lisas.de>
Starting the mirrorlist container after a stop sometimes fails with:
Error: error creating container storage: the container name "mirrorlist1.service" is already in use
One way to work around this is to run:
sudo -u mirrormanager /usr/bin/podman rm mirrorlist1.service --storage --force
The restart mirrorlist container script now tries to remove the
container with '--storage --force' if the start fails and retries the
start.
Signed-off-by: Adrian Reber <adrian@lisas.de>
In a previous commit I changed the non-templated version of
restart-mirrorlist-containers to look at the new protobuf based
mirrorlist cache file instead at the pkl file. It seems that nothing
uses the non-templated version of the script. This removes the unused
script and adapts the templated restart mirrorlist container script to
look at the protbuf based mirrorlist cache file.
Signed-off-by: Adrian Reber <adrian@lisas.de>
The new mirrorlist containers are no longer using the pkl file. The
script still based all its restart and copy decisions on the pkl file.
This changes all occurrences of pkl with proto.
Signed-off-by: Adrian Reber <adrian@lisas.de>
After a successful test of the new mirrorlist server code in staging,
this is the next step. Try to make it work in production on one of the
proxies. As discussed on the mailing list we are trying the new setup
with proxy14.
All the conditionals have been updated to be 'staging or proxy14' and
the mirrorlist data generation has been enhanced to also write out the
new protobuf based format on the backend system.
At the same time this moves the pickle/protobuf generation from :55 to
:30 as this generation takes much longer than it used to be and the
mirrorlist server restarted at :15 was never using the new data during
the last few months.
Signed-off-by: Adrian Reber <adrian@lisas.de>
- chown /var/log/mirrormanager to mirrormanager.mirrormanager
- drop selinux relabeling for mounted directories
Signed-off-by: Adrian Reber <adrian@lisas.de>
Since we delegate the command, we can't test the cache files, since the
creates is looking on mm-backend01, not the proxies. So instead we
stat the cache files and only run the command if they don't exist.
Signed-off-by: Kevin Fenzi <kevin@scrye.com>