Import of pkgsrc-2016Q3

This commit is contained in:
2016-11-18 22:39:22 +01:00
committed by sambuc
parent 9d819b6d54
commit 1242aa1e36
35952 changed files with 949747 additions and 377081 deletions
+16
View File
@@ -0,0 +1,16 @@
syncffsd uses rsync(1) to replicate a directory tree to another host.
This involves detecting changes, something NetBSD is not well prepared to
handle. The kqueue(2) interface can detect changes, but it needs to use a
file descriptor for every node monitored, and this does not scales very
well for huge directories trees.
syncffsd attempts to improve the situation until kqueue(2) gets better,
by using FFS superblock's fs_time field, which is updated on every
filesystem change. This lets syncffsd detects a change immediatly if the
filesystem is mounted synchronous, or after a few seconds if mounted with
WAPBL(4) enabled.
Once a change is detected, the relevant nodes are found by walking source
looking for files that changed since the previous filesystem modification.
The resulting nodes are deduped (i.e.: we do not retain a node in
a directory if the directory itself changed), and are fed to rsync(1).
+18
View File
@@ -0,0 +1,18 @@
# $NetBSD: Makefile,v 1.2 2015/09/30 02:03:56 manu Exp $
DISTNAME= syncffsd-0.8
CATEGORIES= net
MASTER_SITES= http://ftp.espci.fr/pub/syncffsd/
EXTRACT_SUFX= .tgz
MAINTAINER= manu@NetBSD.org
HOMEPAGE= http://ftp.espci.fr/pub/syncffsd/
COMMENT= FFS filesystem miroring using rsync
LICENSE= modified-bsd
RCD_SCRIPTS= syncffsd
MAKE_ENV+= VARBASE=${VARBASE}
MAKE_ENV+= PREFIX=${PREFIX}
.include "../../mk/bsd.pkg.mk"
+4
View File
@@ -0,0 +1,4 @@
@comment $NetBSD: PLIST,v 1.2 2015/09/30 02:03:56 manu Exp $
sbin/syncffsd
libexec/nagios/check_syncffsd
man/man8/syncffsd.8
+6
View File
@@ -0,0 +1,6 @@
$NetBSD: distinfo,v 1.3 2015/11/04 00:35:38 agc Exp $
SHA1 (syncffsd-0.8.tgz) = 50b11b3da9ba25270397d91d849222f2f4d5c59b
RMD160 (syncffsd-0.8.tgz) = adcaf8e0a043344d70d8cabf30241336eae8e99c
SHA512 (syncffsd-0.8.tgz) = ecef3bb3a6baf07522a79fb0a30d091441da5787950ca7b68a3ef264b1ec1541073cd7a944317024cafde33d75eb5843017bae13cbb35b281eb81cf243a6ebbc
Size (syncffsd-0.8.tgz) = 10401 bytes
+53
View File
@@ -0,0 +1,53 @@
#!/bin/sh
#
# PROVIDE: syncffsd
# REQUIRE: LOGIN
$_rc_subr_loaded . /etc/rc.subr
name="syncffsd"
rcvar=$name
pidfile="@VARBASE@/run/syncffsd/${name}.pid"
command="@PREFIX@/sbin/syncffsd"
start_precmd=syncffsd_precmd
start_cmd=syncffsd_start
syncffsd_precmd() {
local userflag
if [ "x${syncffsd_user}" != "x" ] ; then
userflag="-o ${syncffsd_user}"
fi
install -d -m 755 ${userflag} `dirname ${pidfile}`
}
syncffsd_start() {
local userflag
if [ -n "$rc_pid" ]; then
echo 1>&2 "${name} already running? (pid=$rc_pid)."
exit 1
fi
if [ "x${syncffsd_src}" = "x" ] ; then
echo 1>&2 "syncffsd_src is not defined in rc.conf"
exit 1
fi
if [ "x${syncffsd_dst}" = "x" ] ; then
echo 1>&2 "syncffsd_dst is not defined in rc.conf"
exit 1
fi
if [ "x${syncffsd_user}" != "x" ] ; then
userflag="-u ${syncffsd_user}"
fi
echo "Starting ${name}."
${command} -p ${pidfile} ${userflag} ${syncffsd_src} ${syncffsd_dst}
}
load_rc_config $name
run_rc_command "$1"