1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-27 14:04:05 +03:00

102 Commits

Author SHA1 Message Date
Michael Adam
f07d47a56d tests: add a comment to recovery db corruption test
The comment explains that we use "ctdb stop" and "ctdb continue"
but we should use "ctdb setcrecmasterrole off".

Signed-off-by: Michael Adam <obnox@samba.org>

(This used to be ctdb commit 06ac62f890299021220214327f1b611c3cf00145)
2013-04-17 21:16:45 +10:00
Amitay Isaacs
41e2a2e272 tests: Add a test for subsequent recoveries corrupting databases
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Michael Adam <obnox@samba.org>

(This used to be ctdb commit b1577a11d548479ff1a05702d106af9465921ad4)
2013-04-17 21:16:45 +10:00
Amitay Isaacs
43860e4ba0 tests: Fix typo in variable name
Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit 043e18a8324ccb2c8ddd7b323ebedb5b0de1298d)
2013-04-15 15:37:39 +10:00
Amitay Isaacs
cad815164c tests: Add a test for recovery of persistent databases
Ensure that RSN based recovery and __db_sequence_number__ based recovery
methods for persistent databases work correctly.  They should not cause
corruption of the database.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit 45d439a1ab093b420c27b1502ef109021833c7af)
2013-01-09 13:18:34 +11:00
Martin Schwenke
ef7329a415 tests/simple: Add test to check recovery daemon IP verification
Also update ips_are_on_nodeglob() to handle negation.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 13a5944f8a27d43006acfffba76958693cae7702)
2013-01-08 13:27:10 +11:00
Martin Schwenke
752ab15cb1 tests: new simple integration test for delip interface garbage collection
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 1a5410e8349cdb96fdc51aa5ecd4f5734f6798a5)
2013-01-07 12:19:34 +11:00
Amitay Isaacs
4ca7f95d4f tests: Do not check release suffix in ctdb version test
release suffix added by RPM is to track packaging changes. Core CTDB
version does not include the release suffix.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit aad1584da8a8425bc6f5163c95810e9d2390dc91)
2012-10-31 12:19:03 +11:00
Amitay Isaacs
6182d9eaa1 tests: Fix statistics test for new output lines from locking API
Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit 1ee55c511b99e9f8a6fa4e34207267e953f09bae)
2012-10-20 02:48:44 +11:00
Martin Schwenke
e2a604f93c tests/simple: ctdb stop/continue tests weren't actually checking IPs
The correct variable is $test_node_ips, not $ips.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 8d17dacee415dd0b4268805a366a86f83e33f27c)
2012-07-26 22:03:00 +10:00
Martin Schwenke
959e37da7b tests: simple tests against local daemons should check $TEST_LOCAL_DEAMONS
Note the old $CTDB_TEST_REAL_CLUSTER - it doesn't exist anymore...

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 47180dc75d15f3d61470705603565b718491c9f8)
2012-07-26 22:03:00 +10:00
Martin Schwenke
867381486d tests/simple: ctdb reloadips test should use $test_ip
There's no point recalculating this value.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 6e7bd9685406ae024d413a5d9d8c6e0d89b15567)
2012-07-26 22:03:00 +10:00
Amitay Isaacs
0cb1cc631d tests: Fix ctdb_fetch test (parse extra lines of output)
Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit 0be452958db95c8253c362a1c08a1966e53a1f99)
2012-05-28 11:22:28 +10:00
Martin Schwenke
aa50bc580c tests: Move the "ctdb reloadips" test from complex/ to simple/
This is made possible by separation of public addresses files for
local daemons and the addition of get_ctdbd_command_line_option().

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 2bcd58b30d7cf6dd48ad7f019810c6965a44c85a)
2012-05-14 15:13:41 +10:00
Amitay Isaacs
ec72e30b8f tests/simple: Fix typo in the test message
Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit c642b452e7b0272e32c02509ac579b790d9a03e7)
2012-05-01 12:09:38 +10:00
Martin Schwenke
46f82181d0 tests/simple: Add new pseudo testcase to potentially shutdown local daemons
Only shuts them down if $TEST_CLEANUP is true.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit eddfc02335202d853e29a89f08225ab44cac8a25)
2012-04-27 15:42:42 +10:00
Martin Schwenke
451e660338 tests: Time logging in integration tests should use TEST_VAR_DIR
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 734cbd7def23236d418ebc6d813a748a84900101)
2012-04-27 15:42:42 +10:00
Martin Schwenke
edaead3cd5 tests/simple: Replace "tdbdump" with "ctdb cattdb"
tdbdump may not be installed and would be an unnecessary dependency.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit fbabc05569d91bf033f474d89f51b49490943332)
2012-04-27 15:40:43 +10:00
Martin Schwenke
6764b7b33e tests: Update README files and add new README files where missing
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit bef03b32f8ec114a64c55b25951aeeb939d87b33)
2012-04-27 15:40:43 +10:00
Martin Schwenke
f30d4c575e tests: Local daemons are no longer the default, now require run_tests -l
Testing with local daemons is the current default but this is not the
most common use case.  Therefore, we make local daemons optional by
using the -l switch with run_tests or by setting TEST_LOCAL_DAEMONS to
the number of daemons to be used (-l sets this to 3).

