aboutsummaryrefslogtreecommitdiff
path: root/sysutils/heartbeat2/files
diff options
context:
space:
mode:
Diffstat (limited to 'sysutils/heartbeat2/files')
-rw-r--r--sysutils/heartbeat2/files/extrapatch-lib-clplumbing-resource.h154
-rw-r--r--sysutils/heartbeat2/files/patch-ldirectord-init.d-ldirectord11
-rw-r--r--sysutils/heartbeat2/files/pkg-install.in138
3 files changed, 0 insertions, 303 deletions
diff --git a/sysutils/heartbeat2/files/extrapatch-lib-clplumbing-resource.h b/sysutils/heartbeat2/files/extrapatch-lib-clplumbing-resource.h
deleted file mode 100644
index a50080690d28..000000000000
--- a/sysutils/heartbeat2/files/extrapatch-lib-clplumbing-resource.h
+++ /dev/null
@@ -1,154 +0,0 @@
---- lib/clplumbing/resource.h.orig Tue Apr 18 23:30:49 2006
-+++ lib/clplumbing/resource.h Tue Apr 18 23:28:06 2006
-@@ -0,0 +1,151 @@
-+/*
-+ * Copyright (c) 1982, 1986, 1993
-+ * The Regents of the University of California. All rights reserved.
-+ *
-+ * Redistribution and use in source and binary forms, with or without
-+ * modification, are permitted provided that the following conditions
-+ * are met:
-+ * 1. Redistributions of source code must retain the above copyright
-+ * notice, this list of conditions and the following disclaimer.
-+ * 2. 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.
-+ * 3. All advertising materials mentioning features or use of this software
-+ * must display the following acknowledgement:
-+ * This product includes software developed by the University of
-+ * California, Berkeley and its contributors.
-+ * 4. Neither the name of the University 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 REGENTS 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 REGENTS 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.
-+ *
-+ * @(#)resource.h 8.4 (Berkeley) 1/9/95
-+ * $FreeBSD: /tmp/pcvs/ports/sysutils/heartbeat2/files/Attic/extrapatch-lib-clplumbing-resource.h,v 1.1 2006-04-18 21:53:58 ehaupt Exp $
-+ */
-+
-+#ifndef _SYS_RESOURCE_H_
-+#define _SYS_RESOURCE_H_
-+
-+/*
-+ * Process priority specifications to get/setpriority.
-+ */
-+#define PRIO_MIN -20
-+#define PRIO_MAX 20
-+
-+#define PRIO_PROCESS 0
-+#define PRIO_PGRP 1
-+#define PRIO_USER 2
-+
-+/*
-+ * Resource utilization information.
-+ */
-+
-+#define RUSAGE_SELF 0
-+#define RUSAGE_CHILDREN -1
-+
-+#include <sys/time.h>
-+
-+struct rusage {
-+ struct timeval ru_utime; /* user time used */
-+ struct timeval ru_stime; /* system time used */
-+ long ru_maxrss; /* max resident set size */
-+#define ru_first ru_ixrss
-+ long ru_ixrss; /* integral shared memory size */
-+ long ru_idrss; /* integral unshared data " */
-+ long ru_isrss; /* integral unshared stack " */
-+ long ru_minflt; /* page reclaims */
-+ long ru_majflt; /* page faults */
-+ long ru_nswap; /* swaps */
-+ long ru_inblock; /* block input operations */
-+ long ru_oublock; /* block output operations */
-+ long ru_msgsnd; /* messages sent */
-+ long ru_msgrcv; /* messages received */
-+ long ru_nsignals; /* signals received */
-+ long ru_nvcsw; /* voluntary context switches */
-+ long ru_nivcsw; /* involuntary " */
-+#define ru_last ru_nivcsw
-+};
-+
-+/*
-+ * Resource limits
-+ */
-+#define RLIMIT_CPU 0 /* cpu time in milliseconds */
-+#define RLIMIT_FSIZE 1 /* maximum file size */
-+#define RLIMIT_DATA 2 /* data size */
-+#define RLIMIT_STACK 3 /* stack size */
-+#define RLIMIT_CORE 4 /* core file size */
-+#define RLIMIT_RSS 5 /* resident set size */
-+#define RLIMIT_MEMLOCK 6 /* locked-in-memory address space */
-+#define RLIMIT_NPROC 7 /* number of processes */
-+#define RLIMIT_NOFILE 8 /* number of open files */
-+#define RLIMIT_SBSIZE 9 /* maximum size of all socket buffers */
-+#define RLIMIT_VMEM 10 /* virtual process size (inclusive of mmap) */
-+
-+#define RLIM_NLIMITS 11 /* number of resource limits */
-+
-+#define RLIM_INFINITY ((rlim_t)(((u_quad_t)1 << 63) - 1))
-+
-+
-+/*
-+ * Resource limit string identifiers
-+ */
-+
-+#ifdef _RLIMIT_IDENT
-+static char *rlimit_ident[] = {
-+ "cpu",
-+ "fsize",
-+ "data",
-+ "stack",
-+ "core",
-+ "rss",
-+ "memlock",
-+ "nproc",
-+ "nofile",
-+ "sbsize",
-+ "vmem",
-+};
-+#endif
-+
-+struct orlimit {
-+ int32_t rlim_cur; /* current (soft) limit */
-+ int32_t rlim_max; /* maximum value for rlim_cur */
-+};
-+
-+struct rlimit {
-+ rlim_t rlim_cur; /* current (soft) limit */
-+ rlim_t rlim_max; /* maximum value for rlim_cur */
-+};
-+
-+/* Load average structure. */
-+struct loadavg {
-+ fixpt_t ldavg[3];
-+ long fscale;
-+};
-+
-+#ifdef _KERNEL
-+extern struct loadavg averunnable;
-+
-+#else
-+#include <sys/cdefs.h>
-+
-+__BEGIN_DECLS
-+int getpriority __P((int, int));
-+int getrlimit __P((int, struct rlimit *));
-+int getrusage __P((int, struct rusage *));
-+int setpriority __P((int, int, int));
-+int setrlimit __P((int, const struct rlimit *));
-+__END_DECLS
-+
-+#endif /* _KERNEL */
-+#endif /* !_SYS_RESOURCE_H_ */
diff --git a/sysutils/heartbeat2/files/patch-ldirectord-init.d-ldirectord b/sysutils/heartbeat2/files/patch-ldirectord-init.d-ldirectord
deleted file mode 100644
index fa699c652b52..000000000000
--- a/sysutils/heartbeat2/files/patch-ldirectord-init.d-ldirectord
+++ /dev/null
@@ -1,11 +0,0 @@
---- ldirectord/init.d/ldirectord.orig
-+++ ldirectord/init.d/ldirectord
-@@ -22,7 +22,7 @@
- then
- . /etc/rc.d/init.d/functions
- else
-- function action {
-+ action() {
- echo -n "$1... "
- shift
- $@
diff --git a/sysutils/heartbeat2/files/pkg-install.in b/sysutils/heartbeat2/files/pkg-install.in
deleted file mode 100644
index a125513bfc8e..000000000000
--- a/sysutils/heartbeat2/files/pkg-install.in
+++ /dev/null
@@ -1,138 +0,0 @@
-#! /bin/sh
-
-ask() {
- local question default answer
-
- question=$1
- default=$2
- # pkg_add fails anyhow, if we do not create the user/group
- if [ "x${BATCH}" = xno ]; then
- read -p "${question} [${default}]? " answer
- fi
- if [ "x${answer}" = x ]; then
- answer=${default}
- fi
- echo ${answer}
-}
-
-yesno() {
- local dflt question answer
-
- question=$1
- dflt=$2
- while :; do
- answer=$(ask "${question}" "${dflt}")
- case "${answer}" in
- [Yy]*) return 0;;
- [Nn]*) return 1;;
- esac
- echo "Please answer yes or no."
- done
-}
-
-make_account() {
- local u g uid gid
-
- u=$1
- g=$2
- uid=$3
- gid=$4
-
- if pw group show "${g}" >/dev/null 2>&1; then
- echo "You already have a group \"${g}\", so I will use it."
- else
- echo "You need a group \"${g}\"."
- if yesno "Would you like me to create it" y; then
- pw groupadd ${g} -g ${gid} || exit
- echo "Done."
- else
- echo "Please create it manually, and try again."
- exit 1
- fi
- fi
-
- if pw user show "${u}" >/dev/null 2>&1; then
- echo "You already have a user \"${u}\", so I will use it."
- else
- echo "You need a user \"${u}\"."
- if yesno "Would you like me to create it" y; then
- pw useradd ${u} -u ${uid} -g ${g} -h - -d /nonexistant \
- -s /sbin/nologin -c "Heartbeat cluster user" || exit
- echo "Done."
- else
- echo "Please create it, and try again."
- exit 1
- fi
- fi
-}
-
-delete_account() {
- local u g
-
- u=$1
- g=$2
- if yesno "Do you want me to remove group \"${g}\"" y; then
- echo "Removing group \"${g}\""
- pw groupdel -n ${g}
- echo "Done."
- fi
- if yesno "Do you want me to remove user \"${u}\"" y; then
- echo "Removing user \"${u}\""
- pw userdel -n ${u}
- echo "Done."
- fi
-}
-
-case $2 in
-
-PRE-INSTALL)
- echo ""
- user=hacluster
- group=haclient
- uid=275
- gid=275
- make_account ${user} ${group} $uid $gid
-
- echo "Adding empty dirs and pid file."
- test -d /var/lib/heartbeat/ckpt || \
- install -d -m 755 /var/lib/heartbeat/ckpt
- test -d /var/lib/heartbeat/ccm || \
- install -d -m 750 -o ${user} -g ${group} /var/lib/heartbeat/ccm
- test -d /var/lib/heartbeat/cores/root || \
- install -d -m 700 /var/lib/heartbeat/cores/root
- test -d /var/lib/heartbeat/cores/nobody || \
- install -d -m 700 -o nobody /var/lib/heartbeat/cores/nobody
- test -d /var/lib/heartbeat/cores/hacluster || \
- install -d -m 700 -o ${user} /var/lib/heartbeat/cores/hacluster
- test -d /var/lock/subsys || \
- install -d -m 755 /var/lock/subsys
- test -f /var/run/heartbeat.pid || \
- install -m 644 -o ${user} -g ${group} /dev/null \
- /var/run/heartbeat.pid
- ;;
-
-DEINSTALL)
- if ps -axc | grep -q heartbeat; then
- if yesno "There are some heartbeat processes running. Shall I kill them" y
- then
- killall heartbeat
- sleep 2
- else
- echo "OK ... I hope you know what you are doing."
- fi
- fi
-
- delete_account hacluster haclient
-
- echo "Removing runtime files"
- if [ -d /var/lib/heartbeat ]; then
- rm -r /var/lib/heartbeat
- fi
- if [ -f /var/lock/subsys/heartbeat ]; then
- rm /var/lock/subsys/heartbeat
- fi
- if [ -f /var/run/heartbeat.pid ]; then
- rm /var/run/heartbeat.pid
- fi
- ;;
-esac