Rev 565: log the generation numbers to give a hint about this bug in http://samba.org/~tridge/ctdb
revno: 565 revision-id: [EMAIL PROTECTED] parent: [EMAIL PROTECTED] committer: Andrew Tridgell [EMAIL PROTECTED] branch nick: tridge timestamp: Sun 2007-07-08 19:36:55 +1000 message: log the generation numbers to give a hint about this bug modified: server/ctdb_call.c ctdb_call.c-20061128065342-to93h6eejj5kon81-1 === modified file 'server/ctdb_call.c' --- a/server/ctdb_call.c2007-06-07 12:26:27 + +++ b/server/ctdb_call.c2007-07-08 09:36:55 + @@ -311,8 +311,9 @@ } if (ctdb_lmaster(ctdb, key) != ctdb-vnn) { - DEBUG(0,(vnn %u dmaster request to non-lmaster lmaster=%u\n, -ctdb-vnn, ctdb_lmaster(ctdb, key))); + DEBUG(0,(vnn %u dmaster request to non-lmaster lmaster=%u gen=%u curgen=%u\n, +ctdb-vnn, ctdb_lmaster(ctdb, key), +hdr-generation, ctdb-vnn_map-generation)); ctdb_fatal(ctdb, ctdb_req_dmaster to non-lmaster); } @@ -321,9 +322,9 @@ /* its a protocol error if the sending node is not the current dmaster */ if (header.dmaster != hdr-srcnode) { - DEBUG(0,(vnn %u dmaster request non-master %u dmaster=%u key %08x dbid 0x%08x\n, + DEBUG(0,(vnn %u dmaster request non-master %u dmaster=%u key %08x dbid 0x%08x gen=%u curgen=%u\n, ctdb-vnn, hdr-srcnode, header.dmaster, ctdb_hash(key), -ctdb_db-db_id)); +ctdb_db-db_id, hdr-generation, ctdb-vnn_map-generation)); ctdb_fatal(ctdb, ctdb_req_dmaster from non-master); return; }
Rev 566: we do tell banned nodes to release IPs in http://samba.org/~tridge/ctdb
revno: 566 revision-id: [EMAIL PROTECTED] parent: [EMAIL PROTECTED] committer: Andrew Tridgell [EMAIL PROTECTED] branch nick: tridge timestamp: Sun 2007-07-08 20:24:03 +1000 message: we do tell banned nodes to release IPs modified: server/ctdb_takeover.c ctdb_takeover.c-20070525071636-a5n1ihghjtppy08r-2 === modified file 'server/ctdb_takeover.c' --- a/server/ctdb_takeover.c2007-07-04 06:51:13 + +++ b/server/ctdb_takeover.c2007-07-08 10:24:03 + @@ -510,8 +510,8 @@ have. This will be a NOOP on nodes that don't currently hold the given alias */ for (i=0;inodemap-num;i++) { - /* don't talk to unconnected nodes */ - if (nodemap-nodes[i].flags NODE_FLAGS_INACTIVE) { + /* don't talk to unconnected nodes, but do talk to banned nodes */ + if (nodemap-nodes[i].flags NODE_FLAGS_DISCONNECTED) { continue; }
Rev 568: fixed sense of inet_aton test in http://samba.org/~tridge/ctdb
revno: 568 revision-id: [EMAIL PROTECTED] parent: [EMAIL PROTECTED] committer: Andrew Tridgell [EMAIL PROTECTED] branch nick: tridge timestamp: Sun 2007-07-08 21:09:09 +1000 message: fixed sense of inet_aton test modified: server/ctdb_takeover.c ctdb_takeover.c-20070525071636-a5n1ihghjtppy08r-2 === modified file 'server/ctdb_takeover.c' --- a/server/ctdb_takeover.c2007-07-08 10:45:12 + +++ b/server/ctdb_takeover.c2007-07-08 11:09:09 + @@ -785,7 +785,7 @@ ctdb-takeover.interface, node-public_address, node-public_netmask_bits); - if (inet_aton(node-public_address, in) == 0) { + if (inet_aton(node-public_address, in) != 0) { release_kill_clients(ctdb, in); } }
Rev 567: call kill_clients when releasing all IPs, as well as for individual IPs in http://samba.org/~tridge/ctdb
revno: 567 revision-id: [EMAIL PROTECTED] parent: [EMAIL PROTECTED] committer: Andrew Tridgell [EMAIL PROTECTED] branch nick: tridge timestamp: Sun 2007-07-08 20:45:12 +1000 message: call kill_clients when releasing all IPs, as well as for individual IPs modified: server/ctdb_takeover.c ctdb_takeover.c-20070525071636-a5n1ihghjtppy08r-2 === modified file 'server/ctdb_takeover.c' --- a/server/ctdb_takeover.c2007-07-08 10:24:03 + +++ b/server/ctdb_takeover.c2007-07-08 10:45:12 + @@ -224,19 +224,19 @@ /* kill any clients that are registered with a IP that is being released */ -static void release_kill_clients(struct ctdb_context *ctdb, struct sockaddr_in *sin) +static void release_kill_clients(struct ctdb_context *ctdb, struct in_addr in) { struct ctdb_client_ip *ip; for (ip=ctdb-client_ip_list; ip; ip=ip-next) { - if (ip-ip.sin_addr.s_addr == sin-sin_addr.s_addr) { + if (ip-ip.sin_addr.s_addr == in.s_addr) { struct ctdb_client *client = ctdb_reqid_find(ctdb, ip-client_id, struct ctdb_client); if (client-pid != 0) { DEBUG(0,(__location__ Killing client pid %u for IP %s on client_id %u\n, -(unsigned)client-pid, inet_ntoa(sin-sin_addr), - ip-client_id)); +(unsigned)client-pid, inet_ntoa(in), +ip-client_id)); kill(client-pid, SIGKILL); } } @@ -266,7 +266,7 @@ ctdb_daemon_send_message(ctdb, ctdb-vnn, CTDB_SRVID_RELEASE_IP, data); /* kill clients that have registered with this IP */ - release_kill_clients(ctdb, state-sin); + release_kill_clients(ctdb, state-sin-sin_addr); /* tell other nodes about any tcp connections we were holding with this IP */ @@ -780,10 +780,14 @@ for (i=0;ictdb-num_nodes;i++) { struct ctdb_node *node = ctdb-nodes[i]; if (ctdb_sys_have_ip(node-public_address)) { + struct in_addr in; ctdb_event_script(ctdb, releaseip %s %s %u, ctdb-takeover.interface, node-public_address, node-public_netmask_bits); + if (inet_aton(node-public_address, in) == 0) { + release_kill_clients(ctdb, in); + } } } }
svn commit: samba r23751 - in branches: SAMBA_3_0/source/lib SAMBA_3_0_26/source/lib
Author: obnox Date: 2007-07-08 22:01:43 + (Sun, 08 Jul 2007) New Revision: 23751 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=revroot=sambarev=23751 Log: Call tdb_close even when validation was not successful. Michael Modified: branches/SAMBA_3_0/source/lib/util_tdb.c branches/SAMBA_3_0_26/source/lib/util_tdb.c Changeset: Modified: branches/SAMBA_3_0/source/lib/util_tdb.c === --- branches/SAMBA_3_0/source/lib/util_tdb.c2007-07-07 23:57:25 UTC (rev 23750) +++ branches/SAMBA_3_0/source/lib/util_tdb.c2007-07-08 22:01:43 UTC (rev 23751) @@ -994,7 +994,6 @@ int pfd) { int ret = -1; - int tfd = -1; int num_entries = 0; TDB_CONTEXT *tdb = NULL; struct tdb_validation_status v_status; @@ -1012,8 +1011,6 @@ goto out; } - tfd = tdb_fd(tdb); - /* Check the cache freelist is good. */ if (tdb_validate_freelist(tdb, num_entries) == -1) { DEBUG(0,(tdb_validate_child: bad freelist in cache %s\n, @@ -1048,12 +1045,7 @@ out: if (tdb) { - if (ret == 0) { - tdb_close(tdb); - } - else if (tfd != -1) { - close(tfd); - } + tdb_close(tdb); } DEBUG(10, (tdb_validate_child: writing status to pipe\n)); Modified: branches/SAMBA_3_0_26/source/lib/util_tdb.c === --- branches/SAMBA_3_0_26/source/lib/util_tdb.c 2007-07-07 23:57:25 UTC (rev 23750) +++ branches/SAMBA_3_0_26/source/lib/util_tdb.c 2007-07-08 22:01:43 UTC (rev 23751) @@ -994,7 +994,6 @@ int pfd) { int ret = -1; - int tfd = -1; int num_entries = 0; TDB_CONTEXT *tdb = NULL; struct tdb_validation_status v_status; @@ -1012,8 +1011,6 @@ goto out; } - tfd = tdb_fd(tdb); - /* Check the cache freelist is good. */ if (tdb_validate_freelist(tdb, num_entries) == -1) { DEBUG(0,(tdb_validate_child: bad freelist in cache %s\n, @@ -1048,12 +1045,7 @@ out: if (tdb) { - if (ret == 0) { - tdb_close(tdb); - } - else if (tfd != -1) { - close(tfd); - } + tdb_close(tdb); } DEBUG(10, (tdb_validate_child: writing status to pipe\n));
Build status as of Mon Jul 9 00:00:01 2007
URL: http://build.samba.org/ --- /home/build/master/cache/broken_results.txt.old 2007-07-08 00:01:57.0 + +++ /home/build/master/cache/broken_results.txt 2007-07-09 00:01:05.0 + @@ -1,25 +1,25 @@ -Build status as of Sun Jul 8 00:00:02 2007 +Build status as of Mon Jul 9 00:00:01 2007 Build counts: Tree Total Broken Panic SOC 0 0 0 build_farm 0 0 0 -ccache 35 8 0 +ccache 34 7 0 ctdb 0 0 0 distcc 2 0 0 -ldb 34 3 0 -libreplace 33 10 0 +ldb 33 2 0 +libreplace 32 10 0 lorikeet-heimdal 30 13 0 pidl 18 4 0 ppp 15 10 0 python 0 0 0 -rsync35 12 0 +rsync34 14 0 samba0 0 0 samba-docs 0 0 0 samba-gtk4 4 0 samba4 32 19 7 samba_3_035 18 0 -smb-build32 32 0 -talloc 35 8 0 -tdb 34 1 0 +smb-build31 31 0 +talloc 33 7 0 +tdb 32 0 0
svn commit: samba r23752 - in branches: SAMBA_3_0/source/smbd SAMBA_3_0_26/source/smbd
Author: jra Date: 2007-07-09 00:48:07 + (Mon, 09 Jul 2007) New Revision: 23752 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=revroot=sambarev=23752 Log: Fix bug introduced by checkin 22920, allow large readX. Fix from Dmitry Shatrov [EMAIL PROTECTED]. In send_file_readX(), if startpos sbuf.st_size, then smb_maxcnt is set to an invalid large value due to integer overflow. As for me, this resulted in MS Word hanging while trying to save a 1.5Mb document. This isn't in shipping code. Jeremy. Modified: branches/SAMBA_3_0/source/smbd/reply.c branches/SAMBA_3_0_26/source/smbd/reply.c Changeset: Modified: branches/SAMBA_3_0/source/smbd/reply.c === --- branches/SAMBA_3_0/source/smbd/reply.c 2007-07-08 22:01:43 UTC (rev 23751) +++ branches/SAMBA_3_0/source/smbd/reply.c 2007-07-09 00:48:07 UTC (rev 23752) @@ -2590,9 +2590,7 @@ if (startpos sbuf.st_size) { smb_maxcnt = 0; - } - - if (smb_maxcnt (sbuf.st_size - startpos)) { + } else if (smb_maxcnt (sbuf.st_size - startpos)) { smb_maxcnt = (sbuf.st_size - startpos); } Modified: branches/SAMBA_3_0_26/source/smbd/reply.c === --- branches/SAMBA_3_0_26/source/smbd/reply.c 2007-07-08 22:01:43 UTC (rev 23751) +++ branches/SAMBA_3_0_26/source/smbd/reply.c 2007-07-09 00:48:07 UTC (rev 23752) @@ -2590,9 +2590,7 @@ if (startpos sbuf.st_size) { smb_maxcnt = 0; - } - - if (smb_maxcnt (sbuf.st_size - startpos)) { + } else if (smb_maxcnt (sbuf.st_size - startpos)) { smb_maxcnt = (sbuf.st_size - startpos); }
svn commit: samba r23753 - in branches/SAMBA_4_0/source/lib/ldb/swig: .
Author: tpot Date: 2007-07-09 01:49:49 + (Mon, 09 Jul 2007) New Revision: 23753 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=revroot=sambarev=23753 Log: Fix bitrot afflicting the ldb Python swig bindings. Modified: branches/SAMBA_4_0/source/lib/ldb/swig/ldb.i Changeset: Modified: branches/SAMBA_4_0/source/lib/ldb/swig/ldb.i === --- branches/SAMBA_4_0/source/lib/ldb/swig/ldb.i2007-07-09 00:48:07 UTC (rev 23752) +++ branches/SAMBA_4_0/source/lib/ldb/swig/ldb.i2007-07-09 01:49:49 UTC (rev 23753) @@ -37,8 +37,9 @@ /* Include headers */ +#include lib/replace/replace.h +#include lib/talloc/talloc.h #include lib/ldb/include/ldb.h -#include lib/talloc/talloc.h %} @@ -179,7 +180,6 @@ struct ldb_dn *dn; unsigned int num_elements; struct ldb_message_element *elements; - void *private_data; }; /* @@ -213,11 +213,11 @@ int ldb_connect(struct ldb_context *ldb, const char *url, unsigned int flags, const char *options[]); -int ldb_search(struct ldb_context *ldb, const struct ldb_dn *base, enum ldb_scope scope, const char *expression, const char * const *attrs, struct ldb_result **OUT); +int ldb_search(struct ldb_context *ldb, struct ldb_dn *base, enum ldb_scope scope, const char *expression, const char * const *attrs, struct ldb_result **OUT); -int ldb_delete(struct ldb_context *ldb, const struct ldb_dn *dn); +int ldb_delete(struct ldb_context *ldb, struct ldb_dn *dn); -int ldb_rename(struct ldb_context *ldb, const struct ldb_dn *olddn, const struct ldb_dn *newdn); +int ldb_rename(struct ldb_context *ldb, struct ldb_dn *olddn, struct ldb_dn *newdn); int ldb_add(struct ldb_context *ldb, const struct ldb_message *message); @@ -227,11 +227,11 @@ struct ldb_message_element *ldb_msg_find_element(const struct ldb_message *msg, const char *attr_name); -int ldb_msg_add_value(struct ldb_message *msg, const char *attr_name, const struct ldb_val *INPUT); +int ldb_msg_add_value(struct ldb_message *msg, const char *attr_name, const struct ldb_val *val, struct ldb_message_element **return_el); void ldb_msg_remove_attr(struct ldb_message *msg, const char *attr); -int ldb_msg_sanity_check(struct ldb_message *msg); +int ldb_msg_sanity_check(struct ldb_context *ldb, const struct ldb_message *msg); /* DN operations */
svn commit: samba r23754 - in branches/SAMBA_4_0/source/libcli/raw: .
Author: abartlet Date: 2007-07-09 03:08:20 + (Mon, 09 Jul 2007) New Revision: 23754 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=revroot=sambarev=23754 Log: Make sure to check the status return before we de-reference the returned elements. Andrew Bartlett Modified: branches/SAMBA_4_0/source/libcli/raw/rawshadow.c Changeset: Modified: branches/SAMBA_4_0/source/libcli/raw/rawshadow.c === --- branches/SAMBA_4_0/source/libcli/raw/rawshadow.c2007-07-09 01:49:49 UTC (rev 23753) +++ branches/SAMBA_4_0/source/libcli/raw/rawshadow.c2007-07-09 03:08:20 UTC (rev 23754) @@ -46,6 +46,9 @@ nt.ntioctl.in.blob = data_blob(NULL, 0); status = smb_raw_ioctl(tree, mem_ctx, nt); + if (!NT_STATUS_IS_OK(status)) { + return status; + } blob = nt.ntioctl.out.blob;