mirror of
https://github.com/samba-team/samba.git
synced 2025-02-04 17:47:26 +03:00
merge from ronnie
(This used to be ctdb commit b92bfe97999e110915e10070bdbd389a92d40404)
This commit is contained in:
commit
dfe501c2c8
@ -888,6 +888,30 @@ static int send_election_request(struct ctdb_recoverd *rec, TALLOC_CTX *mem_ctx,
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
this function will unban all nodes in the cluster
|
||||
*/
|
||||
static void unban_all_nodes(struct ctdb_context *ctdb)
|
||||
{
|
||||
int ret, i;
|
||||
struct ctdb_node_map *nodemap;
|
||||
TALLOC_CTX *tmp_ctx = talloc_new(ctdb);
|
||||
|
||||
ret = ctdb_ctrl_getnodemap(ctdb, CONTROL_TIMEOUT(), CTDB_CURRENT_NODE, tmp_ctx, &nodemap);
|
||||
if (ret != 0) {
|
||||
DEBUG(0,(__location__ " failed to get nodemap to unban all nodes\n"));
|
||||
return;
|
||||
}
|
||||
|
||||
for (i=0;i<nodemap->num;i++) {
|
||||
if ( (!(nodemap->nodes[i].flags & NODE_FLAGS_DISCONNECTED))
|
||||
&& (nodemap->nodes[i].flags & NODE_FLAGS_BANNED) ) {
|
||||
ctdb_ctrl_modflags(ctdb, CONTROL_TIMEOUT(), nodemap->nodes[i].vnn, 0, NODE_FLAGS_BANNED);
|
||||
}
|
||||
}
|
||||
|
||||
talloc_free(tmp_ctx);
|
||||
}
|
||||
|
||||
/*
|
||||
handler for recovery master elections
|
||||
@ -912,6 +936,7 @@ static void election_handler(struct ctdb_context *ctdb, uint64_t srvid,
|
||||
DEBUG(0, (__location__ " failed to initiate recmaster election"));
|
||||
}
|
||||
talloc_free(mem_ctx);
|
||||
/*unban_all_nodes(ctdb);*/
|
||||
return;
|
||||
}
|
||||
|
||||
@ -920,6 +945,7 @@ static void election_handler(struct ctdb_context *ctdb, uint64_t srvid,
|
||||
ctdb->recovery_lock_fd != -1) {
|
||||
close(ctdb->recovery_lock_fd);
|
||||
ctdb->recovery_lock_fd = -1;
|
||||
unban_all_nodes(ctdb);
|
||||
}
|
||||
|
||||
/* ok, let that guy become recmaster then */
|
||||
|
@ -11,15 +11,20 @@ Not all CTDB documentation is complete yet, but here are some bits to
|
||||
get you started
|
||||
|
||||
<ul>
|
||||
<li><a href="http://ctdb.samba.org/~tridge/ctdb/doc/ctdb.1.html">ctdb manual page</a>
|
||||
<li><a href="download.html">downloading CTDB</a>
|
||||
<li><a href="building.html">building CTDB</a>
|
||||
<li><a href="configuring.html">configuring CTDB</a>
|
||||
<li><a href="configuring.html">testing CTDB</a>
|
||||
<li><a href="prerequisites.html">Prerequisites</a>
|
||||
<li><a href="download.html">Downloading CTDB</a>
|
||||
<li><a href="building.html">Building CTDB</a>
|
||||
<li><a href="configuring.html">Configuring CTDB</a>
|
||||
<li><a href="configuring.html">Testing CTDB</a>
|
||||
<li><a href="samba.html">Setting up Samba with CTDB</a>
|
||||
<li><a href="ftp.html">Setting up FTP with CTDB</a>
|
||||
<li><a href="nfs.html">Setting up NFS with CTDB</a>
|
||||
<li><a href="http://wiki.samba.org/index.php/CTDB_Setup">CTDB Wiki</a>
|
||||
</ul>
|
||||
|
||||
Man pages:
|
||||
<ul>
|
||||
<li><a href="http://ctdb.samba.org/~tridge/ctdb/doc/ctdb.1.html">ctdb manual page</a>
|
||||
</ul>
|
||||
|
||||
<!--#include virtual="footer.html" -->
|
||||
|
@ -61,17 +61,8 @@ README file</a> for some description of how TDB is used.
|
||||
|
||||
<h2>Documentation</h2>
|
||||
|
||||
<ul>
|
||||
<li><a href="download.html">Getting the code</a><br>
|
||||
<li><a href="building.html">Building Samba and CTDB</a><br>
|
||||
<li><a href="configuring.html">Configuring CTDB</a><br>
|
||||
<li><a href="testing.html">Starting and testing CTDB</a><br>
|
||||
<li><a href="samba.html">Setting up clustered Samba</a><br>
|
||||
<li><a href="nfs.html">Setting up clustered NFS</a><br>
|
||||
<li><a href="ftp.html">Setting up clustered FTP</a><br>
|
||||
</ul>
|
||||
<a href="./documentation.html">CTDB documentation</a><br><br>
|
||||
|
||||
<br>
|
||||
Additional documentation on how to install and configure CTDB is available in the
|
||||
<a href="http://wiki.samba.org/index.php/CTDB_Setup">CTDB
|
||||
Wiki</a>. Please read all of the documentation carefully.
|
||||
@ -127,7 +118,7 @@ retransmission timeouts that may be active in the clients.
|
||||
<h2>Discussion and bug reports</h2>
|
||||
|
||||
For discussions please use
|
||||
the <ahref="https://lists.samba.org/mailman/listinfo/samba-technical">samba-technical</a>
|
||||
the <a href="https://lists.samba.org/mailman/listinfo/samba-technical">samba-technical</a>
|
||||
mailing list. To submit a bug report, please use
|
||||
the <a href="http://bugzilla.samba.org/">Samba bugzilla</a> bug
|
||||
tracking system.
|
||||
|
22
ctdb/web/prerequisites.html
Normal file
22
ctdb/web/prerequisites.html
Normal file
@ -0,0 +1,22 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>Prerequisites</TITLE>
|
||||
</HEAD>
|
||||
<!--#include virtual="header.html" -->
|
||||
|
||||
<h1>Prerequisites</h1>
|
||||
|
||||
Before you can start using CTDB you must first install and configure a bunch of linux boxes.<br><br>
|
||||
|
||||
After that you need to install and configure a cluster filesystem and mount that cluster filesystem on all the linux boxes that will form your cluster.<br><br>
|
||||
|
||||
We have primarily used the GPFS filesystem for our testing but any cluster filesystem should work as long as it provides correct file locking.<br>
|
||||
|
||||
<h1>Other cluster filesystems</h1>
|
||||
While we primarily test with GPFS, CTDB should work with almost any other cluster filesystem as well.<br><br>
|
||||
Please let us know your experiences in using other cluster filesystems.
|
||||
|
||||
|
||||
<!--#include virtual="footer.html" -->
|
||||
|
Loading…
x
Reference in New Issue
Block a user