2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-28 12:58:00 +00:00

5 Commits

Author SHA1 Message Date
Ilya Maximets
fe1d48dba2 rhel, debian: Add missing restart policy to ipsec service.
Currently, if openvswitch-ipsec service will die for any reason it
will not be restarted. At the same time, that will prevent updating
tunnel configuration and prohibit adding new nodes in OVN clusters,
for example.

Add the 'on-failure' restart policy, so it behaves the same as all
other OVS daemons.

Acked-by: Frode Nordahl <fnordahl@ubuntu.com>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
2025-01-16 13:54:27 +01:00
Ilya Maximets
656c95e133 rhel, debian: Fix systemd monitoring wrong pid for ovs-monitor-ipsec.
Other services are running without monitors, so systemd can properly
track the pid.  But ovs-monitor-ipsec is running with a monitor, so
there is one more fork and systemd complains about the pid file:

  systemd[1]: openvswitch-ipsec.service: Supervising process 1037185
              which is not our child. We'll most likely not notice
              when it exits.

This is also causing some spurious kills sent to the child on service
stop.

Fix by running ovs-monitor-ipsec without a monitor as all other OVS
services.

We can't use start_daemon, that would take care of this, because the
script is not on the PATH and we don't want to accidentally change
permissions for OVS directories (ipsec runs as root), but we can mimic
the behavior.

Debian package had a custom patch for this issue, removing now.

Fixes: f385abded520 ("rhel: Use PIDFile on forking systemd service files")
Fixes: 9990322610f6 ("debian: Update packaging source from Debian/Ubuntu.")
Acked-by: Frode Nordahl <fnordahl@ubuntu.com>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
2025-01-16 13:54:21 +01:00
Timothy Redaelli
113f925aa5 rhel: Use /run instead of /var/run.
Systemd unit file generates warnings about PID file path since /var/run
is a legacy path so just use /run instead of /var/run.

/var/run is a symlink of /run starting from RHEL7 (and any other distribution
that uses systemd).

Reported-at: https://bugzilla.redhat.com/1952081
Signed-off-by: Timothy Redaelli <tredaelli@redhat.com>
Acked-by: Flavio Leitner <fbl@sysclose.org>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
2021-11-08 22:45:49 +01:00
Timothy Redaelli
f385abded5 rhel: Use PIDFile on forking systemd service files
Currently, PIDFile is not used in systemd service files with
Type=forking. This means sometimes systemd fails to restart a daemon
that is killed (with SIGKILL) or that is crashed.

This commit adds PIDFile to all systemd service file with Type=forking
in order to always have the correct PID to monitor.

Reported-at: https://bugzilla.redhat.com/1653717
Reported-by: Candido Campos <ccamposr@redhat.com>
Acked-by: Flavio Leitner <fbl@sysclose.org>
Signed-off-by: Timothy Redaelli <tredaelli@redhat.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
2019-02-28 14:29:21 -08:00
Qiuyu Xiao
bdddc71535 debian and rhel: Create IPsec package.
Added rules and files to create debian and rpm ovs-ipsec packages.

Signed-off-by: Qiuyu Xiao <qiuyu.xiao.qyx@gmail.com>
Signed-off-by: Ansis Atteka <aatteka@ovn.org>
Co-authored-by: Ansis Atteka <aatteka@ovn.org>
Signed-off-by: Ben Pfaff <blp@ovn.org>
2018-11-09 15:03:48 -08:00