1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

quick fix for timeout in recovery

(This used to be ctdb commit 9205c681a819782d061bb41637191c130e91b100)
This commit is contained in:
Andrew Tridgell 2008-01-02 12:04:07 +11:00
parent ec5995221f
commit fa965dee8f
3 changed files with 3 additions and 9 deletions

View File

@ -295,12 +295,7 @@ tdb_off_t tdb_allocate(struct tdb_context *tdb, tdb_len_t length, struct list_st
bestfit.rec_len = rec->rec_len;
bestfit.rec_ptr = rec_ptr;
bestfit.last_ptr = last_ptr;
/* consider a fit to be good enough if
we aren't wasting more than half
the space */
if (bestfit.rec_len < 2*length) {
break;
}
break;
}
}

View File

@ -261,9 +261,9 @@ int tdb_expand(struct tdb_context *tdb, tdb_off_t size)
/* must know about any previous expansions by another process */
tdb->methods->tdb_oob(tdb, tdb->map_size + 1, 1);
/* always make room for at least 10 more records, and round
/* always make room for at least 100 more records, and round
the database up to a multiple of the page size */
size = TDB_ALIGN(tdb->map_size + size*10, tdb->page_size) - tdb->map_size;
size = TDB_ALIGN(tdb->map_size + size*100, tdb->page_size) - tdb->map_size;
if (!(tdb->flags & TDB_INTERNAL))
tdb_munmap(tdb);

View File

@ -6,7 +6,6 @@ if [ $# -gt 0 ]; then
fi
NODES="nodes.txt"
shift
shift
rm -f nodes.txt
for i in `seq 1 $NUMNODES`; do