From: fbrehm Date: Tue, 21 Feb 2012 06:09:03 +0000 (+0100) Subject: committing changes in /etc after emerge run X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=3fef96585353dcd2fc5ac7f30c08e1a07a394b98;p=config%2Fsamara%2Fetc.git committing changes in /etc after emerge run Package changes: +sys-fs/mdadm-3.1.4 --- diff --git a/.etckeeper b/.etckeeper index 707bf12..030f405 100755 --- a/.etckeeper +++ b/.etckeeper @@ -212,6 +212,8 @@ maybe chmod 0644 './conf.d/keymaps' maybe chmod 0644 './conf.d/killprocs' maybe chmod 0644 './conf.d/localmount' maybe chmod 0644 './conf.d/lvm' +maybe chmod 0644 './conf.d/mdadm' +maybe chmod 0644 './conf.d/mdraid' maybe chmod 0644 './conf.d/modules' maybe chmod 0644 './conf.d/mysql' maybe chmod 0644 './conf.d/nas' @@ -850,6 +852,8 @@ maybe chmod 0755 './init.d/local' maybe chmod 0755 './init.d/localmount' maybe chmod 0755 './init.d/lvm' maybe chmod 0755 './init.d/lvm-monitoring' +maybe chmod 0755 './init.d/mdadm' +maybe chmod 0755 './init.d/mdraid' maybe chmod 0755 './init.d/mit-krb5kadmind' maybe chmod 0755 './init.d/mit-krb5kdc' maybe chmod 0755 './init.d/mit-krb5kpropd' @@ -986,6 +990,7 @@ maybe chmod 0644 './mailcap' maybe chmod 0644 './make.conf' maybe chmod 0644 './make.conf.catalyst' maybe chmod 0644 './man.conf' +maybe chmod 0644 './mdadm.conf' maybe chmod 0644 './mime.types' maybe chmod 0644 './mke2fs.conf' maybe chmod 0644 './mlocate-cron.conf' diff --git a/conf.d/mdadm b/conf.d/mdadm new file mode 100644 index 0000000..a4ead14 --- /dev/null +++ b/conf.d/mdadm @@ -0,0 +1,7 @@ +# /etc/conf.d/mdadm: config file for /etc/init.d/mdadm + +# Misc options to pass to mdadm in monitor mode. +# For more info, run `mdadm --monitor --help` or see +# the mdadm(8) manpage. + +MDADM_OPTS="--syslog" diff --git a/conf.d/mdraid b/conf.d/mdraid new file mode 100644 index 0000000..daa17ab --- /dev/null +++ b/conf.d/mdraid @@ -0,0 +1,5 @@ +# /etc/conf.d/mdraid: config file for /etc/init.d/mdraid + +# 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. diff --git a/init.d/mdadm b/init.d/mdadm new file mode 100755 index 0000000..c30004d --- /dev/null +++ b/init.d/mdadm @@ -0,0 +1,26 @@ +#!/sbin/runscript +# 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 $ + +depend() { + use logger dns net +} + +start() { + ebegin "Starting mdadm monitor" + mdadm --monitor --scan \ + --daemonise \ + --pid-file /var/run/mdadm.pid \ + ${MDADM_OPTS} + eend $? +} + +stop() { + local ret + ebegin "Stopping mdadm monitor" + start-stop-daemon --stop --pidfile /var/run/mdadm.pid + ret=$? + rm -f /var/run/mdadm.pid + eend ${ret} +} diff --git a/init.d/mdraid b/init.d/mdraid new file mode 100755 index 0000000..1a566cf --- /dev/null +++ b/init.d/mdraid @@ -0,0 +1,40 @@ +#!/sbin/runscript +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/mdadm/files/mdraid.rc-3.1.1,v 1.1 2010/01/24 22:20:57 robbat2 Exp $ + +depend() { + if [ ! -e /sbin/functions.sh ] ; then + # on baselayout-1 this could cause + # dependency-cycles with checkroot (before *) + before checkfs fsck + after modules + fi +} + +run_addon() { + local f=/lib64/rcscripts/addons/$1.sh + if [ -r "$f" ]; then + ( . "$f" ) + fi +} +start_addon() { + run_addon "$1"-start +} +stop_addon() { + run_addon "$1"-stop +} + +start() { + if [ -e /sbin/functions.sh ] ; then + eerror "The ${SVCNAME} init script is written for baselayout-2" + eerror "Please do not use it with baselayout-1" + return 1 + fi + + start_addon raid +} + +stop() { + stop_addon raid +} diff --git a/mdadm.conf b/mdadm.conf new file mode 100644 index 0000000..7bdff67 --- /dev/null +++ b/mdadm.conf @@ -0,0 +1,65 @@ +# mdadm configuration file +# +# mdadm will function properly without the use of a configuration file, +# but this file is useful for keeping track of arrays and member disks. +# In general, a mdadm.conf file is created, and updated, after arrays +# are created. This is the opposite behavior of /etc/raidtab which is +# created prior to array construction. +# +# +# the config file takes two types of lines: +# +# DEVICE lines specify a list of devices of where to look for +# potential member disks +# +# 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 +# example includes SCSI the first partition of SCSI disks /dev/sdb, +# /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 +#DEVICE /dev/hda1 /dev/hdb1 +# +# If you mount devfs on /dev, then a suitable way to list all devices is: +#DEVICE /dev/discs/*/* +# +# +# The AUTO line can control which arrays get assembled by auto-assembly, +# meaing either "mdadm -As" when there are no 'ARRAY' lines in this file, +# or "mdadm --incremental" when the array found is not listed in this file. +# By default, all arrays that are found are assembled. +# If you want to ignore all DDF arrays (maybe they are managed by dmraid), +# and only assemble 1.x arrays if which are marked for 'this' homehost, +# but assemble all others, then use +#AUTO -ddf homehost -1.x +all +# +# ARRAY lines specify an array to assemble and a method of identification. +# Arrays can currently be identified by using a UUID, superblock minor number, +# or a listing of devices. +# +# super-minor is usually the minor number of the metadevice +# UUID is the Universally Unique Identifier for the array +# Each can be obtained using +# +# mdadm -D +# +#ARRAY /dev/md0 UUID=3aaa0122:29827cfa:5331ad66:ca767371 +#ARRAY /dev/md1 super-minor=1 +#ARRAY /dev/md2 devices=/dev/hda1,/dev/hdb1 +# +# ARRAY lines can also specify a "spare-group" for each array. mdadm --monitor +# will then move a spare between arrays in a spare-group if one array has a failed +# drive but no spare +#ARRAY /dev/md4 uuid=b23f3c6d:aec43a9f:fd65db85:369432df spare-group=group1 +#ARRAY /dev/md5 uuid=19464854:03f71b1b:e0df2edd:246cc977 spare-group=group1 +# +# When used in --follow (aka --monitor) mode, mdadm needs a +# mail address and/or a program. This can be given with "mailaddr" +# and "program" lines to that monitoring can be started using +# mdadm --follow --scan & echo $! > /var/run/mdadm +# If the lines are not found, mdadm will exit quietly +#MAILADDR root@mydomain.tld +#PROGRAM /usr/sbin/handle-mdadm-events