TEST_LOCAL_DAEMONS replaces CTDB_TEST_NUM_DAEMONS and
CTDB_TEST_REAL_CLUSTER is removed.

Most relevant logic is moved from ctdb_test_env to integration.bash.
ctdb_test_check_real_cluster() is moved from integration.bash to
complex/scripts/local.bash.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 72ecae61c43b318ec94b527a12cbb0a382e8c3db)
2012-04-27 15:40:43 +10:00
Martin Schwenke
bf197d097f tests: Rename ctdb_test_functions.bash to integration.bash
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 79adb50b3ce3873c3baf9e6715c1d1c3f181ce43)
2012-04-27 15:40:43 +10:00
Ronnie Sahlberg
618d247420 Merge remote branch 'martins/master'
(This used to be ctdb commit abe7ebe6c531f912efe4ebc1daade4d2af67574c)
2012-04-18 13:48:43 +10:00
Martin Schwenke
d4785e813a Tests - turn of time logging by default
We haven't seen problems related to time jumps for a long time.  Turn
this off by default.

To switch it back on set $CTDB_TEST_TIME_LOGGING to any non-null
value.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 2aa9bbf3a52dde0707eb06acd91e57c8da5c717f)
2012-04-16 14:57:44 +10:00
Amitay Isaacs
f2a5fda861 tests: Check assigned IPs from ctdb output
This fixes the test ctdb_config_add_ip when running against local daemons.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit b81c2c8a2360001fe73f9fd9aa1ba32665fdb0bb)
2012-04-13 14:51:13 +10:00
Amitay Isaacs
db13fd893c tests: Check for assigned IP addresses only if we are on real cluster
This fixes the ctdb_ip test when running against local daemons.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit a108fc14d90b6d552736d19b0ea104f2508dc331)
2012-04-13 14:51:13 +10:00
Amitay Isaacs
ea1c89566e tests: Add regular expression parsing for hop_count_buckets
This fixes the test to check ctdb statistics output.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>

(This used to be ctdb commit 98c633ab4824e0e4d28ab2eb2532e16eb859bd94)
2012-04-13 14:51:13 +10:00
Ronnie Sahlberg
7698a5105e Add test for NoIPTakeover
(This used to be ctdb commit 79172330d10ae0d5a7e5bf724959c9e5784716b4)
2012-04-12 10:31:17 +10:00
Ronnie Sahlberg
b3ddf6901d Merge remote branch 'martins/master'
(This used to be ctdb commit af72f8bc05f78983f9624d81788f9d89af474b11)
2012-03-15 16:09:41 +11:00
Ronnie Sahlberg
f7b2adfde6 Test: add test tool and test that UPDATE_RECORD works on persistent databases
(This used to be ctdb commit f06634951331232cddf0b48eac3552b92aca5b93)
2012-03-12 16:10:09 +11:00
Ronnie Sahlberg
1cfefb406f TESTS: Add test for wipedb command
(This used to be ctdb commit 4ea05fef886b0680d0ad0936c239a51fd75bf000)
2012-02-16 10:19:15 +11:00
Martin Schwenke
bd41a2ae0d Tests - simple - make disconnected node tests handle changed error message
Recent changes to nodestring parsing generalised the error message
logged when trying to talk to a disconnected node.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit db69a39ca010b2c8853b13466e30792dda350cdb)
2012-02-13 13:32:25 +11:00
Ronnie Sahlberg
5082bba246 READONLY: add test for creating and revoking delegations
(This used to be ctdb commit a7e7fa2169ee12f817336f6d03d5bb72df7ec020)
2012-02-13 11:16:24 +11:00
Ronnie Sahlberg
770bba6718 TESTS: Add a test that verifies that RecoverPDBBySeqNum works as expected.
If this tunable is set to 1 AND the persistent database contains a record "__db_sequence_number__" then we will recover the whole database as-is instead of doing the record by record recovery

(This used to be ctdb commit 3e5d2b61fcb4d0062d2573d99724f630a4fc4622)
2012-02-08 08:59:53 +11:00
Martin Schwenke
facd0ce624 Tests - ctdb listvars test should allow alphanumericals in tunable names.
This matches the new "LCP2PublicIPs" tunable.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 0680437bf5f02aeaed6387370e58bbdba2c04f28)
2011-08-15 13:56:26 +10:00
Martin Schwenke
47f1a7dd5b Test suite: Fix consistency in 26_ctdb_config_check_error_on_unreachable.
The test currently waits until any node thinks that the test node is
disconnected, and then uses node 0 as a proxy for testing.  However,
nodes may notice at different times that a node is disconnected, so
this test can fail unnecessarily.

