summaryrefslogtreecommitdiff
path: root/ctdb/doc
diff options
context:
space:
mode:
authorMartin Schwenke <martin@meltin.net>2019-03-29 11:19:55 +1100
committerAmitay Isaacs <amitay@samba.org>2019-05-07 05:45:34 +0000
commitb80967f5dcc6b58db0c38ec3e5cf0cbe46dbeb4b (patch)
tree66c0171b773cb11e555ffcd1248ee112017a952b /ctdb/doc
parent8108b3134c017c22d245fc5b2207a88d44ab0dd2 (diff)
downloadsamba-b80967f5dcc6b58db0c38ec3e5cf0cbe46dbeb4b.tar.gz
ctdb-scripts: Drop script configuration variable CTDB_MONITOR_SWAP_USAGE
CTDB's system memory monitoring in 05.system.script monitors both main memory and swap. The swap monitoring was originally based on the (possibly incorrect, see below) idea that swap space stacks on top of main memory, so that when a system starts filling swap space then this is supposed to be a good sign that the system is running out of memory. Additionally, performance on a Linux system tends to be destroyed by the I/O associated with a lot of swapping to spinning disks. However, some platforms default to creating only 4GB of swap space even when there is 128GB of main memory. With such a small swap to main memory ratio, memory pressure can force swap to be nearly full even when a significant amount of main memory is still available and the system is performing well. This suggests that checking swap utilisation might be less than useful in many circumstances. So, remove the separate swap space checking and change the memory check to cover the total of main memory and swap space. Test function set_mem_usage() still takes an argument for each of main memory and swap space utilisation. For simplicity, the same number is now passed twice to make the intended results comprehensible. This could be changed later. A couple of tests are cleaned up to no longer use hard-coded /proc/meminfo and ps output. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Diffstat (limited to 'ctdb/doc')
-rw-r--r--ctdb/doc/ctdb-script.options.5.xml21
-rwxr-xr-xctdb/doc/examples/config_migrate.sh2
2 files changed, 1 insertions, 22 deletions
diff --git a/ctdb/doc/ctdb-script.options.5.xml b/ctdb/doc/ctdb-script.options.5.xml
index 9d545b5cc0d..6b2efb27ac2 100644
--- a/ctdb/doc/ctdb-script.options.5.xml
+++ b/ctdb/doc/ctdb-script.options.5.xml
@@ -964,27 +964,6 @@ CTDB_PER_IP_ROUTING_TABLE_ID_HIGH=9000
</listitem>
</varlistentry>
- <varlistentry>
- <term>
- CTDB_MONITOR_SWAP_USAGE=<parameter>SWAP-LIMITS</parameter>
- </term>
- <listitem>
- <para>
- SWAP-LIMITS takes the form
- <parameter>WARN_LIMIT</parameter><optional>:<parameter>UNHEALTHY_LIMIT</parameter></optional>
- indicating that warnings should be logged if
- swap usage reaches WARN_LIMIT%. If usage reaches
- UNHEALTHY_LIMIT then the node should be flagged
- unhealthy. Either WARN_LIMIT or UNHEALTHY_LIMIT may be
- left blank, meaning that check will be omitted.
- </para>
- <para>
- Default is 25, so warnings will be logged when swap
- usage reaches 25%.
- </para>
- </listitem>
- </varlistentry>
-
</variablelist>
</refsect2>
diff --git a/ctdb/doc/examples/config_migrate.sh b/ctdb/doc/examples/config_migrate.sh
index 8479aeb39f3..e0d01e77057 100755
--- a/ctdb/doc/examples/config_migrate.sh
+++ b/ctdb/doc/examples/config_migrate.sh
@@ -209,6 +209,7 @@ CTDB_NOTIFY_SCRIPT
CTDB_PUBLIC_INTERFACE
CTDB_MAX_PERSISTENT_CHECK_ERRORS
CTDB_SHUTDOWN_TIMEOUT
+CTDB_MONITOR_SWAP_USAGE
EOF
}
@@ -262,7 +263,6 @@ CTDB_MAX_CORRUPT_DB_BACKUPS
# 05.system
CTDB_MONITOR_FILESYSTEM_USAGE
CTDB_MONITOR_MEMORY_USAGE
-CTDB_MONITOR_SWAP_USAGE
# debug_hung_scripts.sh
CTDB_DEBUG_HUNG_SCRIPT_STACKPAT
EOF