From: Frank Brehm Date: Tue, 3 Jan 2017 08:53:32 +0000 (+0100) Subject: saving uncommitted changes in /etc prior to emerge run X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=183f38a0e53fe46685d2a4af2a14295859db2c47;p=config%2Fbruni%2Fetc.git saving uncommitted changes in /etc prior to emerge run --- diff --git a/conf.d/mdraid b/conf.d/mdraid index daa17abd..5694d732 100644 --- a/conf.d/mdraid +++ b/conf.d/mdraid @@ -3,3 +3,9 @@ # For people who run raid on top of some other layer (like # dmcrypt), use rc_need to specify that requirement. See # the runscript(8) man page for more information. + +# Most configuration happens in /etc/mdadm.conf. + +# Pass additional options when assembling raids. +# Note: This applies to all raids. +MDADM_ASSEMBLE_OPTS="" diff --git a/cron.weekly/mdadm b/cron.weekly/mdadm old mode 100644 new mode 100755 index 72e401d5..e2b35b55 --- a/cron.weekly/mdadm +++ b/cron.weekly/mdadm @@ -1,4 +1,5 @@ #!/bin/sh +# This requires that AUTOCHECK is true in /etc/default/mdadm if [ -x /usr/sbin/checkarray ] && [ $(date +\%d) -le 7 ]; then /usr/sbin/checkarray --cron --all --idle --quiet fi diff --git a/default/mdadm b/default/mdadm new file mode 100644 index 00000000..921c70b1 --- /dev/null +++ b/default/mdadm @@ -0,0 +1,9 @@ +# Based on Debian /etc/default/mdadm + +# Gentoo comment: The cronjob checks for this value to decide to actually +# validate arrays. If missing, it does NOT actually do anything. +# AUTOCHECK: +# should mdadm run periodic redundancy checks over your arrays? See +# /etc/cron.weekly/mdadm + +#AUTOCHECK=true diff --git a/init.d/mdadm b/init.d/mdadm index c30004d0..c721c4d0 100755 --- a/init.d/mdadm +++ b/init.d/mdadm @@ -1,7 +1,7 @@ -#!/sbin/runscript +#!/sbin/openrc-run # Copyright 1999-2006 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/mdadm/files/mdadm.rc,v 1.2 2006/04/25 05:41:51 vapier Exp $ +# $Id$ depend() { use logger dns net diff --git a/init.d/mdraid b/init.d/mdraid index 27421e26..327b89ef 100755 --- a/init.d/mdraid +++ b/init.d/mdraid @@ -1,7 +1,7 @@ -#!/sbin/runscript -# Copyright 1999-2011 Gentoo Foundation +#!/sbin/openrc-run +# Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/mdadm/files/mdraid.rc,v 1.6 2011/11/12 21:06:44 vapier Exp $ +# $Id$ depend() { before checkfs fsck @@ -12,7 +12,7 @@ start() { local output ebegin "Starting up RAID devices" - output=$(mdadm -As 2>&1) + output=$(mdadm -As ${MDADM_ASSEMBLE_OPTS} 2>&1) eend $? "${output}" local pat="/dev/md_d*" diff --git a/mdadm.conf b/mdadm.conf index d9d8d396..35a75d12 100644 --- a/mdadm.conf +++ b/mdadm.conf @@ -15,9 +15,9 @@ # ARRAY lines specify information about how to identify arrays so # so that they can be activated # -# You can have more than one device line and use wild cards. The first +# You can have more than one device line and use wild cards. The first # example includes SCSI the first partition of SCSI disks /dev/sdb, -# /dev/sdc, /dev/sdd, /dev/sdj, /dev/sdk, and /dev/sdl. The second +# /dev/sdc, /dev/sdd, /dev/sdj, /dev/sdk, and /dev/sdl. The second # line looks for array slices on IDE disks. # #DEVICE /dev/sd[bcdjkl]1