We force the proxy node for the wait-until-disconnected to be the same
as the proxy node used to launch the actual tests.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 73cfc304513358e99e6505c95f44a4d319201309)
2011-08-08 16:35:55 +10:00
Martin Schwenke
6ffeae85d6 Test suite: Fix consistency in 09_ctdb_ping.sh.
Same problem as described in commit
283a85b42d9c0a26acb64d5abcc7f175e31e6e75.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 7758fd0591467a758e5d22404aa59fcbc1e1cb8b)
2011-08-08 16:35:22 +10:00
Martin Schwenke
667a743fff Test suite: Strip architecture suffix from CTDB RPM package version.
Later versions of RPM seem to include it but we don't want it.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 6c8eedb21a5e231d4a26ac26706ea51f348a27e0)
2011-08-08 16:34:48 +10:00
Martin Schwenke
b3db37cd30 Test suite: remove getmonmode test.
This can't be made 100% reliable since the monitor mode can change
underneath us due to some event.  Therefore, the test is useless.

Signed-off-by: Martin Schwenke <martin@meltin.net>

Conflicts:

	tests/simple/20_ctdb_getmonmode.sh

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 98ccdc6241a73036c4f210bb510f1cb5cff588cc)
2011-08-08 16:33:47 +10:00
Martin Schwenke
7e5549a54e Test suite: make time log use seconds since epoch.
Easier to implement automatic checking.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 18db530880849b59445d7aa508bf218bdd77ea1c)
2011-08-03 16:06:40 +10:00
Martin Schwenke
4f4cf7b100 Test suite: make time logging only happen on a real cluster, not local daemons.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit a6b3a7b7db9aa5fc971aae11b9b012e72c7d240c)
2011-08-03 16:06:40 +10:00
Martin Schwenke
bb32a6cf70 Test suite: add time logging.
We're seeing some weirdness with CTDB controls timing out.  We're
wondering if time is jumping forward, so this creates a time log on
each node that we can examine later if tests fail weirdly.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 5d82d89ee99f10bead101aebda645a80435ba246)
2011-08-03 16:06:40 +10:00
Martin Schwenke
44d66153af Test suite: fix typo in ctdb ping test grep pattern.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit ad18bfa398e582474afe25340368e39d4e74e3c6)
2010-11-17 11:39:51 +11:00
Martin Schwenke
0ff7924d15 Test suite: match changed output for ctdb ping to disconnected node.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit a9f5ae2a548e1096c086888adc886cb604d372fa)
2010-11-17 11:38:45 +11:00
Martin Schwenke
bcb6e726b6 Test suite: make statistics test cope with changes to statistics output.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 9e88466a99b5245d5f0ebab553be8d2b9b9a58e2)
2010-11-17 11:35:05 +11:00
Martin Schwenke
4e9fe3545c Test suite: loosen the getmonmode test.
Monitoring could be off at the beginning of the test.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 6a33a7715067175869ea2f3f15b64c3371079a6b)
2010-08-18 11:25:44 +10:00
Martin Schwenke
d549c31031 Test suite: make addip test use $CTDB rather than ctdb in debug code.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 5bb6b28ab7b45b7242d100ae8f1483d02e1d0d1d)
2010-08-11 16:55:33 +10:00
Martin Schwenke
b50ec65963 Test suite: remove unnecessary verbosity from enable/continue tests.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 69c95b2a42f55b80cd8d91a90ab55166f964163b)
2010-08-05 16:03:21 +10:00
Martin Schwenke
f66b5b46d6 Test suite: Fix typo in continue test.
Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit c2bce140da7c4b118394ee77bb9d0348d27e7e95)
2010-08-05 16:01:23 +10:00
Martin Schwenke
77ad2be488 Test suite: weaken ctdb continue/enable tests for non-deterministic IPs.
These tests currently wait for the old IPs to fail back to the test
node.  This isn't guaranteed with DeterministicIPs disabled.

This changes those tests to wait until the test node gets at least 1
IP assigned.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit e9b3f5b1b51d541a911a27eb4348b368f28d185e)
2010-08-05 15:58:56 +10:00
Martin Schwenke
774582c360 Test suite - make the ctdb_fetch test cope with "Reqid wrap!" messages.
Recent CTDB notice the wrap and print this message.  The test needs to
cope.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit b93b60ec96d02ce4f54921e85a5c5554d1fc0c55)
2010-08-05 13:43:50 +10:00
Martin Schwenke
dff9282917 Test suite: remove thaw/freeze tests.
They test debugging commands that no longer operate as expected.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit d33fa4d6557aab1938049f194c2de55f2c395bd2)
2010-08-05 11:40:05 +10:00