openvswitch-ipsec daemon fails to start

Bug #1983478 reported by Andrei Azhoichyk
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
openvswitch (Ubuntu)
New
Undecided
Unassigned

Bug Description

In Ubuntu 22.04 LTS (jammy) with openvswitch package v2.17.0-0ubuntu1 the https://bugs.launchpad.net/ubuntu/+source/openvswitch/+bug/1645323 bug appears again, because https://git.launchpad.net/~ubuntu-server-dev/ubuntu/+source/openvswitch/tree/debian/patches/ovs-dirs.patch?id=256b2312732e9aead36559e89129f2938d79f4fb patch is not applied:

# /usr/share/openvswitch/scripts/ovs-monitor-ipsec --pidfile=/var/run/openvswitch/ovs-monitor-ipsec.pid --ike-daemon=strongswan unix:/var/run/openvswitch/db.sock
2022-08-03T12:17:04Z | 0 | ovs-monitor-ipsec | INFO | Restarting IKE daemon
2022-08-03T12:17:04Z | 1 | ovs-monitor-ipsec | INFO | Restarting StrongSwan
Stopping strongSwan IPsec failed: starter is not running
Starting strongSwan 5.9.5 IPsec [starter]...
2022-08-03T12:17:06Z | 2 | ovs-monitor-ipsec | ERR | traceback
Traceback (most recent call last):
  File "/usr/share/openvswitch/scripts/ovs-monitor-ipsec", line 1354, in <module>
    main()
  File "/usr/share/openvswitch/scripts/ovs-monitor-ipsec", line 1303, in main
    schema_helper = ovs.db.idl.SchemaHelper()
  File "/usr/lib/python3/dist-packages/ovs/db/idl.py", line 2230, in __init__
    schema_json = ovs.json.from_file(location)
  File "/usr/lib/python3/dist-packages/ovs/json.py", line 61, in from_file
    stream = open(name, "r")
FileNotFoundError: [Errno 2] No such file or directory: '/usr/local/share/openvswitch/vswitch.ovsschema'
2022-08-03T12:17:06.578Z | 2 | ovs-monitor-ipsec | ERR | traceback
Traceback (most recent call last):
  File "/usr/share/openvswitch/scripts/ovs-monitor-ipsec", line 1354, in <module>
    main()
  File "/usr/share/openvswitch/scripts/ovs-monitor-ipsec", line 1303, in main
    schema_helper = ovs.db.idl.SchemaHelper()
  File "/usr/lib/python3/dist-packages/ovs/db/idl.py", line 2230, in __init__
    schema_json = ovs.json.from_file(location)
  File "/usr/lib/python3/dist-packages/ovs/json.py", line 61, in from_file
    stream = open(name, "r")
FileNotFoundError: [Errno 2] No such file or directory: '/usr/local/share/openvswitch/vswitch.ovsschema'

$ cat /usr/lib/python3/dist-packages/ovs/dirs.py
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# The @variables@ in this file are replaced by default directories for
# use in python/ovs/dirs.py in the source directory and replaced by the
# configured directories for use in the installed python/ovs/dirs.py.
#
import os

# Note that the use of """ is to aid in dealing with paths with quotes in them.
PKGDATADIR = os.environ.get("OVS_PKGDATADIR", """/usr/local/share/openvswitch""")
RUNDIR = os.environ.get("OVS_RUNDIR", """/usr/local/var/run/openvswitch""")
LOGDIR = os.environ.get("OVS_LOGDIR", """/usr/local/var/log/openvswitch""")
BINDIR = os.environ.get("OVS_BINDIR", """/usr/local/bin""")

DBDIR = os.environ.get("OVS_DBDIR")
if not DBDIR:
    sysconfdir = os.environ.get("OVS_SYSCONFDIR")
    if sysconfdir:
        DBDIR = "%s/openvswitch" % sysconfdir
    else:
        DBDIR = """/usr/local/etc/openvswitch"""

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.