Signed-off-by: Angus Salkeld <asalkeld@xxxxxxxxxx> --- INSTALL | 2 +- cts/corotests.py | 10 ++-- man/Makefile.am | 2 +- man/corosync-blackbox.8 | 2 +- man/corosync-cmapctl.8 | 85 +++++++++++++++++++++++++++++++++ man/corosync-notifyd.8 | 2 +- man/corosync-objctl.8 | 120 ----------------------------------------------- man/corosync-pload.8 | 4 +- man/index.html | 4 +- tools/.gitignore | 1 - tools/corosync-blackbox | 4 +- 11 files changed, 100 insertions(+), 136 deletions(-) create mode 100644 man/corosync-cmapctl.8 delete mode 100644 man/corosync-objctl.8 diff --git a/INSTALL b/INSTALL index b9dba63..5c00dec 100644 --- a/INSTALL +++ b/INSTALL @@ -168,7 +168,7 @@ I start up wireshark to see if there are any snmp traps been sent as I am too lazy to setup a manager to receive traps. run a program that talks to corosync e.g. -$ corosync-objctl +$ corosync-cmapctl And you should get traps diff --git a/cts/corotests.py b/cts/corotests.py index 3f66316..52b5932 100644 --- a/cts/corotests.py +++ b/cts/corotests.py @@ -1247,7 +1247,7 @@ check that we do NOT get watchdog'ed no_w.setwatch() time.sleep(2) - self.CM.rsh(node, 'corosync-objctl -d resources.system.memory_used') + self.CM.rsh(node, 'corosync-cmapctl -d resources.system.memory_used') yes_matched = yes_w.look() no_matched = no_w.look() @@ -1294,7 +1294,7 @@ check that we do NOT get watchdog'ed if poll_period < 500: poll_period = 500 self.CM.log("setting poll_period to: %d" % poll_period) - self.CM.rsh(node, 'corosync-objctl -w resources.system.memory_used.poll_period=%d' % poll_period) + self.CM.rsh(node, 'corosync-cmapctl -s resources.system.memory_used.poll_period str %d' % poll_period) sleep_time = poll_period * 2 / 1000 if sleep_time < 1: sleep_time = 1 @@ -1329,19 +1329,19 @@ confirm reboot action # get the uptime up_before = self.CM.rsh(node, 'cut -d. -f1 /proc/uptime', 1).rstrip() - cmd = 'corosync-objctl resources.system.memory_used. | grep current | cut -d= -f2' + cmd = 'corosync-cmapctl resources.system.memory_used. | grep current | cut -d= -f2' mem_current_str = self.CM.rsh(node, cmd, 1).rstrip() mem_new_max = int(mem_current_str) + 5 self.CM.log("current mem usage: %s, new max:%d" % (mem_current_str, mem_new_max)) - cmd = 'corosync-objctl -w resources.system.memory_used.max=' + str(mem_new_max) + cmd = 'corosync-cmapctl -s resources.system.memory_used.max str ' + str(mem_new_max) self.CM.rsh(node, cmd) self.CM.rsh(node, 'memhog -r10000 200m', synchronous=0) self.CM.log("wait for it to reboot") time.sleep(60 * 3) - cmd = 'corosync-objctl resources.system.memory_used. | grep current | cut -d= -f2' + cmd = 'corosync-cmapctl resources.system.memory_used. | grep current | cut -d= -f2' mem_current_str = self.CM.rsh(node, cmd, 1).rstrip() self.CM.log("current mem usage: %s" % (mem_current_str)) diff --git a/man/Makefile.am b/man/Makefile.am index b0a6257..767b5e6 100644 --- a/man/Makefile.am +++ b/man/Makefile.am @@ -39,7 +39,7 @@ EXTRA_DIST = index.html dist_man_MANS = \ corosync.conf.5 \ corosync.8 \ - corosync-objctl.8 \ + corosync-cmapctl.8 \ corosync-blackbox.8 \ corosync-keygen.8 \ corosync-cfgtool.8 \ diff --git a/man/corosync-blackbox.8 b/man/corosync-blackbox.8 index f416444..4201a5b 100644 --- a/man/corosync-blackbox.8 +++ b/man/corosync-blackbox.8 @@ -63,7 +63,7 @@ Finishing replay: records found [2609] .br .SH SEE ALSO .BR corosync-fplay (8), -.BR corosync-objctl (8), +.BR corosync-cmapctl (8), .SH AUTHOR Angus Salkeld .PP diff --git a/man/corosync-cmapctl.8 b/man/corosync-cmapctl.8 new file mode 100644 index 0000000..2f825b0 --- /dev/null +++ b/man/corosync-cmapctl.8 @@ -0,0 +1,85 @@ +.\"/* +.\" * Copyright (C) 2010 Red Hat, Inc. +.\" * +.\" * All rights reserved. +.\" * +.\" * Author: Angus Salkeld <asalkeld@xxxxxxxxxx> +.\" * +.\" * This software licensed under BSD license, the text of which follows: +.\" * +.\" * Redistribution and use in source and binary forms, with or without +.\" * modification, are permitted provided that the following conditions are met: +.\" * +.\" * - Redistributions of source code must retain the above copyright notice, +.\" * this list of conditions and the following disclaimer. +.\" * - Redistributions in binary form must reproduce the above copyright notice, +.\" * this list of conditions and the following disclaimer in the documentation +.\" * and/or other materials provided with the distribution. +.\" * - Neither the name of the MontaVista Software, Inc. nor the names of its +.\" * contributors may be used to endorse or promote products derived from this +.\" * software without specific prior written permission. +.\" * +.\" * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +.\" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +.\" * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +.\" * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +.\" * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +.\" * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +.\" * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +.\" * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF +.\" * THE POSSIBILITY OF SUCH DAMAGE. +.\" */ +.TH COROSYNC-CMAP 8 2012-01-23 +.SH NAME +corosync-cmapctl: \- A tool for accessing the object database. +.SH DESCRIPTION +usage: corosync\-cmapctl [\-b] [\-dghsTtp] [params...] +.HP +\fB\-b\fR show binary values +.SS "Set key:" +.IP +corosync\-cmapctl \fB\-s\fR key_name type value +.IP +where type is one of ([i|u][8|16|32|64] | flt | dbl | str | bin) +for bin, value is file name (or \- for stdin) +.SS "Load settings from a file:" +.IP +corosync\-cmapctl \fB\-p\fR filename +.IP +the format of the file is: +<key_name> <type> <value> +.SS "Delete key:" +.IP +corosync\-cmapctl \fB\-d\fR key_name... +.SS "Delete multiple keys with prefix:" +.IP +corosync\-cmapctl \fB\-D\fR key_prefix... +.SS "Get key:" +.IP +corosync\-cmapctl [\-b] \fB\-g\fR key_name... +.SS "Display all keys:" +.IP +corosync\-cmapctl [\-b] +.SS "Display keys with prefix key_name:" +.IP +corosync\-cmapctl [\-b] key_name... +.SS "Track changes on keys with key_name:" +.IP +corosync\-cmapctl [\-b] \fB\-t\fR key_name +.SS "Track changes on keys with key prefix:" +.IP +corosync\-cmapctl [\-b] \fB\-T\fR key_prefix +.SH "SEE ALSO" +The full documentation for +.B corosync-cmapctl: +is maintained as a Texinfo manual. If the +.B info +and +.B corosync-cmapctl: +programs are properly installed at your site, the command +.IP +.B info corosync-cmapctl: +.PP +should give you access to the complete manual. diff --git a/man/corosync-notifyd.8 b/man/corosync-notifyd.8 index 1ff8994..0c9255d 100644 --- a/man/corosync-notifyd.8 +++ b/man/corosync-notifyd.8 @@ -138,7 +138,7 @@ signal sender=:1.216 -> dest=(null destination) serial=6 path=/com/redhat/cluste string "left" .SH SEE ALSO .BR corosync (8), -.BR corosync-objctl (8), +.BR corosync-cmapctl (8), .BR dbus-monitor (1), .SH AUTHOR Angus Salkeld diff --git a/man/corosync-objctl.8 b/man/corosync-objctl.8 deleted file mode 100644 index 2b3a7b6..0000000 --- a/man/corosync-objctl.8 +++ /dev/null @@ -1,120 +0,0 @@ -.\"/* -.\" * Copyright (c) 2008 Allied Telesis Labs NZ. -.\" * -.\" * All rights reserved. -.\" * -.\" * Author: Angus Salkeld (angus.salkeld@xxxxxxxxxxxxxxxxxxx) -.\" * -.\" * This software licensed under BSD license, the text of which follows: -.\" * -.\" * Redistribution and use in source and binary forms, with or without -.\" * modification, are permitted provided that the following conditions are met: -.\" * -.\" * - Redistributions of source code must retain the above copyright notice, -.\" * this list of conditions and the following disclaimer. -.\" * - Redistributions in binary form must reproduce the above copyright notice, -.\" * this list of conditions and the following disclaimer in the documentation -.\" * and/or other materials provided with the distribution. -.\" * - Neither the name of the MontaVista Software, Inc. nor the names of its -.\" * contributors may be used to endorse or promote products derived from this -.\" * software without specific prior written permission. -.\" * -.\" * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -.\" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -.\" * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -.\" * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE -.\" * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -.\" * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -.\" * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -.\" * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN -.\" * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -.\" * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF -.\" * THE POSSIBILITY OF SUCH DAMAGE. -.\" */ -.TH COROSYNC-OBJCTL 8 2008-07-29 -.SH NAME -corosync-objctl \- Configure objects in the Object Database -.SH SYNOPSIS -.B "corosync-objctl [\-b] [\-c|\-w|\-d|\-a|\-t\-h] <OBJECT-SPEC>..." -.SH DESCRIPTION -.B corosync-objctl -is used to configure objects within the object database at runtime. -.SH OBJECT-SPEC -.TP -There are two types of entities -.B Objects -and -.B Key=Value pairs -.TP -.B Objects -Objects are container like entities that can hold other entities. -They are specified as "objectA"."objectB". -An example is logging.logger. -.TP -.B Key=Value pairs -These are the entities that actually hold values (read database "fields"). -They are specified as object.key=value or just object.key if you are reading. -.SH OPTIONS -.TP -.B -c -Create a new object. -.TP -.B -d -Delete an existing object. -.TP -.B -w -Use this option when you want to write a new value to a key. -.TP -.B -a -Display all values currently available. -.TP -.B -t -Track changes to an object and it's children. As changes are made to the object -they are printed out. this is kind of like a "tail -f" for the object database. -.TP -.B -h -Print basic usage. -.TP -.B -b -Display binary values in BASH backslash escape sequences format. -.SH EXAMPLES -.TP -Print the objOne object (shouldn't exist yet). -$ corosync-objctl objOne -.TP -Create the objOne object. -$ corosync-objctl -c objOne -.TP -Print the objOne object (empty). -$ corosync-objctl objOne -.br -objOne -.TP -Write two new keys to the objOne object. -$ corosync-objctl -w objOne.max=3000 objOne.min=100 -.TP -Print the objOne object (with the two new keys). -$ corosync-objctl objOne -.br -objOne.min=100 -.br -objOne.max=3000 -.TP -Delete the objOne.min key -$ corosync-objctl -d objOne.min=100 -.TP -Prove that is gone. -$ corosync-objctl objOne -.br -objOne.max=3000 -.TP -Delete the whole objOne object. -$ corosync-objctl -d objOne -.TP -Prove that is gone. -$ corosync-objctl objOne -.SH SEE ALSO -.BR confdb_initialize (3), -.SH AUTHOR -Angus Salkeld -.PP diff --git a/man/corosync-pload.8 b/man/corosync-pload.8 index 93c0993..b04fff4 100644 --- a/man/corosync-pload.8 +++ b/man/corosync-pload.8 @@ -45,7 +45,7 @@ All nodes will begin transmitting messages and they will stop when .PP To view the progress of this execute: .PP -$ corosync-objctl runtime.services.pload. +$ corosync-cmapctl runtime.services.pload. .br runtime.services.pload.service_id=13 .br @@ -63,7 +63,7 @@ and the time that this took. corosync[4931]: [PLOAD ] 1500000 Writes 300 bytes per write 30.838 seconds runtime, 48640.968 TP/S, 13.916 MB/S. .TP .SH SEE ALSO -.BR corosync-objctl (8) +.BR corosync-cmapctl (8) .SH AUTHOR Angus Salkeld .PP diff --git a/man/index.html b/man/index.html index 709f2e5..0b5b1ab 100644 --- a/man/index.html +++ b/man/index.html @@ -59,8 +59,8 @@ Description of corosync-notifyd tool. <br> - <a href="corosync-objctl.8.html">corosync-objctl(8)</a>: - Description of corosync-objctl tool. + <a href="corosync-cmapctl.8.html">corosync-cmapctl(8)</a>: + Description of corosync-cmapctl tool. <br> <a href="corosync-pload.8.html">corosync-pload(8)</a>: diff --git a/tools/.gitignore b/tools/.gitignore index 88e7313..2d9fa0f 100644 --- a/tools/.gitignore +++ b/tools/.gitignore @@ -2,7 +2,6 @@ corosync-cfgtool corosync-cpgtool corosync-fplay corosync-keygen -corosync-objctl corosync-pload corosync-quorumtool corosync-notifyd diff --git a/tools/corosync-blackbox b/tools/corosync-blackbox index b1c27ec..15a97e3 100755 --- a/tools/corosync-blackbox +++ b/tools/corosync-blackbox @@ -29,7 +29,7 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF # THE POSSIBILITY OF SUCH DAMAGE. -corosync-objctl -w runtime.blackbox.dump_state=$(date +%s) -corosync-objctl -w runtime.blackbox.dump_flight_data=$(date +%s) +corosync-cmapctl -s runtime.blackbox.dump_state str $(date +%s) +corosync-cmapctl -s runtime.blackbox.dump_flight_data str $(date +%s) corosync-fplay -- 1.7.7.5 _______________________________________________ discuss mailing list discuss@xxxxxxxxxxxx http://lists.corosync.org/mailman/listinfo/discuss