Change ovsdb file ownership to match "$OVS_USER":"$OVS_GROUP" when we either create it for the first time, or upgrade it.
Signed-off-by: Andy Zhou <az...@ovn.org> --- utilities/ovs-lib.in | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/utilities/ovs-lib.in b/utilities/ovs-lib.in index 34e2041..3fbc2f5 100644 --- a/utilities/ovs-lib.in +++ b/utilities/ovs-lib.in @@ -376,4 +376,8 @@ upgrade_db () { create_db "$DB_FILE" "$DB_SCHEMA" fi fi + + # Make sure we change the ownership of related files, such as lock files, by changing + # the entire directory, not just the '$DB_FILE'. + chown -R "$OVS_USER":"$OVS_GROUP" `dirname $DB_FILE` } -- 1.8.3.1 _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev