On Thu, Aug 25, 2016 at 10:38 PM, Numan Siddique <nusid...@redhat.com> wrote:
> > > On Thu, Aug 25, 2016 at 5:37 AM, Andy Zhou <az...@ovn.org> wrote: > >> The main purpose of this series patch 6 (OVSDB: Reimplement >> replication. Using a state machine). Patch 7 includes >> a few replication usability enhancements that has been requested >> on the mailing list. >> >> Andy Zhou (7): >> ovsdb: Properly handle error returned from from reset_database() >> ovsdb: Add blacklist_tables >> ovsdb: Add request_ids >> ovsdb: (Re)hide struct db in ovsdb-server.c >> test: Improve replication unit tests >> OVSDB: Reimplement replication. Using a state machine. >> ovsdb: Replication usability improvements >> >> Documentation/OVSDB-replication.md | 2 +- >> ovsdb/jsonrpc-server.c | 6 + >> ovsdb/jsonrpc-server.h | 1 + >> ovsdb/ovsdb-server.1.in | 24 +- >> ovsdb/ovsdb-server.c | 308 +++++++++---- >> ovsdb/replication.c | 897 +++++++++++++++++++++++------- >> ------- >> ovsdb/replication.h | 54 ++- >> ovsdb/replication.man | 16 +- >> tests/ovsdb-replication.at | 28 +- >> tests/ovsdb-server.at | 203 ++++++--- >> 10 files changed, 1021 insertions(+), 518 deletions(-) >> >> > Hi Andy, > > I tested this patch series. I have noticed few core dumps > Thanks for testing and for the bug report. > > 1. I am seeing the below core dump quite often, If not 100% of the time > - I start both the ovsdb-server's as backup (both pointing to each > other) or > - > > When an active server transitions to backup > > ********************** > > (gdb) bt > #0 0x0000000000424640 in ovsdb_datum_compare_3way (a=0x10986a0, b=0x0, > type=0x107e728) at lib/ovsdb-data.c:1626 > #1 0x0000000000424719 in ovsdb_datum_equals (a=a@entry=0x10986a0, > b=b@entry=0x0, type=type@entry=0x107e728) at lib/ovsdb-data.c:1616 > #2 0x000000000040e3a9 in update_monitor_row_data (mt=0x10970a0, > mt=0x10970a0, data=<optimized out>, row=0x1098640) at ovsdb/monitor.c:310 > #3 ovsdb_monitor_changes_update (old=<optimized out>, new=0x1098640, > mt=0x10970a0, changes=<optimized out>) at ovsdb/monitor.c:1255 > #4 0x000000000040ef09 in ovsdb_monitor_change_cb (old=0x0, new=0x1098640, > changed=<optimized out>, aux_=0x7fff1aa0ec60) at ovsdb/monitor.c:1339 > #5 0x00000000004158b7 in ovsdb_txn_for_each_change (txn=<optimized out>, > cb=cb@entry=0x40edb0 <ovsdb_monitor_change_cb>, > aux=aux@entry=0x7fff1aa0ec60) at ovsdb/transaction.c:906 > #6 0x000000000040e0bc in ovsdb_monitor_commit (replica=0x10960a0, > txn=<optimized out>, durable=<optimized out>) at ovsdb/monitor.c:1553 > #7 0x00000000004157ca in ovsdb_txn_commit_ (durable=<optimized out>, > txn=0x10962c0) at ovsdb/transaction.c:868 > #8 ovsdb_txn_commit (txn=txn@entry=0x10962c0, durable=durable@entry=false) > at ovsdb/transaction.c:893 > #9 0x0000000000410c9e in process_notification (table_updates=0x1096470, > db=0x1083b00) at ovsdb/replication.c:569 > #10 0x0000000000411ca6 in process_notification (db=<optimized out>, > table_updates=<optimized out>) at ovsdb/replication.c:549 > #11 replication_run () at ovsdb/replication.c:182 > #12 0x0000000000406144 in main_loop (is_backup=0x7fff1aa0eee6, > exiting=0x7fff1aa0eee7, run_process=0x0, remotes=0x7fff1aa0ef30, > unixctl=0x1094980, > all_dbs=0x7fff1aa0ef70, jsonrpc=0x1070df0) at ovsdb/ovsdb-server.c:197 > #13 main (argc=1, argv=0x7fff1aa0f208) at ovsdb/ovsdb-server.c:425 > (gdb) quit > ************ > Sorry about this. I was able to reproduce it, it should now be fixed with the V2 series. > > 2. When I call unix command ovsdb-server/set-active-ovsdb-server without > passing the active ovsdb server's address. > > ***** > (gdb) bt > #0 0x00007f05fe75069a in strlen () from /lib64/libc.so.6 > #1 0x0000000000432fd9 in xstrdup (s=0x0) at lib/util.c:151 > #2 0x0000000000407fa2 in ovsdb_server_set_active_ovsdb_server > (conn=0xf5c9e0, argc=<optimized out>, argv=0xf4de60, config_=0x7fff53e12810) > at ovsdb/ovsdb-server.c:1132 > #3 0x0000000000432621 in process_command (request=0xf5dbe0, > conn=0xf5c9e0) at lib/unixctl.c:313 > #4 run_connection (conn=0xf5c9e0) at lib/unixctl.c:347 > #5 unixctl_server_run (server=server@entry=0xf5b980) at lib/unixctl.c:400 > #6 0x0000000000405c21 in main_loop (is_backup=0x7fff53e12766, > exiting=0x7fff53e12767, run_process=0x0, remotes=0x7fff53e127b0, > unixctl=0xf5b980, > all_dbs=0x7fff53e127f0, jsonrpc=0xf37df0) at ovsdb/ovsdb-server.c:182 > #7 main (argc=1, argv=0x7fff53e12a88) at ovsdb/ovsdb-server.c:425 > **** > > This command should fail without an argument. Fixed in v2 > > > 3. When I call unix command ovsdb-server/connect-active-ovsdb-server if > the active ovsdb server is not yet set. > ********** > (gdb) bt > #0 0x00007fa37f08469a in strlen () from /lib64/libc.so.6 > #1 0x0000000000432fd9 in xstrdup (s=s@entry=0x0) at lib/util.c:151 > #2 0x0000000000411440 in replication_init (sync_from_=0x0, > exclude_tables=0x0) at ovsdb/replication.c:114 > #3 0x00000000004079be in ovsdb_replication_init (sync_from=<optimized > out>, exclude=<optimized out>, all_dbs=0x7ffc530ca900) > at ovsdb/ovsdb-server.c:142 > #4 0x0000000000408183 in ovsdb_server_connect_active_ovsdb_server > (conn=0x1c6fce0, argc=<optimized out>, argv=<optimized out>, > config_=0x7ffc530ca920) at ovsdb/ovsdb-server.c:1157 > #5 0x0000000000432621 in process_command (request=0x1c6fdc0, > conn=0x1c6fce0) at lib/unixctl.c:313 > #6 run_connection (conn=0x1c6fce0) at lib/unixctl.c:347 > #7 unixctl_server_run (server=server@entry=0x1c6e710) at > lib/unixctl.c:400 > #8 0x0000000000405c21 in main_loop (is_backup=0x7ffc530ca876, > exiting=0x7ffc530ca877, run_process=0x0, remotes=0x7ffc530ca8c0, > unixctl=0x1c6e710, > all_dbs=0x7ffc530ca900, jsonrpc=0x1c4ad60) at ovsdb/ovsdb-server.c:182 > #9 main (argc=1, argv=0x7ffc530cab90) at ovsdb/ovsdb-server.c:425 > > Added an error message to catch this case. Also added a unit test to cover this in V2. > ****** > > Thanks > Numan > > -- >> 1.9.1 >> >> _______________________________________________ >> dev mailing list >> dev@openvswitch.org >> http://openvswitch.org/mailman/listinfo/dev >> > > _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev