Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Cluster Development (http://www.linux-archive.org/cluster-development/)
-   -   conga ./clustermon.spec.in.in ./conga.spec.in. ... (http://www.linux-archive.org/cluster-development/53804-conga-clustermon-spec-conga-spec.html)

02-12-2008 04:40 PM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL5
Changes by: rmccabe@sourceware.org 2008-02-12 17:40:39

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
make : version.in
ricci/modules/cluster: ClusterStatus.cpp
ricci/modules/log: LogParser.cpp
ricci/modules/rpm: PackageHandler.cpp
ricci/modules/service: ServiceManager.cpp

Log message:
Fix 432533 and 432534

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&only_wi th_tag=RHEL5&r1=1.18.2.31&r2=1.18.2.32
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&only_with_ta g=RHEL5&r1=1.45.2.68&r2=1.45.2.69
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/make/version.in.diff?cvsroot=cluster&only_with_tag=RHEL 5&r1=1.21.2.33&r2=1.21.2.34
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/cluster/ClusterStatus.cpp.diff?cvsroot=cluster&only_with_t ag=RHEL5&r1=1.15.2.5&r2=1.15.2.6
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/log/LogParser.cpp.diff?cvsroot=cluster&only_with_tag=R HEL5&r1=1.6.2.5&r2=1.6.2.6
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/rpm/PackageHandler.cpp.diff?cvsroot=cluster&only_with_ tag=RHEL5&r1=1.9.2.7&r2=1.9.2.8
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/service/ServiceManager.cpp.diff?cvsroot=cluster&only_with_ tag=RHEL5&r1=1.5.2.5&r2=1.5.2.6

--- conga/clustermon.spec.in.in 2008/01/29 22:02:12 1.18.2.31
+++ conga/clustermon.spec.in.in 2008/02/12 17:40:38 1.18.2.32
@@ -193,6 +193,9 @@


%changelog
+* Tue Feb 12 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-5
+- Fix bz432534 (clustermon should not attempt to start or stop the cmirror service)
+
* Mon Jan 28 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-2
- Run the cmirror init script when starting cluster nodes that use shared storage.
- Related: bz430737
--- conga/conga.spec.in.in 2008/02/08 21:56:33 1.45.2.68
+++ conga/conga.spec.in.in 2008/02/12 17:40:38 1.45.2.69
@@ -292,6 +292,9 @@

### changelog ###
%changelog
+* Tue Feb 12 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-5
+- Fix bz432533 (Do not attempt to install the cmirror package when shared storage is requested)
+
* Fri Feb 08 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-4
- Fix bz429151 ([RFE] Luci: increase min password length to 6 characters)
- Fix bz429152 ([RFE] add inactivity timeout)
--- conga/make/version.in 2008/02/08 21:59:48 1.21.2.33
+++ conga/make/version.in 2008/02/12 17:40:38 1.21.2.34
@@ -1,2 +1,2 @@
VERSION=0.12.0
-RELEASE=4
+RELEASE=5
--- conga/ricci/modules/cluster/ClusterStatus.cpp 2008/01/29 22:02:12 1.15.2.5
+++ conga/ricci/modules/cluster/ClusterStatus.cpp 2008/02/12 17:40:38 1.15.2.6
@@ -263,7 +263,6 @@

if (use_qdisk)
run_initd("qdiskd", true, false);
- run_initd("cmirror", true, false);
run_initd("clvmd", true, false);
run_initd("gfs", true, false);
run_initd("gfs2", true, false);
@@ -276,7 +275,6 @@
run_chkconfig("qdiskd", true);
else
run_chkconfig("qdiskd", false);
- run_chkconfig("cmirror", true);
run_chkconfig("clvmd", true);
run_chkconfig("gfs", true);
run_chkconfig("gfs2", true);
--- conga/ricci/modules/log/LogParser.cpp 2008/01/29 22:02:13 1.6.2.5
+++ conga/ricci/modules/log/LogParser.cpp 2008/02/12 17:40:38 1.6.2.6
@@ -47,7 +47,6 @@
"lock_gulmd_LTPX",
"cman",
"cman_tool",
- "cmirror",
"ccs",
"ccs_tool",
"ccsd",
@@ -83,7 +82,6 @@
"lvm",
"clvm",
"clvmd",
- "cmirror",
"end_request",
"buffer",
"scsi",
--- conga/ricci/modules/rpm/PackageHandler.cpp 2008/01/29 22:02:13 1.9.2.7
+++ conga/ricci/modules/rpm/PackageHandler.cpp 2008/02/12 17:40:39 1.9.2.8
@@ -507,7 +507,6 @@
set.packages.push_back("gfs2-utils");
if (RHEL5) {
set.packages.push_back("gfs-utils");
- set.packages.push_back("cmirror");
if (kernel.find("xen") == kernel.npos) {
set.packages.push_back("kmod-gfs");
set.packages.push_back("kmod-gfs2");
--- conga/ricci/modules/service/ServiceManager.cpp 2008/01/29 22:02:13 1.5.2.5
+++ conga/ricci/modules/service/ServiceManager.cpp 2008/02/12 17:40:39 1.5.2.6
@@ -522,8 +522,6 @@
} else if (RHEL5 || FC6) {
descr = "Shared Storage: clvmd, gfs, gfs2";
servs.push_back("clvmd");
- if (RHEL5)
- servs.push_back("cmirror");
servs.push_back("gfs");
servs.push_back("gfs2");
}

04-07-2008 08:11 PM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL4
Changes by: rmccabe@sourceware.org 2008-04-07 20:11:44

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
make : version.in

Log message:
- Update changelogs
- Bump version

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&only_wi th_tag=RHEL4&r1=1.25.2.10&r2=1.25.2.11
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&only_with_ta g=RHEL4&r1=1.67.2.21&r2=1.67.2.22
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/make/version.in.diff?cvsroot=cluster&only_with_tag=RHEL 4&r1=1.28.2.9&r2=1.28.2.10

--- conga/clustermon.spec.in.in 2008/01/02 22:45:31 1.25.2.10
+++ conga/clustermon.spec.in.in 2008/04/07 20:11:44 1.25.2.11
@@ -195,6 +195,10 @@


%changelog
+* Tue Mar 25 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.1-1
+- Fix bz441376 (modclusterd segfaults during startup)
+- Backport fixes from RHEL5
+
* Wed Jan 02 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.0-4
- Fix bz426189 (Conga attempts to free a null pointer)
- Resolves: bz426189
--- conga/conga.spec.in.in 2008/03/25 17:12:18 1.67.2.21
+++ conga/conga.spec.in.in 2008/04/07 20:11:44 1.67.2.22
@@ -319,6 +319,11 @@

%changelog
* Tue Mar 25 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.1-1
+- Fix bz349561 (Add Conga support for Oracle Resource Agent)
+- Fix bz369131 (RFE: should only have to enter a system's password once)
+- Fix bz333181 (Add option to not fail-back service)
+- Fix bz295781 (RFE: add ability to set self_fence attribute for clusterfs resources)
+- Fix bz253904 (Quorum disk page: Interval + tko should be together)
- Backport fixes from RHEL5

* Fri Oct 19 2007 Ryan McCabe <rmccabe@redhat.com> 0.11.0-3
--- conga/make/version.in 2008/01/02 22:45:33 1.28.2.9
+++ conga/make/version.in 2008/04/07 20:11:44 1.28.2.10
@@ -1,6 +1,2 @@
-VERSION=0.11.0
-RELEASE=4
-# Remove "_UNRELEASED" at release time.
-# Put release num at the beggining,
-# so that after it gets released, it has
-# seniority over UNRELEASED one
+VERSION=0.11.1
+RELEASE=1

04-11-2008 06:48 AM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL4
Changes by: rmccabe@sourceware.org 2008-04-11 06:48:11

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
luci/cluster : fence-macros
luci/site/luci/Extensions: StorageReport.py

Log message:
Fix bz441574 (nodename" field for fence_scsi disabled when adding a new fence device/instance)

Sync up spec files' %pre and %post sections with RHEL5.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&only_wi th_tag=RHEL4&r1=1.25.2.11&r2=1.25.2.12
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&only_with_ta g=RHEL4&r1=1.67.2.22&r2=1.67.2.23
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/fence-macros.diff?cvsroot=cluster&only_with_tag=RHEL4&r1 =1.2.4.1&r2=1.2.4.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/StorageReport.py.diff?cvsroot=cluster&only_with_ta g=RHEL4&r1=1.22.2.4&r2=1.22.2.5

--- conga/clustermon.spec.in.in 2008/04/07 20:11:44 1.25.2.11
+++ conga/clustermon.spec.in.in 2008/04/11 06:48:09 1.25.2.12
@@ -1,20 +1,18 @@
-################################################## #############################
-################################################## #############################
-##
-## Copyright (C) 2006-2007 Red Hat, Inc. All rights reserved.
-##
-## This copyrighted material is made available to anyone wishing to use,
-## modify, copy, or redistribute it subject to the terms and conditions
-## of the GNU General Public License v.2.
-##
-################################################## #############################
+################################################# #############################
+#
+# Copyright (C) 2006-2008 Red Hat, Inc. All rights reserved.
+#
+# This copyrighted material is made available to anyone wishing to use,
+# modify, copy, or redistribute it subject to the terms and conditions
+# of the GNU General Public License version 2.
+#
################################################## #############################


%define PEGASUS_PROVIDERS_DIR %{_libdir}/Pegasus/providers


-############ SRPM ###################
+############ SRPM ###################


Name: clustermon
@@ -60,7 +58,7 @@



-### cluster module ###
+### cluster module ###


%package -n modcluster
@@ -91,31 +89,32 @@

%post -n modcluster
/sbin/chkconfig --add modclusterd
-DBUS_PID=`cat /var/run/messagebus.pid 2> /dev/null`
-/bin/kill -s SIGHUP $DBUS_PID > /dev/null 2>&1
+DBUS_PID=`cat /var/run/messagebus.pid 2>/dev/null`
+/bin/kill -s SIGHUP $DBUS_PID >&/dev/null
# It's ok if this fails (it will fail when oddjob is not running).
-/sbin/service oddjobd reload > /dev/null 2>&1 || true
+/sbin/service oddjobd reload >&/dev/null
+exit 0

%preun -n modcluster
if [ "$1" == "0" ]; then
- /sbin/service modclusterd stop > /dev/null 2>&1
+ /sbin/service modclusterd stop >&/dev/null
/sbin/chkconfig --del modclusterd
fi
+exit 0

%postun -n modcluster
if [ "$1" == "0" ]; then
DBUS_PID=`cat /var/run/messagebus.pid 2> /dev/null`
- /bin/kill -s SIGHUP $DBUS_PID > /dev/null 2>&1
- /sbin/service oddjobd reload > /dev/null 2>&1
+ /bin/kill -s SIGHUP $DBUS_PID >&/dev/null
+ /sbin/service oddjobd reload >&/dev/null
fi
if [ "$1" == "1" ]; then
- /sbin/service modclusterd condrestart > /dev/null 2>&1
+ /sbin/service modclusterd condrestart >&/dev/null
fi
+exit 0


-
-
-### cluster-snmp ###
+### cluster-snmp ###


%package -n cluster-snmp
@@ -140,20 +139,19 @@
%{_docdir}/cluster-snmp-%{version}/

%post -n cluster-snmp
-/sbin/service snmpd condrestart > /dev/null 2>&1 || true
+/sbin/service snmpd condrestart >&/dev/null
+exit 0

%postun -n cluster-snmp
# don't restart snmpd twice on upgrades
if [ "$1" == "0" ]; then
- /sbin/service snmpd condrestart > /dev/null 2>&1
+ /sbin/service snmpd condrestart >&/dev/null
fi
+exit 0



-
-
-### cluster-cim ###
-
+### cluster-cim ###

%package -n cluster-cim
Group: System Environment/Base
@@ -176,12 +174,13 @@

%post -n cluster-cim
# pegasus might not be running, don't fail %post
-/sbin/service tog-pegasus condrestart > /dev/null 2>&1 || true
+/sbin/service tog-pegasus condrestart >&/dev/null
+exit 0

%postun -n cluster-cim
# don't restart pegasus twice on upgrades
if [ "$1" == "0" ]; then
- /sbin/service tog-pegasus condrestart > /dev/null 2>&1
+ /sbin/service tog-pegasus condrestart >&/dev/null
fi
# pegasus might not be running, don't fail %postun
exit 0
--- conga/conga.spec.in.in 2008/04/07 20:11:44 1.67.2.22
+++ conga/conga.spec.in.in 2008/04/11 06:48:10 1.67.2.23
@@ -1,22 +1,18 @@
################################################## #############################
-################################################## #############################
-##
-## Copyright (C) 2006-2007 Red Hat, Inc. All rights reserved.
-##
-## This copyrighted material is made available to anyone wishing to use,
-## modify, copy, or redistribute it subject to the terms and conditions
-## of the GNU General Public License v.2.
-##
-################################################## #############################
+#
+# Copyright (C) 2006-2008 Red Hat, Inc. All rights reserved.
+#
+# This copyrighted material is made available to anyone wishing to use,
+# modify, copy, or redistribute it subject to the terms and conditions
+# of the GNU General Public License version 2.
+#
################################################## #############################


%define include_zope_and_plone @@INCLUDE_ZOPE_AND_PLONE@@


-
-############ SRPM ###################
-
+############ SRPM ###################

Name: conga
Version: @@VERS@@
@@ -42,13 +38,11 @@
BuildRequires: cyrus-sasl-devel >= 2.1
BuildRequires: openssl-devel dbus-devel pkgconfig file

-
%description
Conga is a project developing management system for remote stations.
It consists of luci, https frontend, and ricci, secure daemon that dispatches
incoming messages to underlying management modules.

-
%prep
%setup -q
%if "%{include_zope_and_plone}" == "yes"
@@ -81,13 +75,7 @@
rm -rf $RPM_BUILD_ROOT


-
-
-
-
-
-####### luci #######
-
+####### luci #######

%package -n luci

@@ -112,14 +100,12 @@
Requires(post): chkconfig initscripts
Requires(preun): chkconfig initscripts

-
%description -n luci
Conga is a project developing management system for remote stations.
It consists of luci, https frontend, and ricci, secure daemon that
dispatches incoming messages to underlying management modules.

-This package contains Luci website.
-
+This package contains the luci server.

%files -n luci
%verify(not size md5 mtime) /var/lib/luci/var/Data.fs
@@ -138,12 +124,12 @@
%endif

%pre -n luci
-grep ^luci:x /etc/group >&/dev/null
-if [ $? -ne 0 ]; then
+groupmod luci >&/dev/null
+if [ $? -eq 6 ]; then
/usr/sbin/groupadd -r -f luci >&/dev/null
fi

-grep ^luci:x /etc/passwd >&/dev/null
+id luci >&/dev/null
if [ $? -ne 0 ]; then
/usr/sbin/useradd -r -M -s /sbin/nologin -d /var/lib/luci -g luci luci >&/dev/null
fi
@@ -159,7 +145,7 @@
fi
/usr/sbin/luci_admin backup >&/dev/null
if [ $LUCI_RUNNING -eq 0 ]; then
- /sbin/service luci start >& /dev/null
+ /sbin/service luci start >&/dev/null
fi
fi
exit 0
@@ -206,10 +192,8 @@
exit 0


-
### ricci daemon & basic modules ###

-
%package -n ricci

Group: System Environment/Base
@@ -232,7 +216,6 @@

# modlog

-
Requires(pre): grep shadow-utils
Requires(post): chkconfig initscripts util-linux
Requires(preun): chkconfig initscripts
@@ -246,7 +229,6 @@
This package contains listening daemon (dispatcher), as well as
reboot, rpm, storage, service and log management modules.

-
%files -n ricci
%defattr(-,root,root)
# ricci
@@ -318,7 +300,8 @@


%changelog
-* Tue Mar 25 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.1-1
+* Tue Mar 25 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.1-2
+- Fix bz441574 (nodename" field for fence_scsi disabled when adding a new fence device/instance)
- Fix bz349561 (Add Conga support for Oracle Resource Agent)
- Fix bz369131 (RFE: should only have to enter a system's password once)
- Fix bz333181 (Add option to not fail-back service)
--- conga/luci/cluster/fence-macros 2008/03/25 01:27:10 1.2.4.1
+++ conga/luci/cluster/fence-macros 2008/04/11 06:48:10 1.2.4.2
@@ -1849,7 +1849,7 @@
<tr>
<td>Node name</td>
<td>
- <input type="text" name="node" disabled="disabled"
+ <input type="text" name="node"
tal:attributes="value request/node | nothing" />
</td>
</tr>
--- conga/luci/site/luci/Extensions/StorageReport.py 2008/03/25 01:27:12 1.22.2.4
+++ conga/luci/site/luci/Extensions/StorageReport.py 2008/04/11 06:48:11 1.22.2.5
@@ -1,4 +1,4 @@
-# Copyright (C) 2006-2007 Red Hat, Inc.
+# Copyright (C) 2006-2008 Red Hat, Inc.
#
# This program is free software; you can redistribute
# it and/or modify it under the terms of version 2 of the

04-11-2008 06:54 AM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL5
Changes by: rmccabe@sourceware.org 2008-04-11 06:54:44

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
make : version.in

Log message:
Update changelogs and bump the version

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&only_wi th_tag=RHEL5&r1=1.18.2.36&r2=1.18.2.37
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&only_with_ta g=RHEL5&r1=1.45.2.76&r2=1.45.2.77
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/make/version.in.diff?cvsroot=cluster&only_with_tag=RHEL 5&r1=1.21.2.36&r2=1.21.2.37

--- conga/clustermon.spec.in.in 2008/03/31 17:23:45 1.18.2.36
+++ conga/clustermon.spec.in.in 2008/04/11 06:54:43 1.18.2.37
@@ -212,6 +212,9 @@


%changelog
+* Thu Apr 10 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-8
+- Fix bz441947 (cluster-snmp dlopen failure)
+
* Thu Mar 27 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-7
- Fix bz439186

--- conga/conga.spec.in.in 2008/04/11 06:50:32 1.45.2.76
+++ conga/conga.spec.in.in 2008/04/11 06:54:43 1.45.2.77
@@ -291,7 +291,7 @@

### changelog ###
%changelog
-* Thu Apr 10 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-7
+* Thu Apr 10 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-8
- Fix bz441573 ("nodename" field for fence_scsi disabled when adding a new fence device/instance)

* Wed Feb 27 2008 Ryan McCabe <rmccabe@redhat.com> 0.12.0-6
--- conga/make/version.in 2008/03/28 01:15:16 1.21.2.36
+++ conga/make/version.in 2008/04/11 06:54:43 1.21.2.37
@@ -1,2 +1,2 @@
VERSION=0.12.0
-RELEASE=7
+RELEASE=8

04-18-2008 03:31 AM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL4
Changes by: rmccabe@sourceware.org 2008-04-18 03:31:46

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
luci/cluster : fence-macros validate_fence.js
luci/site/luci/Extensions: FenceHandler.py

Log message:
Fix bz442933 (Luci inserts "hostname" instead of "ipaddr" for rsa II fencing device)

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&only_wi th_tag=RHEL4&r1=1.25.2.13&r2=1.25.2.14
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&only_with_ta g=RHEL4&r1=1.67.2.24&r2=1.67.2.25
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/fence-macros.diff?cvsroot=cluster&only_with_tag=RHEL4&r1 =1.2.4.3&r2=1.2.4.4
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/validate_fence.js.diff?cvsroot=cluster&only_with_t ag=RHEL4&r1=1.3.2.5&r2=1.3.2.6
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/FenceHandler.py.diff?cvsroot=cluster&only_with_tag =RHEL4&r1=1.17.2.7&r2=1.17.2.8

--- conga/clustermon.spec.in.in 2008/04/14 17:17:29 1.25.2.13
+++ conga/clustermon.spec.in.in 2008/04/18 03:31:46 1.25.2.14
@@ -194,6 +194,9 @@


%changelog
+* Tue Apr 15 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.1-3
+- Fix bz441966 (cluster-snmp dlopen failure)
+
* Tue Mar 25 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.1-2
- Fix bz441376 (modclusterd segfaults during startup)
- Backport fixes from RHEL5
--- conga/conga.spec.in.in 2008/04/14 15:55:08 1.67.2.24
+++ conga/conga.spec.in.in 2008/04/18 03:31:46 1.67.2.25
@@ -301,6 +301,7 @@

%changelog
* Tue Mar 25 2008 Ryan McCabe <rmccabe@redhat.com> 0.11.1-2
+- Fix bz442933 (Luci inserts "hostname" instead of "ipaddr" for rsa II fencing device)
- Fix bz442369 (conga should install 'sg3_utils' and start service 'scsi_reserve' when scsi fencing is used)
- Fix bz441574 (nodename" field for fence_scsi disabled when adding a new fence device/instance)
- Fix bz349561 (Add Conga support for Oracle Resource Agent)
--- conga/luci/cluster/fence-macros 2008/04/11 22:43:17 1.2.4.3
+++ conga/luci/cluster/fence-macros 2008/04/18 03:31:46 1.2.4.4
@@ -188,6 +188,10 @@
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-rsa" />
</tal:block>

+ <tal:block tal:condition="python: cur_fence_type == 'fence_rsb'">
+ <tal:block metal:use-macro="here/fence-macros/macros/fence-form-rsb" />
+ </tal:block>
+
<tal:block tal:condition="python: cur_fence_type == 'fence_brocade'">
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-brocade" />
</tal:block>
@@ -329,6 +333,7 @@
<option name="fence_egenera" value="fence_egenera">Egenera SAN Controller</option>
<option name="fence_ilo" value="fence_ilo">HP iLO</option>
<option name="fence_rsa" value="fence_rsa">IBM RSA II</option>
+ <option name="fence_rsb" value="fence_rsb">Fujitsu Siemens RSB</option>
<option name="fence_bladecenter" value="fence_bladecenter">IBM Blade Center</option>
<option name="fence_bullpap" value="fence_bullpap">Bull PAP</option>
<option name="fence_rps10" value="fence_rps10">RPS10 Serial Switch</option>
@@ -701,8 +706,8 @@
<tr>
<td>Hostname</td>
<td>
- <input name="hostname" type="text"
- tal:attributes="value cur_fencedev/hostname | nothing" />
+ <input name="ipaddr" type="text"
+ tal:attributes="value cur_fencedev/ipaddr | nothing" />
</td>
</tr>
<tr>
@@ -742,6 +747,66 @@
</div>
</div>

+<div metal:define-macro="fence-form-rsb"
+ tal:attributes="id cur_fencedev/name | nothing">
+
+ <div id="fence_rsb" class="fencedev">
+ <table>
+ <tr>
+ <td><strong class="cluster">Fence Type</strong></td>
+ <td>Fujitsu Siemens RemoteView Service Board (RSB)</td>
+ </tr>
+ <tr>
+ <td>Name</td>
+ <td>
+ <input name="name" type="text"
+ tal:attributes="value cur_fencedev/name | nothing" />
+ </td>
+ </tr>
+ <tr>
+ <td>Hostname</td>
+ <td>
+ <input name="ipaddr" type="text"
+ tal:attributes="value cur_fencedev/ipaddr | nothing" />
+ </td>
+ </tr>
+ <tr>
+ <td>Login</td>
+ <td>
+ <input name="login" type="text"
+ tal:attributes="value cur_fencedev/login | nothing" />
+ </td>
+ </tr>
+ <tr>
+ <td>Password</td>
+ <td>
+ <input name="passwd" type="password" autocomplete="off"
+ tal:attributes="value nothing" />
+ </td>
+ </tr>
+ <tr>
+ <td>
+ <span title="Full path to a script to generate fence password">Password Script (optional)</span>
+ </td>
+ <td>
+ <input type="text" name="passwd_script"
+ tal:attributes="
+ disabled cur_fencedev/isShared | nothing;
+ value cur_fencedev/passwd_script | nothing" />
+ </td>
+ </tr>
+ </table>
+
+ <tal:block tal:condition="exists: cur_fencedev">
+ <input type="hidden" name="existing_device" value="1" />
+ <input type="hidden" name="orig_name"
+ tal:attributes="value cur_fencedev/name | nothing" />
+ </tal:block>
+
+ <input type="hidden" name="fence_type" value="fence_rsb" />
+ </div>
+</div>
+
<div metal:define-macro="fence-form-brocade"
tal:attributes="id cur_fencedev/name | nothing">

@@ -1376,6 +1441,7 @@
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-ilo" />
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-drac" />
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-rsa" />
+ <tal:block metal:use-macro="here/fence-macros/macros/fence-form-rsb" />
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-brocade" />
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-sanbox2" />
<tal:block metal:use-macro="here/fence-macros/macros/fence-form-vixel" />
--- conga/luci/cluster/validate_fence.js 2008/03/25 01:27:10 1.3.2.5
+++ conga/luci/cluster/validate_fence.js 2008/04/18 03:31:46 1.3.2.6
@@ -34,7 +34,8 @@
fence_validator['manual'] = [];
fence_validator['mcdata'] = [ 'ipaddr', 'login', 'passwd', 'passwd_script' ];
fence_validator['rps10'] = [ 'device', 'port'];
-fence_validator['rsa'] = [ 'hostname', 'login', 'passwd', 'passwd_script' ];
+fence_validator['rsa'] = [ 'ipaddr', 'login', 'passwd', 'passwd_script' ];
+fence_validator['rsb'] = [ 'ipaddr', 'login', 'passwd', 'passwd_script' ];
fence_validator['sanbox2'] = [ 'ipaddr', 'login', 'passwd', 'passwd_script' ];
fence_validator['scsi'] = [];
fence_validator['unknown'] = [];
--- conga/luci/site/luci/Extensions/FenceHandler.py 2008/03/25 01:27:11 1.17.2.7
+++ conga/luci/site/luci/Extensions/FenceHandler.py 2008/04/18 03:31:46 1.17.2.8
@@ -543,10 +543,10 @@
errors = list()

try:
- hostname = form['hostname'].strip()
+ hostname = form['ipaddr'].strip()
if not hostname:
raise Exception, 'blank'
- fencedev.addAttribute('hostname', hostname)
+ fencedev.addAttribute('ipaddr', hostname)
except Exception, e:
errors.append(FD_PROVIDE_HOSTNAME)

@@ -822,6 +822,7 @@
'fence_ipmilan': val_ipmilan_fd,
'fence_drac': val_drac_fd,
'fence_rsa': val_rsa_fd,
+ 'fence_rsb': val_rsa_fd, # same params as rsa
'fence_rps10': val_rps10_fd,
'fence_manual': val_noop_fd
}
@@ -1082,6 +1083,7 @@
'fence_ipmilan': val_noop_fi,
'fence_drac': val_noop_fi,
'fence_rsa': val_noop_fi,
+ 'fence_rsb': val_noop_fi,
'fence_rps10': val_noop_fi
}

05-12-2008 03:13 PM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL5
Changes by: rmccabe@sourceware.org 2008-05-12 15:13:33

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
luci/site/luci/Extensions: ricci_communicator.py
make : version.in
ricci/common : File.cpp Variable.cpp daemon_init.c utils.cpp
ricci/include : shred_allocator.h
ricci/init.d : ricci
ricci/modules/cluster/clumon: Makefile
ricci/modules/cluster/clumon/init.d: modclusterd
ricci/modules/cluster/clumon/src/common: Cluster.cpp
ricci/modules/storage: ContentFS.cpp ExtendedFS.cpp LV.cpp
Mapper.cpp MountHandler.cpp PTSource.cpp
PV.cpp Partition.cpp PartitionTable.cpp
parted_wrapper.cpp

Log message:
Fixes from HEAD

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&only_wi th_tag=RHEL5&r1=1.18.2.37&r2=1.18.2.38
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&only_with_ta g=RHEL5&r1=1.45.2.84&r2=1.45.2.85
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/ricci_communicator.py.diff?cvsroot=cluster&only_wi th_tag=RHEL5&r1=1.9.2.14&r2=1.9.2.15
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/make/version.in.diff?cvsroot=cluster&only_with_tag=RHEL 5&r1=1.21.2.38&r2=1.21.2.39
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/common/File.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5& r1=1.1.2.4&r2=1.1.2.5
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/common/Variable.cpp.diff?cvsroot=cluster&only_with_tag=RH EL5&r1=1.8.2.1&r2=1.8.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/common/daemon_init.c.diff?cvsroot=cluster&only_with_tag=R HEL5&r1=1.1.2.1&r2=1.1.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/common/utils.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5 &r1=1.6.2.2&r2=1.6.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/include/shred_allocator.h.diff?cvsroot=cluster&only_with_t ag=RHEL5&r1=1.2.2.1&r2=1.2.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/init.d/ricci.diff?cvsroot=cluster&only_with_tag=RHEL5&r1= 1.8.2.4&r2=1.8.2.5
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/cluster/clumon/Makefile.diff?cvsroot=cluster&only_with_tag=RHEL5& r1=1.4.2.2&r2=1.4.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/cluster/clumon/init.d/modclusterd.diff?cvsroot=cluster&only_with_tag=RHE L5&r1=1.2.2.2&r2=1.2.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/cluster/clumon/src/common/Cluster.cpp.diff?cvsroot=cluster&only_with_tag=RHE L5&r1=1.6.2.2&r2=1.6.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/ContentFS.cpp.diff?cvsroot=cluster&only_with_tag=R HEL5&r1=1.5.2.1&r2=1.5.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/ExtendedFS.cpp.diff?cvsroot=cluster&only_with_tag= RHEL5&r1=1.7.2.2&r2=1.7.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/LV.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5&r1 =1.6.2.4&r2=1.6.2.5
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/Mapper.cpp.diff?cvsroot=cluster&only_with_tag=RHEL 5&r1=1.3.2.1&r2=1.3.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/MountHandler.cpp.diff?cvsroot=cluster&only_with_ta g=RHEL5&r1=1.5.2.2&r2=1.5.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/PTSource.cpp.diff?cvsroot=cluster&only_with_tag=RH EL5&r1=1.2.2.1&r2=1.2.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/PV.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5&r1 =1.4.2.3&r2=1.4.2.4
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/Partition.cpp.diff?cvsroot=cluster&only_with_tag=R HEL5&r1=1.3.2.1&r2=1.3.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/PartitionTable.cpp.diff?cvsroot=cluster&only_with_ tag=RHEL5&r1=1.5.2.1&r2=1.5.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/parted_wrapper.cpp.diff?cvsroot=cluster&only_with_ tag=RHEL5&r1=1.8.2.4&r2=1.8.2.5

--- conga/clustermon.spec.in.in 2008/04/11 06:54:43 1.18.2.37
+++ conga/clustermon.spec.in.in 2008/05/12 15:13:31 1.18.2.38
@@ -18,7 +18,7 @@
Name: clustermon
Version: @@VERS@@
Release: @@REL@@%{?dist}
-License: GPL
+License: GPLv2
URL: http://sources.redhat.com/cluster/conga

Group: System Environment/Base
@@ -67,12 +67,11 @@
make %{?_smp_mflags} clustermon

%install
-rm -rf $RPM_BUILD_ROOT
-make DESTDIR=$RPM_BUILD_ROOT install_clustermon
+rm -rf %{buildroot}
+make DESTDIR=%{buildroot} install_clustermon

%clean
-rm -rf $RPM_BUILD_ROOT
-
+rm -rf %{buildroot}



@@ -191,7 +190,7 @@
%{_docdir}/cluster-cim-%{version}/

%post -n cluster-cim
-# pegasus might not be running, don't fail %post
+# pegasus might not be running, don't fail
/sbin/service tog-pegasus condrestart >&/dev/null
exit 0

@@ -200,7 +199,7 @@
if [ "$1" == "0" ]; then
/sbin/service tog-pegasus condrestart >&/dev/null
fi
-# pegasus might not be running, don't fail %postun
+# pegasus might not be running, don't fail
exit 0


--- conga/conga.spec.in.in 2008/04/28 03:54:18 1.45.2.84
+++ conga/conga.spec.in.in 2008/05/12 15:13:32 1.45.2.85
@@ -62,11 +62,11 @@
make %{?_smp_mflags} conga

%install
-rm -rf $RPM_BUILD_ROOT
-make DESTDIR=$RPM_BUILD_ROOT install_conga
+rm -rf %{buildroot}
+make DESTDIR=%{buildroot} install_conga

%clean
-rm -rf $RPM_BUILD_ROOT
+rm -rf %{buildroot}


####### luci #######
--- conga/luci/site/luci/Extensions/ricci_communicator.py 2008/01/23 04:44:32 1.9.2.14
+++ conga/luci/site/luci/Extensions/ricci_communicator.py 2008/05/12 15:13:32 1.9.2.15
@@ -169,7 +169,7 @@
luci_log.debug_net('RC:UNAUTH0: unauthenticate %s for %s:%d'
% (ret, self.__hostname, self.__port))
if ret != '0':
- raise Exception, 'Invalid response'
+ raise Exception, 'Invalid response: %s' % ret

try:
self.ss.untrust()
@@ -494,7 +494,7 @@
% batch_xml.toxml())
except:
pass
- raise RicciError, 'Not an XML batch node'
+ raise RicciError, 'Not an XML batch node: %s' % batch_xml.nodeName

total = 0
last = 0
@@ -544,7 +544,7 @@
if LUCI_DEBUG_NET is True:
luci_log.debug_net_priv('RC:EMS0: Expecting "batch" got "%s"'
% batch_xml.toxml())
- raise RicciError, 'Invalid XML node; expecting a batch node'
+ raise RicciError, 'Invalid XML node; expecting a batch node: %s' % batch_xml.nodeName

c = 0
for node in batch_xml.childNodes:
--- conga/make/version.in 2008/04/28 03:54:18 1.21.2.38
+++ conga/make/version.in 2008/05/12 15:13:32 1.21.2.39
@@ -1,2 +1,2 @@
-VERSION=0.12.0
-RELEASE=9
+VERSION=0.14.0
+RELEASE=1
--- conga/ricci/common/File.cpp 2008/01/17 17:38:36 1.1.2.4
+++ conga/ricci/common/File.cpp 2008/05/12 15:13:32 1.1.2.5
@@ -139,17 +139,17 @@
MutexLocker l(*_mutex);

long len = size();
- const auto_ptr<char> buff(new char[len]);
+ char buff[len];
try {
((fstream *) _pimpl->fs)->seekg(0, ios::beg);
check_failed();
- ((fstream *) _pimpl->fs)->read(buff.get(), len);
+ ((fstream *) _pimpl->fs)->read(buff, len);
check_failed();
- String ret(buff.get(), len);
- ::shred(buff.get(), len);
+ String ret(buff, len);
+ ::shred(buff, len);
return ret;
} catch ( ... ) {
- ::shred(buff.get(), len);
+ ::shred(buff, len);
throw;
}
}
--- conga/ricci/common/Variable.cpp 2008/01/17 17:38:36 1.8.2.1
+++ conga/ricci/common/Variable.cpp 2008/05/12 15:13:32 1.8.2.2
@@ -26,6 +26,8 @@

#include <stdio.h>

+#include <vector>
+#include <algorithm>
using namespace std;

// ##### class Variable #####
--- conga/ricci/common/daemon_init.c 2008/01/17 17:38:36 1.1.2.1
+++ conga/ricci/common/daemon_init.c 2008/05/12 15:13:32 1.1.2.2
@@ -20,7 +20,7 @@
/** @file
* daemon_init function, does sanity checks and calls daemon().
*
- * $Id: daemon_init.c,v 1.1.2.1 2008/01/17 17:38:36 rmccabe Exp $
+ * $Id: daemon_init.c,v 1.1.2.2 2008/05/12 15:13:32 rmccabe Exp $
*
* Author: Jeff Moyer <moyer@mclinux.com>
*/
@@ -232,5 +232,4 @@

update_pidfile(prog);
nice(-1);
- //mlockall(MCL_CURRENT | MCL_FUTURE);
}
--- conga/ricci/common/utils.cpp 2008/01/17 17:38:36 1.6.2.2
+++ conga/ricci/common/utils.cpp 2008/05/12 15:13:32 1.6.2.3
@@ -23,8 +23,13 @@
#include "utils.h"
#include "executils.h"

-#include <openssl/md5.h>
+#include <unistd.h>
+#include <stdio.h>
#include <stdlib.h>
+#include <math.h>
+#include <errno.h>
+#include <limits.h>
+#include <openssl/md5.h>

//#include <iostream>

@@ -201,24 +206,44 @@
long long
utils::to_long(const String& str)
{
- return atoll(str.c_str());
+ char *p = NULL;
+ long long ret;
+ ret = strtoll(strip(str).c_str(), &p, 10);
+ if (p != NULL && *p != '')
+ throw String("Not a number: ") + str;
+ if (ret == LLONG_MIN && errno == ERANGE)
+ throw String("Numeric underflow: ") + str;
+ if (ret == LLONG_MAX && errno == ERANGE)
+ throw String("Numeric overflow: ") + str;
+ return ret;
}

float
utils::to_float(const String& str)
{
- float num = 0;
+ char *p = NULL;
+ float ret;

- sscanf(strip(str).c_str(), "%f", &num);
- return num;
+ ret = strtof(strip(str).c_str(), &p);
+ if (p != NULL && *p == '')
+ throw String("Invalid floating point number: ") + str;
+ if (ret == 0 && errno == ERANGE)
+ throw String("Floating point underflow: ") + str;
+ if ((ret == HUGE_VALF || ret == HUGE_VALL) && errno == ERANGE)
+ throw String("Floating point overflow: ") + str;
+
+ return ret;
}

String
utils::to_string(int value)
{
char tmp[64];
+ int ret;

- sprintf(tmp, "%d", value);
+ ret = snprintf(tmp, sizeof(tmp), "%d", value);
+ if (ret < 0 || (size_t) ret >= sizeof(tmp))
+ throw String("Invalid integer");
return tmp;
}

@@ -226,8 +251,11 @@
utils::to_string(long value)
{
char tmp[64];
+ int ret;

- sprintf(tmp, "%ld", value);
+ ret = snprintf(tmp, sizeof(tmp), "%ld", value);
+ if (ret < 0 || (size_t) ret >= sizeof(tmp))
+ throw String("Invalid long integer");
return tmp;
}

@@ -235,8 +263,11 @@
utils::to_string(long long value)
{
char tmp[64];
+ int ret;

- sprintf(tmp, "%lld", value);
+ ret = snprintf(tmp, sizeof(tmp), "%lld", value);
+ if (ret < 0 || (size_t) ret >= sizeof(tmp))
+ throw String("Invalid long long integer");
return tmp;
}

--- conga/ricci/include/shred_allocator.h 2008/01/17 17:38:37 1.2.2.1
+++ conga/ricci/include/shred_allocator.h 2008/05/12 15:13:32 1.2.2.2
@@ -33,6 +33,12 @@
#ifndef __CONGA_SHRED_ALLOCATOR_H
#define __CONGA_SHRED_ALLOCATOR_H

+extern "C" {
+ #include <unistd.h>
+ #include <stdlib.h>
+ #include <string.h>
+}
+
#include <new>

template<typename _Tp>
--- conga/ricci/init.d/ricci 2008/01/17 17:38:37 1.8.2.4
+++ conga/ricci/init.d/ricci 2008/05/12 15:13:32 1.8.2.5
@@ -53,103 +53,159 @@
{
rm -f "$SSL_PUBKEY" "$SSL_PRIVKEY"
echo -n "generating SSL certificates... "
- /usr/bin/openssl genrsa -out "$SSL_PRIVKEY" 2048 >&/dev/null
- /usr/bin/openssl req -new -x509 -key "$SSL_PRIVKEY" -out "$SSL_PUBKEY" -days 1825 -config /var/lib/ricci/certs/cacert.config
- /bin/chown $RUNASUSER:$RUNASUSER "$SSL_PRIVKEY" "$SSL_PUBKEY"
+ /usr/bin/openssl genrsa -out "$SSL_PRIVKEY" 2048 >&/dev/null &&
+ /usr/bin/openssl req -new -x509 -key "$SSL_PRIVKEY" -out "$SSL_PUBKEY" -days 1825 -config /var/lib/ricci/certs/cacert.config &&
+ /bin/chown $RUNASUSER:$RUNASUSER "$SSL_PRIVKEY" "$SSL_PUBKEY" &&
+ /bin/chmod 600 "$SSL_PRIVKEY" &&
/bin/chmod 644 "$SSL_PUBKEY"
- /bin/chmod 600 "$SSL_PRIVKEY"
ret=$?
echo "done"
return $ret
}

+check_ricci_lockfiles() {
+ ricci_status >& /dev/null
+ ret=$?
+ if [ "$ret" -eq 1 ] || [ "$ret" -eq 2 ]; then
+ # stale pid and/or lockfile
+ rm -f -- "$PIDFILE" "$LOCKFILE"
+ fi
+}
+
+ricci_status() {
+ if [ -f "$PIDFILE" ]; then
+ status -p "$PIDFILE" "$RICCID"
+ ricci_up=$?
+ else
+ status "$RICCID"
+ ricci_up=$?
+ fi
+ return $ricci_up
+}
+
+ricci_stop() {
+ ricci_status >& /dev/null
+ ret=$?
+
+ if [ "$ret" -ne 0 ]; then
+ # already stopped - no error
+ check_ricci_lockfiles
+ return 0
+ fi
+
+ killproc "$RICCID" SIGTERM
+
+ ricci_status >& /dev/null
+ ret=$?
+
+ max_wait=10
+ cur_wait=0
+ while [ "$ret" -eq 0 ] && [ $cur_wait -lt $max_wait ]; do
+ sleep 1
+ cur_wait=`expr $cur_wait + 1`
+ ricci_status >& /dev/null
+ ret=$?
+ done
+
+ ricci_status >& /dev/null
+ ret=$?
+
+ if [ "$ret" -ne 0 ]; then
+ rm -f -- "$PIDFILE" "$LOCKFILE"
+ return 0
+ fi
+
+ return 1
+}

case $1 in
start)
service messagebus status >&/dev/null
- if [ $? -ne 0 ]; then
+ if [ "$?" -ne 0 ]; then
service messagebus start
service messagebus status >&/dev/null
- if [ $? -ne 0 ]; then
- echo "not starting ricci..."
- /usr/bin/logger -t $RICCID "startup failed"
+ if [ "$?" -ne 0 ]; then
+ /usr/bin/logger -t "$RICCID" -- "messagebus startup failed"
+ failure "not starting $RICCID"
exit 1
fi
fi
+
service oddjobd status >&/dev/null
- if [ $? -ne 0 ]; then
+ if [ "$?" -ne 0 ]; then
service oddjobd start
service oddjobd status >&/dev/null
- if [ $? -ne 0 ]; then
- echo "not starting ricci..."
- /usr/bin/logger -t $RICCID "startup failed"
+ if [ "$?" -ne 0 ]; then
+ /usr/bin/logger -t "$RICCID" -- "oddjob startup failed"
+ failure "not starting $RICCID"
exit 1
fi
fi

service saslauthd start >&/dev/null
+
ssl_certs_ok
- if [ "1$?" != "10" ] ; then
+ if [ "$?" -ne 0 ] ; then
generate_ssl_certs
fi

- NewUID=`grep "^$RUNASUSER:" /etc/passwd | sed -e 's/^[^:]*:[^:]*://' -e 's/:.*//'`
+ check_ricci_lockfiles
+ NewUID=`grep "^$RUNASUSER:" /etc/passwd | cut -d: -f3`
echo -n $"Starting $ID: "
- daemon $RICCID -u $NewUID
- rtrn=$?
+ daemon "$RICCID" -u "$NewUID"
echo
+ ret=$?

- if [ $rtrn -eq 0 ]; then
- touch "$LOCKFILE"
- /usr/bin/logger -t $RICCID "startup succeeded"
+ if [ "$ret" -eq 0 ]; then
+ touch -- "$LOCKFILE"
+ /usr/bin/logger -t $RICCID -- "startup succeeded"
else
- /usr/bin/logger -t $RICCID "startup failed"
+ /usr/bin/logger -t $RICCID -- "startup failed"
fi
;;

restart)
$0 stop
$0 start
- rtrn=$?
+ ret=$?
;;

status)
- status $RICCID
- rtrn=$?
+ ricci_status
+ ret=$?
;;

stop)
echo -n "Shutting down $ID: "
- killproc $RICCID SIGTERM
- rtrn=$?
- if [ $rtrn -eq 0 ]; then
- sleep 8
- rm -f $PIDFILE
- rm -f $LOCKFILE
- /usr/bin/logger -t $RICCID "shutdown succeeded"
- rtrn=0
+ ricci_stop
+ ret=$?
+ if [ "$ret" -eq 0 ]; then
+ /usr/bin/logger -t "$RICCID" -- "shutdown succeeded"
else
- /usr/bin/logger -t $RICCID "shutdown failed"
- rtrn=1
+ /usr/bin/logger -t "$RICCID" -- "shutdown failed"
fi
echo
;;

condrestart)
- if [ -f ${PIDFILE} ] ; then
+ if [ -f "$PIDFILE" ]; then
$0 restart
- rtrn=$?
+ ret=$?
fi
;;

+ try-restart)
+ ret=3
+ ;;
+
reload)
- rtrn=3
+ ret=3
;;

*)
echo "Usage: $0 {start|stop|status|restart|condrestart|reload}"
- rtrn=3
+ ret=3
;;
esac

-exit $rtrn
+exit $ret
--- conga/ricci/modules/cluster/clumon/Makefile 2008/01/17 17:38:37 1.4.2.2
+++ conga/ricci/modules/cluster/clumon/Makefile 2008/05/12 15:13:33 1.4.2.3
@@ -11,6 +11,7 @@
top_srcdir=../../..
UNINSTALL=${top_srcdir}/scripts/uninstall.pl

+include ${top_srcdir}/make/version.in
include ${top_srcdir}/make/defines.mk

all:
--- conga/ricci/modules/cluster/clumon/init.d/modclusterd 2008/01/17 17:38:37 1.2.2.2
+++ conga/ricci/modules/cluster/clumon/init.d/modclusterd 2008/05/12 15:13:33 1.2.2.3
@@ -37,66 +37,122 @@
# If we're not configured, then don't start anything.
#
[ "${NETWORKING}" = "yes" ] || exit 1
-#[ -f "$CFG_FILE" ] || exit 0

+modclusterd_status() {
+ if [ -f "$PIDFILE" ]; then
+ status -p "$PIDFILE" "$MODCLUSTERD"
+ ret=$?
+ else
+ status "$MODCLUSTERD"
+ ret=$?
+ fi
+ return $ret
+}
+
+check_modclusterd_lockfiles() {
+ modclusterd_status >& /dev/null
+ ret=$?
+ if [ "$ret" -eq 1 ] || [ "$ret" -eq 2 ]; then
+ # stale pid and/or lockfile
+ rm -f -- "$PIDFILE" "$LOCKFILE"
+ fi
+ return 0
+}
+
+modclusterd_stop() {
+ modclusterd_status >& /dev/null
+ ret=$?
+
+ if [ "$ret" -ne 0 ]; then
+ # already stopped - no error
+ check_modclusterd_lockfiles
+ return 0
+ fi
+
+ killproc "$MODCLUSTERD" SIGTERM
+
+ modclusterd_status >& /dev/null
+ ret=$?
+
+ max_wait=10
+ cur_wait=0
+ while [ "$ret" -eq 0 ] && [ $cur_wait -lt $max_wait ]; do
+ sleep 1
+ cur_wait=`expr $cur_wait + 1`
+ modclusterd_status >& /dev/null
+ ret=$?
+ done
+
+ modclusterd_status >& /dev/null
+ ret=$?
+
+ if [ "$ret" -ne 0 ]; then
+ rm -f -- "$PIDFILE" "$LOCKFILE"
+ return 0
+ fi
+
+ return 1
+}

case $1 in
start)
echo -n $"Starting $ID: "
- daemon $MODCLUSTERD
- rtrn=$?
- if [ $rtrn -eq 0 ]; then
- touch $LOCKFILE
- /usr/bin/logger -t $MODCLUSTERD "startup succeeded"
+ check_modclusterd_lockfiles
+ daemon "$MODCLUSTERD"
+ ret=$?
+ if [ "$ret" -eq 0 ]; then
+ touch -- "$LOCKFILE"
+ /usr/bin/logger -t "$MODCLUSTERD" -- "startup succeeded"
else
- /usr/bin/logger -t $MODCLUSTERD "startup failed"
- rtrn=1
+ /usr/bin/logger -t "$MODCLUSTERD" -- "startup failed"
+ ret=1
fi
echo
;;

restart)
$0 stop
- sleep 8
$0 start
- rtrn=$?
+ ret=$?
;;

status)
- status $MODCLUSTERD
- rtrn=$?
+ modclusterd_status
+ ret=$?
;;

stop)
echo -n "Shutting down $ID: "
- killproc $MODCLUSTERD SIGTERM
- rtrn=$?
- if [ $rtrn -eq 0 ]; then
- rm -f $PIDFILE
- rm -f $LOCKFILE
- /usr/bin/logger -t $MODCLUSTERD "shutdown succeeded"
+ modclusterd_stop
+ ret=$?
+ if [ "$ret" -eq 0 ]; then
+ /usr/bin/logger -t "$MODCLUSTERD" -- "shutdown succeeded"
else
- /usr/bin/logger -t $MODCLUSTERD "shutdown failed"
- rtrn=1
+ /usr/bin/logger -t "$MODCLUSTERD" -- "shutdown failed"
+ ret=1
fi
echo
;;

condrestart)
- if [ -f ${PIDFILE} ] ; then
+ if [ -f "$PIDFILE" ]; then
$0 restart
- rtrn=$?
+ ret=$?
fi
;;

+ try-restart)
+ ret=3
+ ;;
+
reload)
- rtrn=3
+ ret=3
;;

*)
echo $"Usage: $0 {start|stop|reload|restart|status}"
- rtrn=3
+ ret=3
;;
esac

-exit $rtrn
+exit $ret
--- conga/ricci/modules/cluster/clumon/src/common/Cluster.cpp 2008/01/17 17:38:38 1.6.2.2
+++ conga/ricci/modules/cluster/clumon/src/common/Cluster.cpp 2008/05/12 15:13:33 1.6.2.3
@@ -25,7 +25,8 @@
#include <stdio.h>

extern "C" {
-# include <libcman.h>
+ #include <limits.h>
+ #include <libcman.h>
}

using namespace std;
--- conga/ricci/modules/storage/ContentFS.cpp 2008/01/17 17:38:39 1.5.2.1
+++ conga/ricci/modules/storage/ContentFS.cpp 2008/05/12 15:13:33 1.5.2.2
@@ -28,6 +28,7 @@
#include "BDFactory.h"
#include "defines.h"
#include "utils.h"
+#include <algorithm>


using namespace std;
--- conga/ricci/modules/storage/ExtendedFS.cpp 2008/01/17 17:38:39 1.7.2.2
+++ conga/ricci/modules/storage/ExtendedFS.cpp 2008/05/12 15:13:33 1.7.2.3
@@ -27,8 +27,9 @@
#include "UMountError.h"
#include "FileMagic.h"

-
+#include <algorithm>
#include <iostream>
+
using namespace std;


--- conga/ricci/modules/storage/LV.cpp 2008/01/17 17:38:39 1.6.2.4
+++ conga/ricci/modules/storage/LV.cpp 2008/05/12 15:13:33 1.6.2.5
@@ -124,7 +124,7 @@
long long min = utils::to_long(xml.get_attr("min"));
long long max = utils::to_long(xml.get_attr("max"));
long long step = utils::to_long(xml.get_attr("step"));
- long long min_size = (long long ) (size * (usage / 100.0));
+ long long min_size = (long long) (size * usage) / 100;
if (min_size > min)
min = min_size;
else if (min_size > max)
--- conga/ricci/modules/storage/Mapper.cpp 2008/01/17 17:38:39 1.3.2.1
+++ conga/ricci/modules/storage/Mapper.cpp 2008/05/12 15:13:33 1.3.2.2
@@ -26,6 +26,7 @@
#include "BDFactory.h"
#include "MapperFactory.h"
#include "MidAir.h"
+#include <algorithm>


using namespace std;
--- conga/ricci/modules/storage/MountHandler.cpp 2008/01/17 17:38:39 1.5.2.2
+++ conga/ricci/modules/storage/MountHandler.cpp 2008/05/12 15:13:33 1.5.2.3
@@ -37,8 +37,9 @@
#include <sys/file.h>
#include <errno.h>

-
+#include <algorithm>
#include <iostream>
+
using namespace std;


--- conga/ricci/modules/storage/PTSource.cpp 2008/01/17 17:38:39 1.2.2.1
+++ conga/ricci/modules/storage/PTSource.cpp 2008/05/12 15:13:33 1.2.2.2
@@ -25,6 +25,7 @@
#include "PartitionTable.h"
#include "parted_wrapper.h"

+#include <algorithm>

using namespace std;

--- conga/ricci/modules/storage/PV.cpp 2008/01/17 17:38:39 1.4.2.3
+++ conga/ricci/modules/storage/PV.cpp 2008/05/12 15:13:33 1.4.2.4
@@ -26,6 +26,7 @@
#include "MapperFactory.h"
#include "utils.h"
#include "LVMClusterLockingError.h"
+#include <algorithm>


using namespace std;
--- conga/ricci/modules/storage/Partition.cpp 2008/01/17 17:38:39 1.3.2.1
+++ conga/ricci/modules/storage/Partition.cpp 2008/05/12 15:13:33 1.3.2.2
@@ -30,6 +30,7 @@
#include "ContentExtendedPartition.h"
#include "PV.h"

+#include <algorithm>

using namespace std;

--- conga/ricci/modules/storage/PartitionTable.cpp 2008/01/17 17:38:39 1.5.2.1
+++ conga/ricci/modules/storage/PartitionTable.cpp 2008/05/12 15:13:33 1.5.2.2
@@ -28,7 +28,7 @@
#include "MapperFactory.h"
#include "utils.h"

-
+#include <algorithm>
#include <iostream>


--- conga/ricci/modules/storage/parted_wrapper.cpp 2008/01/17 17:38:39 1.8.2.4
+++ conga/ricci/modules/storage/parted_wrapper.cpp 2008/05/12 15:13:33 1.8.2.5
@@ -24,8 +24,9 @@
#include "parted_wrapper.h"
#include "utils.h"

-
+#include <algorithm>
#include <iostream>
+
using namespace std;


@@ -667,11 +668,13 @@
String s = utils::to_lower(utils::strip(size_str));
long long multiplier;
// parted defines 1KB as 1000 bytes.
- if (s.find("b") == s.npos)
+ if (s.find("b") == s.npos) {
multiplier = 1000 * 1000; // by old parted behavior, size is in MB
- else {
+ return (long long) utils::to_long(s) * multiplier;
+ } else {
if (s.size() < 3)
throw String("parted size has an invalid value: ") + s;
+ /* This path should never be hit on RHEL5 and later. */
multiplier = 1;
if (s[s.size()-2] == 'k')
multiplier = 1000;
@@ -681,7 +684,6 @@
multiplier = 1000 * 1000 * 1000;
else if (s[s.size()-2] == 't')
multiplier = (long long) 1000 * 1000 * 1000 * 1000;
+ return (long long) utils::to_float(s) * multiplier;
}
-
- return (long long) utils::to_float(s) * multiplier;
}

07-28-2008 05:49 PM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL5
Changes by: rmccabe@sourceware.org 2008-07-28 17:49:45

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
make : version.in
ricci/modules/virt: Makefile Virt.cpp
ricci/test_suite/cluster: vm_list.xml

Log message:
Build fixes

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&only_wi th_tag=RHEL5&r1=1.18.2.38&r2=1.18.2.39
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&only_with_ta g=RHEL5&r1=1.45.2.98&r2=1.45.2.99
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/make/version.in.diff?cvsroot=cluster&only_with_tag=RHEL 5&r1=1.21.2.41&r2=1.21.2.42
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/virt/Makefile.diff?cvsroot=cluster&only_with_tag=RHEL5& r1=1.1.2.1&r2=1.1.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/virt/Virt.cpp.diff?cvsroot=cluster&only_with_tag=RHEL5& r1=1.1.2.1&r2=1.1.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/test_suite/cluster/vm_list.xml.diff?cvsroot=cluster&only_with_tag=RHE L5&r1=1.1.2.1&r2=1.1.2.2

--- conga/clustermon.spec.in.in 2008/05/12 15:13:31 1.18.2.38
+++ conga/clustermon.spec.in.in 2008/07/28 17:49:44 1.18.2.39
@@ -27,22 +27,11 @@
Source0: %{name}-%{version}.tar.gz
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

-%define virt_support 0
-
-%ifarch i386 x86_64 ia64
-%define virt_support 0
-%endif
-
BuildRequires: cman-devel
BuildRequires: glibc-devel gcc-c++ libxml2-devel
BuildRequires: openssl-devel dbus-devel pam-devel pkgconfig
BuildRequires: net-snmp-devel tog-pegasus-devel

-%if %{virt_support}
-BuildRequires: libvirt-devel
-Requires: libvirt
-%endif
-
%description
This package contains Red Hat Enterprise Linux Cluster Suite
SNMP/CIM module/agent/provider.
@@ -52,17 +41,10 @@
%setup -q

%build
-%if %{virt_support}
-%configure --arch=%{_arch}
- --docdir=%{_docdir}
- --pegasus_providers_dir=%{PEGASUS_PROVIDERS_DIR}
- --include_zope_and_plone=no --VIRT_SUPPORT=0
-%else
%configure --arch=%{_arch}
--docdir=%{_docdir}
--pegasus_providers_dir=%{PEGASUS_PROVIDERS_DIR}
- --include_zope_and_plone=no --VIRT_SUPPORT=0
-%endif
+ --include_zope_and_plone=no

make %{?_smp_mflags} clustermon

--- conga/conga.spec.in.in 2008/07/23 19:55:40 1.45.2.98
+++ conga/conga.spec.in.in 2008/07/28 17:49:44 1.45.2.99
@@ -31,6 +31,12 @@
%endif
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

+%define virt_support 0
+
+%ifarch i386 x86_64 ia64
+%define virt_support 1
+%endif
+
BuildRequires: python-devel >= 2.4.1
BuildRequires: glibc-devel gcc-c++ libxml2-devel sed
BuildRequires: cyrus-sasl-devel >= 2.1
@@ -56,9 +62,16 @@
%endif

%build
+%if %{virt_support}
%configure --arch=%{_arch}
--docdir=%{_docdir}
- --include_zope_and_plone=%{include_zope_and_plone}
+ --include_zope_and_plone=%{include_zope_and_plone} --VIRT_SUPPORT=1
+%else
+%configure --arch=%{_arch}
+ --docdir=%{_docdir}
+ --include_zope_and_plone=%{include_zope_and_plone} --VIRT_SUPPORT=0
+%endif
+
make %{?_smp_mflags} conga

%install
@@ -198,10 +211,16 @@
Requires: initscripts
Requires: oddjob dbus openssl pam cyrus-sasl >= 2.1
Requires: sed util-linux
-Requires: modcluster >= 0.10.0
+Requires: modcluster >= 0.12.0

# modreboot

+# modvirt
+
+%if %{virt_support}
+BuildRequires: libvirt-devel
+%endif
+
# modrpm

# modstorage
@@ -253,13 +272,14 @@
%config(noreplace) %{_sysconfdir}/dbus-1/system.d/ricci-modlog.systembus.conf
%{_libexecdir}/ricci-modlog

+# modvirt
+%config(noreplace) %{_sysconfdir}/oddjobd.conf.d/ricci-modvirt.oddjob.conf
+%config(noreplace) %{_sysconfdir}/dbus-1/system.d/ricci-modvirt.systembus.conf
+ %{_libexecdir}/ricci-modvirt
+
%pre -n ricci
-if ! /bin/grep ^ricci:x /etc/group >&/dev/null; then
- /usr/sbin/groupadd -r -f ricci >&/dev/null
-fi
-if ! /bin/grep ^ricci:x /etc/passwd >&/dev/null; then
- /usr/sbin/useradd -r -M -s /sbin/nologin -d /var/lib/ricci -g ricci ricci >&/dev/null
-fi
+getent group ricci >/dev/null || groupadd -r ricci
+getent passwd ricci >/dev/null || useradd -r -M -g ricci -d /var/lib/ricci -s /sbin/nologin -c "ricci daemon user" ricci
exit 0

%post -n ricci
--- conga/make/version.in 2008/07/23 19:55:40 1.21.2.41
+++ conga/make/version.in 2008/07/28 17:49:45 1.21.2.42
@@ -1,2 +1,2 @@
VERSION=0.12.1
-RELEASE=0
+RELEASE=1
--- conga/ricci/modules/virt/Makefile 2008/07/14 16:00:12 1.1.2.1
+++ conga/ricci/modules/virt/Makefile 2008/07/28 17:49:45 1.1.2.2
@@ -14,7 +14,7 @@
include ${top_srcdir}/make/defines.mk


-TARGET = modvirt
+TARGET = ricci-modvirt

OBJECTS = main.o
VirtModule.o
@@ -22,8 +22,11 @@

PARANOID=0
INCLUDE += -I${top_srcdir}/common/
-CXXFLAGS += -DPARANOIA=$(PARANOID)
-LDFLAGS += -lvirt
+CXXFLAGS += -DPARANOIA=$(PARANOID) -DVIRT_SUPPORT=$(VIRT_SUPPORT)
+
+ifeq ($(VIRT_SUPPORT), 1)
+ LDFLAGS += -lvirt
+endif

ifeq ($(PARANOID), 1)
LDFLAGS += ${top_srcdir}/common/paranoid/*.o
@@ -39,9 +42,9 @@
$(INSTALL_DIR) ${libexecdir}
$(INSTALL_BIN) ${TARGET} ${libexecdir}
$(INSTALL_DIR) ${sysconfdir}/oddjobd.conf.d
- $(INSTALL_FILE) d-bus/modvirt.oddjob.conf ${sysconfdir}/oddjobd.conf.d
+ $(INSTALL_FILE) d-bus/ricci-modvirt.oddjob.conf ${sysconfdir}/oddjobd.conf.d
$(INSTALL_DIR) ${sysconfdir}/dbus-1/system.d
- $(INSTALL_FILE) d-bus/modvirt.systembus.conf ${sysconfdir}/dbus-1/system.d
+ $(INSTALL_FILE) d-bus/ricci-modvirt.systembus.conf ${sysconfdir}/dbus-1/system.d

uninstall:

--- conga/ricci/modules/virt/Virt.cpp 2008/07/14 16:00:12 1.1.2.1
+++ conga/ricci/modules/virt/Virt.cpp 2008/07/28 17:49:45 1.1.2.2
@@ -23,7 +23,9 @@
#include <sys/stat.h>
#include <string.h>
#include <errno.h>
+#if VIRT_SUPPORT == 1
#include <libvirt/libvirt.h>
+#endif

#include "sys_util.h"
#include "base64.h"
@@ -53,6 +55,8 @@
return false;
}

+#if VIRT_SUPPORT == 1
+
map<String, String> Virt::get_vm_list(const String &hvURI) {
std::map<String, String> vm_list;
int i;
@@ -130,3 +134,12 @@
virConnectClose(con);
return vm_list;
}
+
+#else
+
+map<String, String> Virt::get_vm_list(const String &hvURI) {
+ std::map<String, String> vm_list;
+ return vm_list;
+}
+
+#endif
--- conga/ricci/test_suite/cluster/vm_list.xml 2008/03/19 14:45:34 1.1.2.1
+++ conga/ricci/test_suite/cluster/vm_list.xml 2008/07/28 17:49:45 1.1.2.2
@@ -2,7 +2,7 @@
<ricci version="1.0" function="process_batch" async="false">
<batch>

-<module name="cluster">
+<module name="virt">
<request sequence="1254" API_version="1.0">
<function_call name="list_vm" />
</request>

07-29-2008 07:47 PM

conga ./clustermon.spec.in.in ./conga.spec.in. ...
 
CVSROOT: /cvs/cluster
Module name: conga
Changes by: rmccabe@sourceware.org 2008-07-29 19:47:07

Modified files:
. : clustermon.spec.in.in conga.spec.in.in
luci/cluster : cluster_config-macros cluster_svc-macros
fence-macros validate_config_qdisk.js
luci/plone-custom: conga.js
luci/site/luci/Extensions: HelperFunctions.py LuciValidation.py
LuciZopeClusterPortal.py
StorageReport.py cluster_adapters.py
conga_constants.py
luci/storage : form-macros
ricci/modules/cluster/clumon: REDHAT-CLUSTER-MIB
ricci/modules/rpm: PackageHandler.cpp
ricci/modules/service: ServiceManager.cpp
ricci/modules/storage: LVM.cpp
ricci/modules/virt: Makefile Virt.cpp
ricci/ricci : DBusController.cpp
ricci/ricci/d-bus: ricci.oddjob.conf
ricci/test_suite/cluster: vm_list.xml

Log message:
Forward port fixes from RHEL5

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/clustermon.spec.in.in.diff?cvsroot=cluster&r1=1.45 &r2=1.46
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&r1=1.99&r2=1 .100
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/cluster_config-macros.diff?cvsroot=cluster&r1=1.4&r2=1.5
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/cluster_svc-macros.diff?cvsroot=cluster&r1=1.7&r2=1.8
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/fence-macros.diff?cvsroot=cluster&r1=1.3&r2=1.4
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/validate_config_qdisk.js.diff?cvsroot=cluster&r1=1 .12&r2=1.13
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/plone-custom/conga.js.diff?cvsroot=cluster&r1=1.14&r2=1.15
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/HelperFunctions.py.diff?cvsroot=cluster&r1=1.15&r2 =1.16
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/LuciValidation.py.diff?cvsroot=cluster&r1=1.10&r2= 1.11
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/LuciZopeClusterPortal.py.diff?cvsroot=cluster&r1=1 .3&r2=1.4
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/StorageReport.py.diff?cvsroot=cluster&r1=1.30&r2=1 .31
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/cluster_adapters.py.diff?cvsroot=cluster&r1=1.283& r2=1.284
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/conga_constants.py.diff?cvsroot=cluster&r1=1.50&r2 =1.51
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/storage/form-macros.diff?cvsroot=cluster&r1=1.31&r2=1.32
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/cluster/clumon/REDHAT-CLUSTER-MIB.diff?cvsroot=cluster&r1=1.2&r2=1.3
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/rpm/PackageHandler.cpp.diff?cvsroot=cluster&r1=1.24&r2 =1.25
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/service/ServiceManager.cpp.diff?cvsroot=cluster&r1=1.20&r2 =1.21
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/storage/LVM.cpp.diff?cvsroot=cluster&r1=1.13&r2=1.14
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/virt/Makefile.diff?cvsroot=cluster&r1=1.1&r2=1.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/virt/Virt.cpp.diff?cvsroot=cluster&r1=1.1&r2=1.2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/ricci/DBusController.cpp.diff?cvsroot=cluster&r1=1.18&r2 =1.19
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/ricci/d-bus/ricci.oddjob.conf.diff?cvsroot=cluster&r1=1.1&r2=1 .2
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/test_suite/cluster/vm_list.xml.diff?cvsroot=cluster&r1=1.1&r2=1.2

--- conga/clustermon.spec.in.in 2008/06/06 16:41:52 1.45
+++ conga/clustermon.spec.in.in 2008/07/29 19:46:59 1.46
@@ -27,7 +27,7 @@
Source0: %{name}-%{version}.tar.gz
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

-BuildRequires: cman-devel libvirt-devel
+BuildRequires: cman-devel
BuildRequires: glibc-devel gcc-c++ libxml2-devel
BuildRequires: openssl-devel dbus-devel pam-devel pkgconfig
BuildRequires: net-snmp-devel tog-pegasus-devel
@@ -45,6 +45,7 @@
--docdir=%{_docdir}
--pegasus_providers_dir=%{PEGASUS_PROVIDERS_DIR}
--include_zope_and_plone=no
+
make %{?_smp_mflags} clustermon

%install
@@ -56,7 +57,6 @@



-
### cluster module ###


--- conga/conga.spec.in.in 2008/06/13 18:38:49 1.99
+++ conga/conga.spec.in.in 2008/07/29 19:47:00 1.100
@@ -31,9 +31,14 @@
%endif
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

+%define virt_support 0
+
+%ifarch i386 x86_64 ia64
+%define virt_support 1
+%endif
+
BuildRequires: python-devel >= 2.4.1
BuildRequires: glibc-devel gcc-c++ libxml2-devel sed
-BuildRequires: cman-devel
BuildRequires: cyrus-sasl-devel >= 2.1
BuildRequires: openssl-devel dbus-devel pkgconfig file

@@ -57,9 +62,16 @@
%endif

%build
+%if %{virt_support}
%configure --arch=%{_arch}
--docdir=%{_docdir}
- --include_zope_and_plone=%{include_zope_and_plone}
+ --include_zope_and_plone=%{include_zope_and_plone} --VIRT_SUPPORT=1
+%else
+%configure --arch=%{_arch}
+ --docdir=%{_docdir}
+ --include_zope_and_plone=%{include_zope_and_plone} --VIRT_SUPPORT=0
+%endif
+
make %{?_smp_mflags} conga

%install
@@ -199,10 +211,16 @@
Requires: initscripts
Requires: oddjob dbus openssl pam cyrus-sasl >= 2.1
Requires: sed util-linux
-Requires: modcluster >= 0.10.0
+Requires: modcluster >= 0.12.0

# modreboot

+# modvirt
+
+%if %{virt_support}
+BuildRequires: libvirt-devel
+%endif
+
# modrpm

# modstorage
@@ -254,13 +272,14 @@
%config(noreplace) %{_sysconfdir}/dbus-1/system.d/ricci-modlog.systembus.conf
%{_libexecdir}/ricci-modlog

+# modvirt
+%config(noreplace) %{_sysconfdir}/oddjobd.conf.d/ricci-modvirt.oddjob.conf
+%config(noreplace) %{_sysconfdir}/dbus-1/system.d/ricci-modvirt.systembus.conf
+ %{_libexecdir}/ricci-modvirt
+
%pre -n ricci
-if ! /bin/grep ^ricci:x /etc/group >&/dev/null; then
- /usr/sbin/groupadd -r -f ricci >&/dev/null
-fi
-if ! /bin/grep ^ricci:x /etc/passwd >&/dev/null; then
- /usr/sbin/useradd -r -M -s /sbin/nologin -d /var/lib/ricci -g ricci ricci >&/dev/null
-fi
+getent group ricci >/dev/null || groupadd -r ricci
+getent passwd ricci >/dev/null || useradd -r -M -g ricci -d /var/lib/ricci -s /sbin/nologin -c "ricci daemon user" ricci
exit 0

%post -n ricci
--- conga/luci/cluster/cluster_config-macros 2008/02/08 21:47:55 1.4
+++ conga/luci/cluster/cluster_config-macros 2008/07/29 19:47:02 1.5
@@ -715,21 +715,39 @@
</td>
</tr>

- <tr class="systemsTable">
- <td class="systemsTable">Device</td>
- <td class="systemsTable">
- <input type="text" name="device"
- tal:attributes="value clusterinfo/device | nothing" />
- </td>
- </tr>
-
- <tr class="systemsTable">
- <td class="systemsTable">Label</td>
- <td class="systemsTable">
- <input type="text" name="label"
- tal:attributes="value clusterinfo/label | nothing" />
- </td>
- </tr>
+
+ <tr class="systemsTable"><td colspan="2">
+ <table class="systemsTable">
+ <tr class="systemsTable">
+ <td class="systemsTable">
+ <input type="radio" name="qdisk_dev_label"
+ onclick="disable_text_field(this.form.label, this.form.device)">Label
+ </td>
+ <td class="systemsTable">
+ <input type="text" name="label" id="qdisk_label"
+ onfocus="disable_text_field(this.form.label, this.form.device);this.form.qdisk_dev_label[0].checked='checked';"
+ tal:attributes="
+ disabled python:(clusterinfo.get('label') or not clusterinfo.get('device')) and ' or 'disabled';
+ checked python:(clusterinfo.get('label') or not clusterinfo.get('label')) and 'checked' or ';
+ value clusterinfo/label | nothing" />
+ </td>
+ </tr>
+ <tr class="systemsTable">
+ <td class="systemsTable">
+ <input type="radio" name="qdisk_dev_label"
+ onclick="disable_text_field(this.form.device, this.form.label)">Device (deprecated)
+ </td>
+ <td class="systemsTable">
+ <input type="text" name="device" id="qdisk_device"
+ onfocus="disable_text_field(this.form.device, this.form.label);this.form.qdisk_dev_label[1].checked='checked';"
+ tal:attributes="
+ disabled python:clusterinfo.get('device') and ' or 'disabled';
+ checked python:clusterinfo.get('device') and 'checked' or ';
+ value clusterinfo/device | nothing" />
+ </td>
+ </tr>
+ </table>
+ </td></tr>
</table>
</div>

--- conga/luci/cluster/cluster_svc-macros 2008/03/06 21:27:16 1.7
+++ conga/luci/cluster/cluster_svc-macros 2008/07/29 19:47:02 1.8
@@ -46,7 +46,7 @@
class python: 'cluster service ' + (running and 'running' or 'stopped')"
tal:content="svc/name" />
<tal:block tal:condition="exists:svc/is_vm">
- (virtual service)
+ (virtual machine service)
</tal:block>
</td>

@@ -156,46 +156,8 @@
<p class="reshdr">Create a Virtual Machine Service</p>
</td></tr>
<tfoot class="systemsTable">
- <tr class="systemsTable">
- <td>Automatically start this service</td>
- <td>
- <input type="checkbox" name="autostart" checked="checked">
- </td>
- </tr>
- <tr class="systemsTable">
- <td>Run exclusive</td>
- <td>
- <input type="checkbox" name="exclusive">
- </td>
- </tr>
- <tr class="systemsTable">
- <td>Failover Domain</td>
- <td>
- <select name="domain">
- <option value="" selected="selected">None</option>
- <tal:block tal:repeat="f python:here.get_fdom_names(modelb)">
- <option tal:content="f"
- tal:attributes="value f" />
- </tal:block>
- </select>
- </td>
- </tr>
-
- <tr class="systemsTable">
- <td>Recovery policy</td>
- <td>
- <select name="recovery">
- <option value="">Select a recovery policy</option>
- <option name="relocate" value="relocate">Relocate</option>
- <option name="restart" value="restart">Restart</option>
- <option name="disable" value="disable">Disable</option>
- </select>
- </td>
- </tr>
-
<tr class="systemsTable"
tal:condition="exists:clusterinfo/vm_migration_choice">
-
<td>Migration type</td>
<td>
<select name="migration_type">
@@ -205,6 +167,8 @@
</td>
</tr>

+ <tal:block metal:use-macro="here/cluster_svc-macros/macros/failover-prefs-macro" />
+
<tr class="systemsTable"><td colspan="2">
<div class="hbSubmit">
<input type="submit" value="Create Virtual Machine Service" />
@@ -228,7 +192,7 @@

<div metal:define-macro="vmconfig-form">
<form method="post" action=""
- tal:define="vminfo python:here.getVMInfo(modelb, request)">
+ tal:define="sinfo python:here.getVMInfo(modelb, request)">

<input type="hidden" name="clustername"
tal:attributes="value request/clustername | nothing" />
@@ -237,14 +201,14 @@
tal:attributes="value request/pagetype | nothing" />

<input type="hidden" name="oldname"
- tal:attributes="value vminfo/name | nothing" />
+ tal:attributes="value sinfo/name | nothing" />

<div class="service_comp_list">
<table class="systemsTable">
<thead class="systemsTable">
<tr class="systemsTable">
<td class="systemsTable">
- <p class="reshdr">Properties for <tal:block tal:replace="vminfo/name | string:virtual machine service"/></p>
+ <p class="reshdr">Properties for <tal:block tal:replace="sinfo/name | string:virtual machine service"/></p>
</td>
</tr>

@@ -313,66 +277,21 @@
</thead>

<tfoot class="systemsTable">
- <tr class="systemsTable">
- <td>Automatically start this service</td>
- <td>
- <input type="checkbox" name="autostart"
- tal:attributes="checked python: ('autostart' in vminfo and vminfo['autostart'] != '0') and 'checked' or '" />
- </td>
- </tr>
- <tr class="systemsTable">
- <td>Run exclusive</td>
- <td>
- <input type="checkbox" name="exclusive"
- tal:attributes="checked python: ('exclusive' in vminfo and vminfo['exclusive'] != '0') and 'checked' or '" />
- </td>
- </tr>
- <tr class="systemsTable">
- <td>Failover Domain</td>
- <td>
- <select name="domain">
- <option value="" tal:content="string:None"
- tal:attributes="selected python: (not 'domain' in vminfo or not vminfo['domain']) and 'selected' or '" />
- <tal:block tal:repeat="f python:here.get_fdom_names(modelb)">
- <option tal:content="f"
- tal:attributes="
- value f;
- selected python: ('domain' in vminfo and vminfo['domain'] == f) and 'selected' or '" />
- </tal:block>
- </select>
- </td>
- </tr>
- <tr class="systemsTable">
- <td>Recovery policy</td>
- <td>
- <select name="recovery">
- <option value="">Select a recovery policy</option>
- <option name="relocate" value="relocate"
- tal:content="string:Relocate"
- tal:attributes="selected python: ('recovery' in vminfo and vminfo['recovery'] == 'relocate') and 'selected' or '" />
- <option name="restart" value="restart"
- tal:content="string:Restart"
- tal:attributes="selected python: ('recovery' in vminfo and vminfo['recovery'] == 'restart') and 'selected' or '" />
- <option name="disable" value="disable"
- tal:content="string:Disable"
- tal:attributes="selected python: ('recovery' in vminfo and vminfo['recovery'] == 'disable') and 'selected' or '" />
- </select>
- </td>
- </tr>
-
<tr class="systemsTable"
- tal:condition="exists:vminfo/vm_migration_choice">
+ tal:condition="exists:sinfo/vm_migration_choice">

<td>Migration type</td>
<td>
<select name="migration_type">
<option value="live" tal:content="string:Live"
- tal:attributes="selected python:('migrate' not in vminfo or vminfo['migrate'] != 'pause') and 'selected' or '" />
+ tal:attributes="selected python:(sinfo.get('migrate') != 'pause') and 'selected' or '" />
<option value="pause" tal:content="string:Pause"
- tal:attributes="selected python:('migrate' in vminfo and vminfo['migrate'] == 'pause') and 'selected' or '" />
+ tal:attributes="selected python:(sinfo.get('migrate') == 'pause') and 'selected' or '" />
</select>
</td>
</tr>
+
+ <tal:block metal:use-macro="here/cluster_svc-macros/macros/failover-prefs-macro" />

<tr class="systemsTable"><td colspan="2">
<div class="hbSubmit">
@@ -386,14 +305,14 @@
<td><span class="cluster_help" title="e.g., guest1 if the VM config file is at /etc/xen/guest1">Virtual machine name</span></td>
<td>
<input type="text" name="vmname"
- tal:attributes="value vminfo/name | nothing" />
+ tal:attributes="value sinfo/name | nothing" />
</td>
</tr>
<tr class="systemsTable">
<td><span class="cluster_help" title="e.g., /etc/xen/">Path to VM configuration files</span></td>
<td>
<input type="text" name="vmpath"
- tal:attributes="value vminfo/path | nothing" />
+ tal:attributes="value sinfo/path | nothing" />
</td>
</tr>
</tbody>
@@ -427,43 +346,7 @@
<input type="text" length="20" name="service_name" value="" />
</td>
</tr>
- <tr class="systemsTable">
- <td class="systemsTable">
- Automatically start this service
- </td>
- <td class="systemsTable">
- <input type="checkbox" name="autostart" checked="checked" />
- </td>
- </tr>
- <tr class="systemsTable">
- <td class="systemsTable">Run exclusive</td>
- <td class="systemsTable">
- <input type="checkbox" name="exclusive">
- </td>
- </tr>
- <tr class="systemsTable">
- <td class="systemsTable">Failover Domain</td>
- <td class="systemsTable">
- <select name="domain">
- <option value="" selected="selected">None</option>
- <tal:block tal:repeat="f sinfo/fdoms">
- <option tal:content="f"
- tal:attributes="value f" />
- </tal:block>
- </select>
- </td>
- </tr>
- <tr class="systemsTable">
- <td class="systemsTable">Recovery policy</td>
- <td class="systemsTable">
- <select name="recovery">
- <option value="">Select a recovery policy</option>
- <option name="relocate" value="relocate">Relocate</option>
- <option name="restart" value="restart">Restart</option>
- <option name="disable" value="disable">Disable</option>
- </select>
- </td>
- </tr>
+ <tal:block metal:use-macro="here/cluster_svc-macros/macros/failover-prefs-macro" />
</table>
</form>
</div>
@@ -522,7 +405,7 @@

<div metal:define-macro="servicemigrate">
<script type="text/javascript">
- set_page_title('Luci ?? cluster ?? services ?? Migrate a virtual service');
+ set_page_title('Luci ?? cluster ?? services ?? Migrate a virtual machine service');
</script>

<tal:block tal:define="
@@ -625,6 +508,76 @@
</tal:block>
</div>

+<div metal:define-macro="failover-prefs-macro" tal:omit-tag="">
+ <tr>
+ <td>Automatically start this service</td>
+ <td>
+ <input type="checkbox" name="autostart"
+ tal:attributes="checked python:(sinfo and sinfo.get('autostart') and sinfo['autostart'].lower() != 'false') and 'checked'" />
+ </td>
+ </tr>
+
+ <tr>
+ <td>Run exclusive</td>
+ <td>
+ <input type="checkbox" name="exclusive"
+ tal:attributes="checked python:(sinfo and sinfo.get('exclusive')and sinfo.get('exclusive').lower() != 'false') and 'checked'" />
+ </td>
+ </tr>
+
+ <tr>
+ <td>Failover Domain</td>
+ <td>
+ <select name="domain">
+ <option value=""
+ tal:attributes="selected python:(not sinfo or not sinfo.get('domain')) and 'selected' or '">None</option>
+ <tal:block tal:condition="exists:sinfo/fdoms">
+ <tal:block tal:repeat="f sinfo/fdoms">
+ <option tal:content="f" tal:attributes="
+ value f;
+ selected python:(sinfo and sinfo.get('domain') == f) and 'selected' or '" />
+ </tal:block>
+ </tal:block>
+ </select>
+ </td>
+ </tr>
+
+ <tr class="systemsTable">
+ <td>Recovery policy</td>
+ <td>
+ <select name="recovery">
+ <option value="">Select a recovery policy</option>
+ <option name="relocate" value="relocate"
+ tal:content="string:Relocate"
+ tal:attributes="selected python:(sinfo and sinfo.get('recovery') == 'relocate') and 'selected' or '" />
+ <option name="restart" value="restart"
+ tal:content="string:Restart"
+ tal:attributes="selected python:(sinfo and sinfo.get('recovery') == 'restart') and 'selected' or '" />
+ <option name="disable" value="disable"
+ tal:content="string:Disable"
+ tal:attributes="selected python:(sinfo and sinfo.get('recovery') == 'disable') and 'selected' or '" />
+ </select>
+ </td>
+ </tr>
+
+ <tr class="systemsTable">
+ <td class="systemsTable">
+ Maximum number of restart failures before relocating
+ </td>
+ <td class="systemsTable">
+ <input type="text" size="3" name="max_restarts"
+ tal:attributes="value sinfo/max_restarts|string:0" />
+ </td>
+ </tr>
+ <tr class="systemsTable">
+ <td class="systemsTable">Length of time in seconds after which to forget a restart</td>
+ <td class="systemsTable">
+ <input type="text" size="3" name="restart_expire_time"
+ tal:attributes="value sinfo/restart_expire_time|string:0" />
+ </td>
+ </tr>
+</div>
+
<div metal:define-macro="service-config-head-macro" tal:omit-tag="">
<script type="text/javascript"
src="/luci/homebase/homebase_common.js">
@@ -778,51 +731,9 @@
<div class="service_comp_list">
<form name="service_name_form">
<table class="rescfg">
- <tr>
- <td>Automatically start this service</td>
- <td><input type="checkbox" name="autostart"
- tal:attributes="checked python: ('autostart' in sinfo and sinfo['autostart'].lower() != 'false') and 'checked'" />
- </td>
- </tr>
- <tr>
- <td>Run exclusive</td>
- <td><input type="checkbox" name="exclusive"
- tal:attributes="checked python: ('exclusive' in sinfo and sinfo['exclusive'].lower() != 'false') and 'checked'" />
- </td>
- </tr>
- <tr>
- <td>Failover Domain</td>
- <td>
- <select name="domain">
- <option value=""
- tal:attributes="selected python: (not 'domain' in sinfo or not sinfo['domain']) and 'selected' or '">None</option>
- <tal:block tal:repeat="f sinfo/fdoms">
- <option tal:content="f"
- tal:attributes="
- value f;
- selected python: ('domain' in sinfo and sinfo['domain'] == f) and 'selected' or '" />
- </tal:block>
- </select>
- </td>
- </tr>
- <tr class="systemsTable">
- <td>Recovery policy</td>
- <td>
- <select name="recovery">
- <option value="">Select a recovery policy</option>
- <option name="relocate" value="relocate"
- tal:content="string:Relocate"
- tal:attributes="selected python: ('recovery' in sinfo and sinfo['recovery'] == 'relocate') and 'selected' or '" />
- <option name="restart" value="restart"
- tal:content="string:Restart"
- tal:attributes="selected python: ('recovery' in sinfo and sinfo['recovery'] == 'restart') and 'selected' or '" />
- <option name="disable" value="disable"
- tal:content="string:Disable"
- tal:attributes="selected python: ('recovery' in sinfo and sinfo['recovery'] == 'disable') and 'selected' or '" />
- </select>
- </td>
- </tr>
+ <tal:block metal:use-macro="here/cluster_svc-macros/macros/failover-prefs-macro" />
</table>
+
<input type="hidden" name="service_name"
tal:attributes="value sinfo/name | string:1" />
</form>
--- conga/luci/cluster/fence-macros 2008/04/23 17:33:37 1.3
+++ conga/luci/cluster/fence-macros 2008/07/29 19:47:02 1.4
@@ -684,6 +684,13 @@
</td>
</tr>
<tr>
+ <td>Module Name</td>
+ <td>
+ <input name="modulename" type="text"
+ tal:attributes="value cur_fencedev/modulename | nothing" />
+ </td>
+ </tr>
+ <tr>
<td>
<span title="Full path to a script to generate fence password">Password Script (optional)</span>
</td>
--- conga/luci/cluster/validate_config_qdisk.js 2008/01/02 20:52:22 1.12
+++ conga/luci/cluster/validate_config_qdisk.js 2008/07/29 19:47:02 1.13
@@ -206,6 +206,9 @@
var no_label = !form.label || str_is_blank(form.label.value);
if (no_dev && no_label)
errors.push('You must give either a label or a device.');
+ if (!no_dev && !no_label) {
+ errors.push('You may not specify both a device and a label.');
+ }

var hnum = document.getElementById('num_heuristics');
if (hnum) {
--- conga/luci/plone-custom/conga.js 2008/06/10 14:50:53 1.14
+++ conga/luci/plone-custom/conga.js 2008/07/29 19:47:02 1.15
@@ -248,6 +248,12 @@
elem.parentNode.removeChild(elem);
}

+function disable_text_field(enable_obj, disable_obj) {
+ disable_obj.value = "";
+ disable_obj.disabled = "disabled";
+ enable_obj.disabled = "";
+}
+
function swap_tabs(new_label, cur_tab, new_tab) {
if (cur_tab == new_tab) {
return (cur_tab);
--- conga/luci/site/luci/Extensions/HelperFunctions.py 2008/06/06 16:41:52 1.15
+++ conga/luci/site/luci/Extensions/HelperFunctions.py 2008/07/29 19:47:03 1.16
@@ -9,7 +9,7 @@
import threading

def resolveOSType(os_str):
- if not os_str or os_str.find('Tikanga') != (-1) or os_str.find('Zod') != (-1) or os_str.find('Moonshine') != (-1) or os_str.find('Werewolf') != (-1) or os.str_find('Sulphur') != (-1):
+ if not os_str or os_str.find('Tikanga') != (-1) or os_str.find('Zod') != (-1) or os_str.find('Moonshine') != (-1) or os_str.find('Werewolf') != (-1) or os_str.find('Sulphur') != (-1):
return 'rhel5'
else:
return 'rhel4'
--- conga/luci/site/luci/Extensions/LuciValidation.py 2008/05/12 18:03:39 1.10
+++ conga/luci/site/luci/Extensions/LuciValidation.py 2008/07/29 19:47:03 1.11
@@ -268,7 +268,7 @@

def validate_clusvc_add(model, request):
errors = list()
- fvar = GetReqVars(request, [ 'form_xml', 'domain', 'recovery', 'svc_name', 'action' ])
+ fvar = GetReqVars(request, [ 'form_xml', 'domain', 'recovery', 'svc_name', 'action', 'max_restarts', 'restart_expire_time' ])

form_xml = fvar['form_xml']
if form_xml is None:
@@ -370,6 +370,26 @@
if recovery is not None and recovery != 'restart' and recovery != 'relocate' and recovery != 'disable':
errors.append('You entered an invalid recovery option: "%s" Valid options are "restart" "relocate" and "disable."')

+ if recovery == 'restart':
+ max_restarts = None
+ if fvar['max_restarts']:
+ try:
+ max_restarts = int(fvar['max_restarts'])
+ if max_restarts < 0:
+ raise ValueError, 'must be greater than 0'
+ except Exception, e:
+ errors.append('Maximum restarts must be a number greater than or equal to 0')
+ max_restarts = None
+ restart_expire_time = None
+ if fvar['restart_expire_time']:
+ try:
+ restart_expire_time = int(fvar['restart_expire_time'])
+ if restart_expire_time < 0:
+ raise ValueError, 'must be greater than 0'
+ except Exception, e:
+ errors.append('Restart expire time must be a number greater than or equal to 0')
+ restart_expire_time = None
+
service_name = fvar['svc_name']
if service_name is None:
if LUCI_DEBUG_MODE is True:
@@ -440,6 +460,11 @@
new_service.addAttribute('domain', fdom)
if recovery:
new_service.addAttribute('recovery', recovery)
+ if max_restarts is not None:
+ new_service.addAttribute('max_restarts', str(max_restarts))
+ if restart_expire_time is not None:
+ new_service.addAttribute('restart_expire_time', str(restart_expire_time))
+
new_service.addAttribute('exclusive', str(exclusive))
if autostart is not None:
new_service.attr_hash['autostart'] = autostart
@@ -725,6 +750,8 @@

if not device and not label:
errors.append('No Device or Label value was given')
+ if device and label:
+ errors.append('You may not specify both device and label')

num_heuristics = 0
try:
@@ -1058,7 +1085,7 @@
def validate_vmsvc_form(model, request):
errors = list()

- fvar = GetReqVars(request, [ 'vmname', 'oldname', 'vmpath', 'recovery', 'domain', 'migration_type'])
+ fvar = GetReqVars(request, [ 'vmname', 'oldname', 'vmpath', 'recovery', 'domain', 'migration_type', 'max_restarts', 'restart_expire_time'])

vm_name = fvar['vmname']
if vm_name is None:
@@ -1087,6 +1114,32 @@
recovery = fvar['recovery']
if recovery is not None and recovery != 'restart' and recovery != 'relocate' and recovery != 'disable':
errors.append('You entered an invalid recovery option "%s" for VM service "%s". Valid options are "restart" "relocate" and "disable"' % (recovery, vm_name))
+ if recovery == 'restart':
+ max_restarts = None
+ if fvar['max_restarts']:
+ try:
+ max_restarts = int(fvar['max_restarts'])
+ if max_restarts < 0:
+ raise ValueError, 'must be greater than 0'
+ except Exception, e:
+ errors.append('Maximum restarts must be a number greater than or equal to 0')
+ max_restarts = None
+ restart_expire_time = None
+ if fvar['restart_expire_time']:
+ try:
+ restart_expire_time = int(fvar['restart_expire_time'])
+ if restart_expire_time < 0:
+ raise ValueError, 'must be greater than 0'
+ except Exception, e:
+ errors.append('Restart expire time must be a number greater than or equal to 0')
+ restart_expire_time = None
+
+ service_name = fvar['svc_name']
+ if service_name is None:
+ if LUCI_DEBUG_MODE is True:
+ luci_log.debug_verbose('vSA5: no service name')
+ errors.append('No service name was given')
+

migration_type = fvar['migration_type']
if migration_type is not None and migration_type != 'live' and migration_type != 'pause':
--- conga/luci/site/luci/Extensions/LuciZopeClusterPortal.py 2008/01/02 21:00:31 1.3
+++ conga/luci/site/luci/Extensions/LuciZopeClusterPortal.py 2008/07/29 19:47:03 1.4
@@ -251,10 +251,10 @@

if model.getIsVirtualized() is True:
vmadd = {}
- vmadd['Title'] = 'Add a Virtual Service'
+ vmadd['Title'] = 'Add a Virtual Machine Service'
vmadd['cfg_type'] = 'vmadd'
vmadd['absolute_url'] = '%s?pagetype=%s&clustername=%s' % (url, VM_ADD, cluname)
- vmadd['Description'] = 'Add a Virtual Service to this cluster'
+ vmadd['Description'] = 'Add a Virtual Machine Service to this cluster'
if pagetype == VM_ADD:
vmadd['currentItem'] = True
else:
@@ -305,7 +305,7 @@
svc['Title'] = name
svc['cfg_type'] = 'vm'
svc['absolute_url'] = '%s?pagetype=%s&servicename=%s&clustername=%s' % (url, VM_CONFIG, name, cluname)
- svc['Description'] = 'Configure this Virtual Service'
+ svc['Description'] = 'Configure this Virtual Machine Service'
if pagetype == VM_CONFIG:
try:
xname = request['servicename']
--- conga/luci/site/luci/Extensions/StorageReport.py 2008/04/23 17:33:37 1.30
+++ conga/luci/site/luci/Extensions/StorageReport.py 2008/07/29 19:47:03 1.31
@@ -1621,9 +1621,10 @@
mutable = var.getAttribute('mutable') == 'true'
var_type = var.getAttribute('type')
value = var.getAttribute('value')
+ def_value = value

d_units = '
- if name in ('size', 'extent_size', 'block_size', 'size_free', 'partition_begin' ):
+ if name in ('size', 'extent_size', 'block_size', 'journal_size', 'size_free', 'partition_begin' ):
d_units = 'bytes'
if 'percent' in name:
d_units = '%'
@@ -1685,7 +1686,7 @@
d_value = str(value)

hidden = False
- if var_type == 'hidden' or name in ( 'partition_begin', 'snapshot' ):
+ if var_type == 'hidden' or name in ( 'partition_begin', 'snapshot' ) or name[0:11] == '__snap_size':
hidden = True

if name == 'removable':
@@ -1697,6 +1698,7 @@
'name': name,
'pretty_name': get_pretty_prop_name(name),
'type': d_type,
+ 'default_val': def_value,
'value': d_value,
'units': d_units,
'validation': validation_data,
--- conga/luci/site/luci/Extensions/cluster_adapters.py 2008/04/23 17:33:37 1.283
+++ conga/luci/site/luci/Extensions/cluster_adapters.py 2008/07/29 19:47:03 1.284
@@ -545,7 +545,9 @@
next_node_id = 1

try:
- for x in system_list:
+ skeys = system_list.keys()
+ skeys.sort()
+ for x in skeys:
i = system_list[x]

try:
@@ -1167,7 +1169,6 @@
msg_list.append('Fix the error and try again:
')
else:
msg_list.append('PASSED
')
- model.setModified(True)
msg_list.append('DONE
')
msg_list.append('Propagating the new cluster.conf')

--- conga/luci/site/luci/Extensions/conga_constants.py 2008/03/05 23:08:58 1.50
+++ conga/luci/site/luci/Extensions/conga_constants.py 2008/07/29 19:47:04 1.51
@@ -155,6 +155,6 @@
# Debugging parameters. Set LUCI_DEBUG_MODE to True and LUCI_DEBUG_VERBOSITY
# to >= 2 to get full debugging output in syslog (LOG_DAEMON/LOG_DEBUG).

-LUCI_DEBUG_MODE = True
-LUCI_DEBUG_NET = True
-LUCI_DEBUG_VERBOSITY = 5
+LUCI_DEBUG_MODE = False
+LUCI_DEBUG_NET = False
+LUCI_DEBUG_VERBOSITY = 0
--- conga/luci/storage/form-macros 2008/01/02 20:52:23 1.31
+++ conga/luci/storage/form-macros 2008/07/29 19:47:04 1.32
@@ -87,6 +87,7 @@
</select>
</td>
</tr>
+ <tal:comment tal:replace="nothing">
<tr>
<td>
Display Devices by
@@ -99,6 +100,7 @@
</select>
</td>
</tr>
+ </tal:comment>
</table>
</form>
</fieldset>
@@ -865,21 +867,28 @@

<tal:block tal:condition="python:prop_type == 'select'">
<select tal:define="prop_options prop/value" tal:attributes="name p">
- <tal:block
- tal:condition="python: prop_units != 'bytes'"
- tal:repeat="prop_opt prop_options">
- <option tal:attributes="value prop_opt" />
- <span tal:replace="prop_opt" />
+ <tal:block tal:condition="python: prop_units != 'bytes'">
+ <tal:block tal:repeat="prop_opt prop_options">
+ <option tal:attributes="value prop_opt" />
+ <span tal:replace="prop_opt" />
+ </tal:block>
</tal:block>
- <tal:block
- tal:condition="python: prop_units == 'bytes'"
- tal:repeat="prop_opt prop_options">
- <option tal:attributes="value prop_opt" />
- <span
+
+ <tal:block tal:condition="python: prop_units == 'bytes'">
+ <tal:block
tal:define="
- dummy python: here.bytes_to_value_units(prop_opt);
- value python: str(dummy[0]) + ' ' + str(dummy[1])"
- tal:replace="value" />
+ dummy2 python:map(lambda x: int(x), prop_options);
+ dummy3 python:dummy2.sort()"
+ tal:repeat="prop_opt dummy2">
+ <option tal:attributes="
+ value prop_opt;
+ selected python:prop.get('default_val') == str(prop_opt) and 'selected' or '" />
+ <span
+ tal:define="
+ dummy python: here.bytes_to_value_units(prop_opt);
+ value python: str(dummy[0]) + ' ' + str(dummy[1])"
+ tal:replace="value" />
+ </tal:block>
</tal:block>
</select>
</tal:block>
--- conga/ricci/modules/cluster/clumon/REDHAT-CLUSTER-MIB 2007/09/11 02:45:27 1.2
+++ conga/ricci/modules/cluster/clumon/REDHAT-CLUSTER-MIB 2008/07/29 19:47:05 1.3
@@ -13,7 +13,7 @@
1801 Varsity Drive
Raleigh, North Carolina 27606
USA
-
+
email: customerservice@redhat.com
"
DESCRIPTION "Red Hat Cluster Suite MIB
@@ -28,7 +28,7 @@
rhcMIBInfo OBJECT IDENTIFIER ::= { RedHatCluster 1 }
rhcCluster OBJECT IDENTIFIER ::= { RedHatCluster 2 }
rhcTables OBJECT IDENTIFIER ::= { RedHatCluster 3 }
-
+



@@ -86,7 +86,7 @@
MAX-ACCESS read-only
STATUS current
DESCRIPTION
- "Minimum number of votes required for quorum.
+ "Minimum number of votes required for quorum.
If cluster is not quorate, all services are stopped."
::= { rhcCluster 4 }

@@ -234,7 +234,7 @@
::= { rhcTables 1 }

rhcNodeEntry OBJECT-TYPE
- SYNTAX RchNodeEntry
+ SYNTAX RhcNodeEntry
MAX-ACCESS not-accessible
STATUS current
DESCRIPTION
@@ -311,7 +311,7 @@
::= { rhcTables 2 }

rhcServiceEntry OBJECT-TYPE
- SYNTAX RchServiceEntry
+ SYNTAX RhcServiceEntry
MAX-ACCESS not-accessible
STATUS current
DESCRIPTION
--- conga/ricci/modules/rpm/PackageHandler.cpp 2008/06/06 16:41:53 1.24
+++ conga/ricci/modules/rpm/PackageHandler.cpp 2008/07/29 19:47:05 1.25
@@ -511,9 +511,12 @@
if (kernel.find("xen") == kernel.npos) {
set.packages.push_back("kmod-gfs");
set.packages.push_back("kmod-gfs2");
+ set.packages.push_back("cmirror");
+ set.packages.push_back("kmod-cmirror");
} else {
set.packages.push_back("kmod-gfs-xen");
set.packages.push_back("kmod-gfs2-xen");
+ set.packages.push_back("kmod-cmirror-xen");
}
}
}
--- conga/ricci/modules/service/ServiceManager.cpp 2008/06/06 16:41:54 1.20
+++ conga/ricci/modules/service/ServiceManager.cpp 2008/07/29 19:47:06 1.21
@@ -521,11 +521,12 @@
servs.push_back("gfs");
servs.push_back("scsi_reserve");
} else if (RHEL5 || FC6) {
- descr = "Shared Storage: clvmd, gfs, gfs2";
+ descr = "Shared Storage: clvmd, cmirror, gfs, gfs2";
servs.push_back("clvmd");
servs.push_back("gfs");
servs.push_back("gfs2");
servs.push_back("scsi_reserve");
+ servs.push_back("cmirror");
}
s = ServiceSet(name, descr);
if (populate_set(s, servs))
--- conga/ricci/modules/storage/LVM.cpp 2007/09/11 02:45:28 1.13
+++ conga/ricci/modules/storage/LVM.cpp 2008/07/29 19:47:06 1.14
@@ -252,7 +252,7 @@
String attrs = words[LVS_ATTR_IDX];
props.set(Variable("attrs", attrs));

- props.set(Variable("mirrored", attrs[0] == 'm'));
+ props.set(Variable("mirrored", attrs[0] == 'm' || attrs[0] == 'M'));

// clustered
String vg_attrs = words[LVS_VG_ATTR_IDX];
@@ -602,17 +602,37 @@
void
LVM::lvremove(const String& path)
{
- vector<String> args;
- args.push_back("lvchange");
- args.push_back("-an");
- args.push_back(path);
-
- String out, err;
- int status;
- if (utils::execute(LVM_BIN_PATH, args, out, err, status, false))
- throw command_not_found_error_msg(LVM_BIN_PATH);
- if (status != 0)
- throw String("Unable to deactivate LV (might be in use by other cluster nodes)");
+ vector<String> args;
+ args.push_back("lvchange");
+ args.push_back("-an");
+ args.push_back(path);
+
+ String out, err;
+ int status;
+
+ if (utils::execute(LVM_BIN_PATH, args, out, err, status, false))
+ throw command_not_found_error_msg(LVM_BIN_PATH);
+
+ if (status != 0) {
+ bool ignore_err = false;
+
+ try {
+ Props props;
+ std::list<counting_auto_ptr<BD> > sources;
+ std::list<counting_auto_ptr<BD> > targets;
+ probe_vg(path, props, sources, targets);
+ if (props.get("snapshot").get_bool() ||
+ props.get("mirror").get_bool())
+ {
+ ignore_err = true;
+ }
+ } catch (...) {
+ ignore_err = false;
+ }
+
+ if (!ignore_err)
+ throw String("Unable to deactivate LV (might be in use by other cluster nodes)");
+ }

try {
args.clear();
--- conga/ricci/modules/virt/Makefile 2008/07/10 20:25:58 1.1
+++ conga/ricci/modules/virt/Makefile 2008/07/29 19:47:06 1.2
@@ -14,7 +14,7 @@
include ${top_srcdir}/make/defines.mk


-TARGET = modvirt
+TARGET = ricci-modvirt

OBJECTS = main.o
VirtModule.o
@@ -22,8 +22,11 @@

PARANOID=0
INCLUDE += -I${top_srcdir}/common/
-CXXFLAGS += -DPARANOIA=$(PARANOID)
-LDFLAGS += -lvirt
+CXXFLAGS += -DPARANOIA=$(PARANOID) -DVIRT_SUPPORT=$(VIRT_SUPPORT)
+
+ifeq ($(VIRT_SUPPORT), 1)
+ LDFLAGS += -lvirt
+endif

ifeq ($(PARANOID), 1)
LDFLAGS += ${top_srcdir}/common/paranoid/*.o
@@ -39,9 +42,9 @@
$(INSTALL_DIR) ${libexecdir}
$(INSTALL_BIN) ${TARGET} ${libexecdir}
$(INSTALL_DIR) ${sysconfdir}/oddjobd.conf.d
- $(INSTALL_FILE) d-bus/modvirt.oddjob.conf ${sysconfdir}/oddjobd.conf.d
+ $(INSTALL_FILE) d-bus/ricci-modvirt.oddjob.conf ${sysconfdir}/oddjobd.conf.d
$(INSTALL_DIR) ${sysconfdir}/dbus-1/system.d
- $(INSTALL_FILE) d-bus/modvirt.systembus.conf ${sysconfdir}/dbus-1/system.d
+ $(INSTALL_FILE) d-bus/ricci-modvirt.systembus.conf ${sysconfdir}/dbus-1/system.d

uninstall:

--- conga/ricci/modules/virt/Virt.cpp 2008/07/10 20:25:58 1.1
+++ conga/ricci/modules/virt/Virt.cpp 2008/07/29 19:47:06 1.2
@@ -23,7 +23,9 @@
#include <sys/stat.h>
#include <string.h>
#include <errno.h>
+#if VIRT_SUPPORT == 1
#include <libvirt/libvirt.h>
+#endif

#include "sys_util.h"
#include "base64.h"
@@ -53,6 +55,8 @@
return false;
}

+#if VIRT_SUPPORT == 1
+
map<String, String> Virt::get_vm_list(const String &hvURI) {
std::map<String, String> vm_list;
int i;
@@ -130,3 +134,13 @@
virConnectClose(con);
return vm_list;
}
+
+#else
+
+map<String, String> Virt::get_vm_list(const String &hvURI) {
+ std::map<String, String> vm_list;
+ throw String("Unsupported on this architecture.");
+ return vm_list;
+}
+
+#endif
--- conga/ricci/ricci/DBusController.cpp 2008/01/02 20:47:38 1.18
+++ conga/ricci/ricci/DBusController.cpp 2008/07/29 19:47:06 1.19
@@ -41,12 +41,12 @@
DBusController::DBusController()
{
// TODO: dynamically determine,
- // currently, rpm requires storage and cluster modules
_mod_map["storage"] = "modstorage_rw";
_mod_map["cluster"] = "modcluster_rw";
_mod_map["rpm"] = "modrpm_rw";
_mod_map["log"] = "modlog_rw";
_mod_map["service"] = "modservice_rw";
+ _mod_map["virt"] = "modvirt_rw";
_mod_map["reboot"] = "reboot";

MutexLocker lock(_dbus_mutex);
--- conga/ricci/ricci/d-bus/ricci.oddjob.conf 2006/06/15 03:08:37 1.1
+++ conga/ricci/ricci/d-bus/ricci.oddjob.conf 2008/07/29 19:47:06 1.2
@@ -18,6 +18,9 @@
<method name="modservice_rw">
<allow user="ricci"/>
</method>
+ <method name="modvirt_rw">
+ <allow user="ricci"/>
+ </method>
<method name="reboot">
<helper exec="/sbin/reboot"
arguments="0"
--- conga/ricci/test_suite/cluster/vm_list.xml 2008/03/14 19:58:12 1.1
+++ conga/ricci/test_suite/cluster/vm_list.xml 2008/07/29 19:47:07 1.2
@@ -2,7 +2,7 @@
<ricci version="1.0" function="process_batch" async="false">
<batch>

-<module name="cluster">
+<module name="virt">
<request sequence="1254" API_version="1.0">
<function_call name="list_vm" />
</request>


All times are GMT. The time now is 10:29 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.