[ovs-dev] [PATCH v2] ovsdb-tool: Convert clustered db to standalone db.

Ben Pfaff blp at ovn.org
Fri Aug 23 21:50:46 UTC 2019


On Fri, Aug 23, 2019 at 09:29:00PM +0000, Ginwala, Aliasgar wrote:
> Hi Ben:
> 
> It seems ovsdb-client backup does conversion for openvswitch databases and not OVN dbs:
> $ovsdb-client backup > standalone_db.db
> 
> When trying for ovnnb dbs, it keeps complaining about syntax error. May be I miss something
> ovsdb-client backup  /var/run/openvswitch/ovnnb_db.sock /etc/openvswitch/ovnnb_db.db > test1.db
> ovsdb-client: invalid syntax for 'backup' (use --help for help)

ovsdb-client is definitely biased in favor of the Open_vSwitch database.
It recognizes server names based on the syntax for connections, which
always includes ":", so you would need to say
"unix:/var/run/openvswitch/ovnnb_db.sock" as the server name.

> However, I checked code and it doesn’t accept args as per code below in ovsdb_client_command
> { "backup",             NEED_DATABASE, 0, 0,       do_backup },

It doesn't accept args beyond an optional server name and database name,
which NEED_DATABASE indicates.

> Also, for ovn control plane nodes, we don’t have/need to run ovs on the control plane nodes.
> As I didn’t have ovs running on my control plane nodes, it complained about the same.
> ovsdb-client: failed to connect to "unix:/var/run/openvswitch/db.sock" (No such file or directory)
> Only works if I start ovs and then run the command.
> 
> So I think current doc itself needs update if I hope I didn’t miss anything trivial.
> Let me know and I can send formal patch to correct existing doc.

If the documentation isn't clear, let's improve it.


More information about the dev mailing list