From: Frank Brehm Date: Sun, 26 Feb 2012 08:24:19 +0000 (+0100) Subject: Current state X-Git-Url: https://git.uhu-banane.org/?a=commitdiff_plain;h=5b26c9a4c1532d60f03520e71818aa3b8ea2e017;p=config%2Fbruni%2Fetc.git Current state --- diff --git a/._cfg0000_ldap.conf.sudo b/._cfg0000_ldap.conf.sudo deleted file mode 100644 index c5d51f95..00000000 --- a/._cfg0000_ldap.conf.sudo +++ /dev/null @@ -1,6 +0,0 @@ -# See ldap.conf(5) and README.LDAP for details -# This file should only be readable by root - -# supported directives: host, port, ssl, ldap_version -# uri, binddn, bindpw, sudoers_base, sudoers_debug -# tls_{checkpeer,cacertfile,cacertdir,randfile,ciphers,cert,key diff --git a/ImageMagick/._cfg0000_delegates.xml b/ImageMagick/._cfg0000_delegates.xml deleted file mode 100644 index 3870f06d..00000000 --- a/ImageMagick/._cfg0000_delegates.xml +++ /dev/null @@ -1,112 +0,0 @@ - - - - - - - - - - -]> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/ImageMagick/._cfg0000_policy.xml b/ImageMagick/._cfg0000_policy.xml deleted file mode 100644 index 19e97962..00000000 --- a/ImageMagick/._cfg0000_policy.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - - -]> - - - - - - - - - - - - - diff --git a/ImageMagick/delegates.xml b/ImageMagick/delegates.xml index db829d8e..3870f06d 100644 --- a/ImageMagick/delegates.xml +++ b/ImageMagick/delegates.xml @@ -80,14 +80,14 @@ - + - + - + @@ -100,11 +100,11 @@ - + - + diff --git a/ImageMagick/policy.xml b/ImageMagick/policy.xml index 28eda178..19e97962 100644 --- a/ImageMagick/policy.xml +++ b/ImageMagick/policy.xml @@ -37,7 +37,7 @@ Any large image is cached to disk rather than memory: - + Note, resource policies are maximums for each instance of ImageMagick (e.g. policy memory limit 1GB, -limit 2GB exceeds policy maximum so memory limit @@ -48,8 +48,8 @@ - - + + diff --git a/conf.d/._cfg0000_postgresql-9.1 b/conf.d/._cfg0000_postgresql-9.1 deleted file mode 100644 index 54cf5cc7..00000000 --- a/conf.d/._cfg0000_postgresql-9.1 +++ /dev/null @@ -1,58 +0,0 @@ -# Which port and socket to bind PostgreSQL -PGPORT="5432" - -# How long to wait for server to start in seconds -START_TIMEOUT=10 - -# NICE_QUIT ignores new connections and wait for clients to disconnect from -# server before shutting down. NICE_TIMEOUT in seconds determines how long to -# wait for this to succeed. -NICE_TIMEOUT=60 - -# Forecfully disconnect clients from server and shut down. This is performed -# after NICE_QUIT. Terminated client connections have their open transactions -# rolled back. -# Set RUDE_QUIT to "NO" to disable. RUDE_TIMEOUT in seconds. -RUDE_QUIT="YES" -RUDE_TIMEOUT=30 - -# If the server still fails to shutdown, you can force it to quit by setting -# this to YES and a recover-run will execute on the next startup. -# Set FORCE_QUIT to "YES" to enable. FORCE_TIMEOUT in seconds. -FORCE_QUIT="NO" -FORCE_TIMEOUT=2 - -# Extra options to run postmaster with, e.g.: -# -N is the maximal number of client connections -# -B is the number of shared buffers and has to be at least 2x the value for -N -# Please read the man-page to postmaster for more options. Many of these -# options can be set directly in the configuration file. -#PGOPTS="-N 512 -B 1024" - -# Pass extra environment variables. If you have to export environment variables -# for the database process, this can be done here. -# Don't forget to escape quotes. -#PG_EXTRA_ENV="PGPASSFILE=\"/path/to/.pgpass\"" - -############################################################################## -# -# The following values should not be arbitrarily changed. -# -# `emerge --config dev-db/postgresql-server:9.1' uses these values to -# determine where to create the data directory, where to place the -# configuration files, and any additional options to pass to initdb. -# -# The initscript also uses these variables to inform PostgreSQL where to find -# its data directory and configuration files. -# -############################################################################## - -# Location of configuration files -PGDATA="/etc/postgresql-9.1/" - -# Where the data directory is located/to be created -DATA_DIR="/var/lib/postgresql/9.1/data" - -# Additional options to pass to initdb. -# See `man initdb' for available options. -#PG_INITDB_OPTS="--locale=en_US.UTF-8" diff --git a/conf.d/postgresql-9.1 b/conf.d/postgresql-9.1 index 5bdd3d59..54cf5cc7 100644 --- a/conf.d/postgresql-9.1 +++ b/conf.d/postgresql-9.1 @@ -1,29 +1,23 @@ # Which port and socket to bind PostgreSQL PGPORT="5432" -# Allow *_TIMEOUT to run its course. -# Disable timeouts by changing to '-W' (capital W) -WAIT_FOR_START="-w" -WAIT_FOR_STOP="-w" - # How long to wait for server to start in seconds -START_TIMEOUT=60 +START_TIMEOUT=10 -# Ignore new connections and wait for clients to disconnect from server before -# shutting down. -# Set NICE_QUIT to "NO" to disable. NICE_TIMEOUT in seconds. -NICE_QUIT="YES" +# NICE_QUIT ignores new connections and wait for clients to disconnect from +# server before shutting down. NICE_TIMEOUT in seconds determines how long to +# wait for this to succeed. NICE_TIMEOUT=60 # Forecfully disconnect clients from server and shut down. This is performed -# after NICE_QUIT. Terminating a client results in a rollback of open -# transactions for that client. +# after NICE_QUIT. Terminated client connections have their open transactions +# rolled back. # Set RUDE_QUIT to "NO" to disable. RUDE_TIMEOUT in seconds. RUDE_QUIT="YES" RUDE_TIMEOUT=30 # If the server still fails to shutdown, you can force it to quit by setting -# this to yes and a recover-run will execute on the next startup. +# this to YES and a recover-run will execute on the next startup. # Set FORCE_QUIT to "YES" to enable. FORCE_TIMEOUT in seconds. FORCE_QUIT="NO" FORCE_TIMEOUT=2 @@ -31,24 +25,25 @@ FORCE_TIMEOUT=2 # Extra options to run postmaster with, e.g.: # -N is the maximal number of client connections # -B is the number of shared buffers and has to be at least 2x the value for -N -# Please read the man-page to postmaster for more options. Many of -# these options can be set directly in the configuration file. +# Please read the man-page to postmaster for more options. Many of these +# options can be set directly in the configuration file. #PGOPTS="-N 512 -B 1024" -# Pass extra environment variables. If you have to export environment -# variables for the database process, this can be done here. +# Pass extra environment variables. If you have to export environment variables +# for the database process, this can be done here. # Don't forget to escape quotes. #PG_EXTRA_ENV="PGPASSFILE=\"/path/to/.pgpass\"" ############################################################################## # # The following values should not be arbitrarily changed. -# emerge --config dev-db/postgresql-server:9.1 uses these values to +# +# `emerge --config dev-db/postgresql-server:9.1' uses these values to # determine where to create the data directory, where to place the -# configuration files and any additional options you'd like to pass to initdb. +# configuration files, and any additional options to pass to initdb. # -# The init script also uses these variables to inform pg_ctl where to find -# the same data and configuration files. +# The initscript also uses these variables to inform PostgreSQL where to find +# its data directory and configuration files. # ############################################################################## @@ -59,5 +54,5 @@ PGDATA="/etc/postgresql-9.1/" DATA_DIR="/var/lib/postgresql/9.1/data" # Additional options to pass to initdb. -# See 'man initdb' for available options. +# See `man initdb' for available options. #PG_INITDB_OPTS="--locale=en_US.UTF-8" diff --git a/config-archive/etc/ImageMagick/delegates.xml b/config-archive/etc/ImageMagick/delegates.xml new file mode 100644 index 00000000..db829d8e --- /dev/null +++ b/config-archive/etc/ImageMagick/delegates.xml @@ -0,0 +1,112 @@ + + + + + + + + + + +]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config-archive/etc/ImageMagick/delegates.xml.dist b/config-archive/etc/ImageMagick/delegates.xml.dist new file mode 100644 index 00000000..3870f06d --- /dev/null +++ b/config-archive/etc/ImageMagick/delegates.xml.dist @@ -0,0 +1,112 @@ + + + + + + + + + + +]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config-archive/etc/ImageMagick/policy.xml b/config-archive/etc/ImageMagick/policy.xml new file mode 100644 index 00000000..28eda178 --- /dev/null +++ b/config-archive/etc/ImageMagick/policy.xml @@ -0,0 +1,57 @@ + + + + + + + + +]> + + + + + + + + + + + + + diff --git a/config-archive/etc/ImageMagick/policy.xml.dist b/config-archive/etc/ImageMagick/policy.xml.dist new file mode 100644 index 00000000..19e97962 --- /dev/null +++ b/config-archive/etc/ImageMagick/policy.xml.dist @@ -0,0 +1,57 @@ + + + + + + + + +]> + + + + + + + + + + + + + diff --git a/config-archive/etc/conf.d/postgresql-9.1 b/config-archive/etc/conf.d/postgresql-9.1 new file mode 100644 index 00000000..5bdd3d59 --- /dev/null +++ b/config-archive/etc/conf.d/postgresql-9.1 @@ -0,0 +1,63 @@ +# Which port and socket to bind PostgreSQL +PGPORT="5432" + +# Allow *_TIMEOUT to run its course. +# Disable timeouts by changing to '-W' (capital W) +WAIT_FOR_START="-w" +WAIT_FOR_STOP="-w" + +# How long to wait for server to start in seconds +START_TIMEOUT=60 + +# Ignore new connections and wait for clients to disconnect from server before +# shutting down. +# Set NICE_QUIT to "NO" to disable. NICE_TIMEOUT in seconds. +NICE_QUIT="YES" +NICE_TIMEOUT=60 + +# Forecfully disconnect clients from server and shut down. This is performed +# after NICE_QUIT. Terminating a client results in a rollback of open +# transactions for that client. +# Set RUDE_QUIT to "NO" to disable. RUDE_TIMEOUT in seconds. +RUDE_QUIT="YES" +RUDE_TIMEOUT=30 + +# If the server still fails to shutdown, you can force it to quit by setting +# this to yes and a recover-run will execute on the next startup. +# Set FORCE_QUIT to "YES" to enable. FORCE_TIMEOUT in seconds. +FORCE_QUIT="NO" +FORCE_TIMEOUT=2 + +# Extra options to run postmaster with, e.g.: +# -N is the maximal number of client connections +# -B is the number of shared buffers and has to be at least 2x the value for -N +# Please read the man-page to postmaster for more options. Many of +# these options can be set directly in the configuration file. +#PGOPTS="-N 512 -B 1024" + +# Pass extra environment variables. If you have to export environment +# variables for the database process, this can be done here. +# Don't forget to escape quotes. +#PG_EXTRA_ENV="PGPASSFILE=\"/path/to/.pgpass\"" + +############################################################################## +# +# The following values should not be arbitrarily changed. +# emerge --config dev-db/postgresql-server:9.1 uses these values to +# determine where to create the data directory, where to place the +# configuration files and any additional options you'd like to pass to initdb. +# +# The init script also uses these variables to inform pg_ctl where to find +# the same data and configuration files. +# +############################################################################## + +# Location of configuration files +PGDATA="/etc/postgresql-9.1/" + +# Where the data directory is located/to be created +DATA_DIR="/var/lib/postgresql/9.1/data" + +# Additional options to pass to initdb. +# See 'man initdb' for available options. +#PG_INITDB_OPTS="--locale=en_US.UTF-8" diff --git a/config-archive/etc/conf.d/postgresql-9.1.dist b/config-archive/etc/conf.d/postgresql-9.1.dist new file mode 100644 index 00000000..54cf5cc7 --- /dev/null +++ b/config-archive/etc/conf.d/postgresql-9.1.dist @@ -0,0 +1,58 @@ +# Which port and socket to bind PostgreSQL +PGPORT="5432" + +# How long to wait for server to start in seconds +START_TIMEOUT=10 + +# NICE_QUIT ignores new connections and wait for clients to disconnect from +# server before shutting down. NICE_TIMEOUT in seconds determines how long to +# wait for this to succeed. +NICE_TIMEOUT=60 + +# Forecfully disconnect clients from server and shut down. This is performed +# after NICE_QUIT. Terminated client connections have their open transactions +# rolled back. +# Set RUDE_QUIT to "NO" to disable. RUDE_TIMEOUT in seconds. +RUDE_QUIT="YES" +RUDE_TIMEOUT=30 + +# If the server still fails to shutdown, you can force it to quit by setting +# this to YES and a recover-run will execute on the next startup. +# Set FORCE_QUIT to "YES" to enable. FORCE_TIMEOUT in seconds. +FORCE_QUIT="NO" +FORCE_TIMEOUT=2 + +# Extra options to run postmaster with, e.g.: +# -N is the maximal number of client connections +# -B is the number of shared buffers and has to be at least 2x the value for -N +# Please read the man-page to postmaster for more options. Many of these +# options can be set directly in the configuration file. +#PGOPTS="-N 512 -B 1024" + +# Pass extra environment variables. If you have to export environment variables +# for the database process, this can be done here. +# Don't forget to escape quotes. +#PG_EXTRA_ENV="PGPASSFILE=\"/path/to/.pgpass\"" + +############################################################################## +# +# The following values should not be arbitrarily changed. +# +# `emerge --config dev-db/postgresql-server:9.1' uses these values to +# determine where to create the data directory, where to place the +# configuration files, and any additional options to pass to initdb. +# +# The initscript also uses these variables to inform PostgreSQL where to find +# its data directory and configuration files. +# +############################################################################## + +# Location of configuration files +PGDATA="/etc/postgresql-9.1/" + +# Where the data directory is located/to be created +DATA_DIR="/var/lib/postgresql/9.1/data" + +# Additional options to pass to initdb. +# See `man initdb' for available options. +#PG_INITDB_OPTS="--locale=en_US.UTF-8" diff --git a/config-archive/etc/eselect/postgresql/slots/9.1/base b/config-archive/etc/eselect/postgresql/slots/9.1/base new file mode 100644 index 00000000..25e967a5 --- /dev/null +++ b/config-archive/etc/eselect/postgresql/slots/9.1/base @@ -0,0 +1 @@ +postgres_ebuilds="${postgres_ebuilds} postgresql-base-9.1.1" diff --git a/config-archive/etc/eselect/postgresql/slots/9.1/base.dist b/config-archive/etc/eselect/postgresql/slots/9.1/base.dist new file mode 100644 index 00000000..479bd41d --- /dev/null +++ b/config-archive/etc/eselect/postgresql/slots/9.1/base.dist @@ -0,0 +1 @@ +postgres_ebuilds="${postgres_ebuilds} postgresql-base-9.1.2" diff --git a/config-archive/etc/eselect/postgresql/slots/9.1/docs b/config-archive/etc/eselect/postgresql/slots/9.1/docs new file mode 100644 index 00000000..133932cf --- /dev/null +++ b/config-archive/etc/eselect/postgresql/slots/9.1/docs @@ -0,0 +1 @@ +postgres_ebuilds="${postgres_ebuilds} postgresql-docs-9.1.1" diff --git a/config-archive/etc/eselect/postgresql/slots/9.1/docs.dist b/config-archive/etc/eselect/postgresql/slots/9.1/docs.dist new file mode 100644 index 00000000..8cec4d40 --- /dev/null +++ b/config-archive/etc/eselect/postgresql/slots/9.1/docs.dist @@ -0,0 +1 @@ +postgres_ebuilds="${postgres_ebuilds} postgresql-docs-9.1.2" diff --git a/config-archive/etc/eselect/postgresql/slots/9.1/server b/config-archive/etc/eselect/postgresql/slots/9.1/server new file mode 100644 index 00000000..cc2c76ba --- /dev/null +++ b/config-archive/etc/eselect/postgresql/slots/9.1/server @@ -0,0 +1 @@ +postgres_ebuilds="${postgres_ebuilds} postgresql-server-9.1.1" diff --git a/config-archive/etc/eselect/postgresql/slots/9.1/server.dist b/config-archive/etc/eselect/postgresql/slots/9.1/server.dist new file mode 100644 index 00000000..7a0a9c0f --- /dev/null +++ b/config-archive/etc/eselect/postgresql/slots/9.1/server.dist @@ -0,0 +1 @@ +postgres_ebuilds="${postgres_ebuilds} postgresql-server-9.1.2-r2" diff --git a/config-archive/etc/init.d/net.lo b/config-archive/etc/init.d/net.lo index 6f8b5b10..23143639 100755 --- a/config-archive/etc/init.d/net.lo +++ b/config-archive/etc/init.d/net.lo @@ -21,11 +21,11 @@ depend() need localmount after bootmisc provide net - keyword -jail -prefix -vserver + keyword -shutdown -jail -prefix -vserver case "${IFACE}" in lo|lo0);; - *) after net.lo net.lo0;; + *) after net.lo net.lo0 dbus;; esac if [ "$(command -v "depend_${IFVAR}")" = "depend_${IFVAR}" ]; then @@ -115,7 +115,7 @@ _wait_for_carrier() eend 0 return 0 fi - timeout=$((${timeout} - 1)) + : $(( timeout -= 1 )) [ "${efunc}" = "einfon" ] && printf "." done @@ -144,9 +144,9 @@ _netmask2cidr() local i= len= local IFS=. for i in $1; do - while [ ${i} != "0" ]; do - len=$((${len} + ${i} % 2)) - i=$((${i} >> 1)) + while [ ${i} -ne 0 ]; do + : $(( len += i % 2 )) + : $(( i >>= 1 )) done done @@ -169,6 +169,36 @@ _configure_variables() done } +_which() +{ + local i OIFS + # Empty + [ -z "$1" ] && return + # check paths + OIFS="$IFS" + IFS=: + for i in $PATH ; do + [ -x $i/$1 ] && echo $i/$1 && break + done + IFS=$OIFS +} + +# Like _which, but also consider shell builtins, and multiple alternatives +_program_available() +{ + [ -z "$1" ] && return 0 + local x= + for x; do + case "${x}" in + /*) [ -x "${x}" ] && break;; + *) type "${x}" >/dev/null 2>&1 && break;; + esac + unset x + done + [ -n "${x}" ] && echo $x && return 0 + return 1 +} + _show_address() { einfo "received address $(_get_inet_address "${IFACE}")" @@ -277,7 +307,7 @@ _gen_module_list() echo "module_${i}_program_start='${PROGRAM_START}'" >> "${MODULESLIST}" echo "module_${i}_program_stop='${PROGRAM_STOP}'" >> "${MODULESLIST}" echo "module_${i}_provide='${PROVIDE}'" >> "${MODULESLIST}" - i=$((${i} + 1)) + : $(( i += 1 )) done echo "module_${i}=" >> "${MODULESLIST}" ) @@ -304,18 +334,17 @@ _load_modules() local i=-1 x= mod= f= provides= while true; do - i=$((${i} + 1)) + : $(( i += 1 )) eval mod=\$module_${i} [ -z "${mod}" ] && break [ -e "${MODULESDIR}/${mod}.sh" ] || continue eval set -- \$module_${i}_program if [ -n "$1" ]; then - x= - for x; do - [ -x "${x}" ] && break - done - [ -x "${x}" ] || continue + if ! _program_available "$@" >/dev/null; then + vewarn "Skipping module $mod due to missing program: $@" + continue + fi fi if ${starting}; then eval set -- \$module_${i}_program_start @@ -323,15 +352,10 @@ _load_modules() eval set -- \$module_${i}_program_stop fi if [ -n "$1" ]; then - x= - for x; do - case "${x}" in - /*) [ -x "${x}" ] && break;; - *) type "${x}" >/dev/null 2>&1 && break;; - esac - unset x - done - [ -n "${x}" ] || continue + if ! _program_available "$@" >/dev/null; then + vewarn "Skipping module $mod due to missing program: $@" + continue + fi fi eval provides=\$module_${i}_provide @@ -407,16 +431,18 @@ _load_config() set -- ${config} # We should support a space separated array for cidr configs + # But only as long as they do not contain other parameters for the address if [ $# = 1 ]; then unset IFS set -- ${config} # Of course, we may have a single address added old style. - case "$2" in - netmask|broadcast|brd|brd+|peer|pointopoint) - local IFS="$__IFS" - set -- ${config} - ;; - esac + # If the NEXT argument is a v4 or v6 address, it's the next config. + # Otherwise, it's arguments to the first config... + if [ "${2#*.*}" = "${2}" -a "${2#*:*}" = "${2}" ]; then + # Not an IPv4/IPv6 + local IFS="$__IFS" + set -- ${config} + fi fi # Ensure that loopback has the correct address @@ -438,7 +464,7 @@ _load_config() # so modules can influence it for cmd; do eval config_${config_index}="'${cmd}'" - config_index=$((${config_index} + 1)) + : $(( config_index += 1 )) done # Terminate the list eval config_${config_index}= @@ -446,7 +472,7 @@ _load_config() config_index=0 for cmd in ${fallback}; do eval fallback_${config_index}="'${cmd}'" - config_index=$((${config_index} + 1)) + : $(( config_index += 1 )) done # Terminate the list eval fallback_${config_index}= @@ -488,7 +514,9 @@ start() { local IFACE=${RC_SVCNAME#*.} oneworked=false fallback=false module= local IFVAR=$(shell_var "${IFACE}") cmd= our_metric= - local metric=0 + local metric=0 _up_before_preup + eval _up_before_preup="\$up_before_preup_${IFVAR}" + [ -z "${_up_before_preup}" ] && _up_before_preup=$up_before_preup einfo "Bringing up interface ${IFACE}" eindent @@ -502,7 +530,7 @@ start() # available in preup and afterwards incase the user inadvertently # brings it down if [ "$(command -v preup)" = "preup" ]; then - _up 2>/dev/null + yesno "${_up_before_preup:-yes}" && _up 2>/dev/null ebegin "Running preup" eindent preup || return 1 @@ -541,7 +569,7 @@ start() if [ -n "${our_metric}" ]; then metric=${our_metric} elif [ "${IFACE}" != "lo" -a "${IFACE}" != "lo0" ]; then - metric=$((${metric} + $(_ifindex))) + : $(( metric += $(_ifindex) )) fi while true; do @@ -581,11 +609,11 @@ start() eindent eval config_${config_index}=\$config unset fallback_${config_index} - config_index=$((${config_index} - 1)) + : $(( config_index -= 1 )) fi fi eoutdent - config_index=$((${config_index} + 1)) + : $(( config_index += 1 )) done if ! ${oneworked}; then diff --git a/config-archive/etc/init.d/net.lo.1 b/config-archive/etc/init.d/net.lo.1 new file mode 100755 index 00000000..6f8b5b10 --- /dev/null +++ b/config-archive/etc/init.d/net.lo.1 @@ -0,0 +1,737 @@ +#!/sbin/runscript +# Copyright (c) 2007-2009 Roy Marples +# Released under the 2-clause BSD license. + +MODULESDIR="${RC_LIBEXECDIR}/net" +MODULESLIST="${RC_SVCDIR}/nettree" +_config_vars="config routes" + +[ -z "${IN_BACKGROUND}" ] && IN_BACKGROUND="NO" + +description="Configures network interfaces." + +# Handy var so we don't have to embed new lines everywhere for array splitting +__IFS=" +" +depend() +{ + local IFACE=${RC_SVCNAME#*.} + local IFVAR=$(shell_var "${IFACE}") + + need localmount + after bootmisc + provide net + keyword -jail -prefix -vserver + + case "${IFACE}" in + lo|lo0);; + *) after net.lo net.lo0;; + esac + + if [ "$(command -v "depend_${IFVAR}")" = "depend_${IFVAR}" ]; then + depend_${IFVAR} + fi + + local dep= prov= + for dep in need use before after provide keyword; do + eval prov=\$rc_${dep}_${IFVAR} + if [ -n "${prov}" ]; then + ${dep} ${prov} + fi + done +} + +# Support bash arrays - sigh +_array_helper() +{ + local _a= + + eval _a=\$$1 + _a=$(echo "${_a}" | sed -e 's:^[[:space:]]*::' -e 's:[[:space:]]*$::' -e '/^$/d' -e 's:[[:space:]]\{1,\}: :g') + + [ -n "${_a}" ] && printf "%s\n" "${_a}" +} + +_get_array() +{ + local _a= + if [ -n "${BASH}" ]; then + case "$(declare -p "$1" 2>/dev/null)" in + "declare -a "*) + ewarn "You are using a bash array for $1." + ewarn "This feature will be removed in the future." + ewarn "Please see net.example for the correct format for $1." + eval "set -- \"\${$1[@]}\"" + for _a; do + printf "%s\n" "${_a}" + done + return 0 + ;; + esac + fi + + _array_helper $1 +} + +# Flatten bash arrays to simple strings +_flatten_array() +{ + if [ -n "${BASH}" ]; then + case "$(declare -p "$1" 2>/dev/null)" in + "declare -a "*) + ewarn "You are using a bash array for $1." + ewarn "This feature will be removed in the future." + ewarn "Please see net.example for the correct format for $1." + eval "set -- \"\${$1[@]}\"" + for x; do + printf "'%s' " "$(printf "$x" | sed "s:':'\\\'':g")" + done + return 0 + ;; + esac + fi + + _array_helper $1 +} + +_wait_for_carrier() +{ + local timeout= efunc=einfon + + _has_carrier && return 0 + + eval timeout=\$carrier_timeout_${IFVAR} + timeout=${timeout:-${carrier_timeout:-5}} + + # Incase users don't want this nice feature ... + [ ${timeout} -le 0 ] && return 0 + + yesno ${RC_PARALLEL} && efunc=einfo + ${efunc} "Waiting for carrier (${timeout} seconds) " + while [ ${timeout} -gt 0 ]; do + sleep 1 + if _has_carrier; then + [ "${efunc}" = "einfon" ] && echo + eend 0 + return 0 + fi + timeout=$((${timeout} - 1)) + [ "${efunc}" = "einfon" ] && printf "." + done + + [ "${efunc}" = "einfon" ] && echo + eend 1 + return 1 +} + +_netmask2cidr() +{ + # Some shells cannot handle hex arithmetic, so we massage it slightly + # Buggy shells include FreeBSD sh, dash and busybox. + # bash and NetBSD sh don't need this. + case $1 in + 0x*) + local hex=${1#0x*} quad= + while [ -n "${hex}" ]; do + local lastbut2=${hex#??*} + quad=${quad}${quad:+.}0x${hex%${lastbut2}*} + hex=${lastbut2} + done + set -- ${quad} + ;; + esac + + local i= len= + local IFS=. + for i in $1; do + while [ ${i} != "0" ]; do + len=$((${len} + ${i} % 2)) + i=$((${i} >> 1)) + done + done + + echo "${len}" +} + +_configure_variables() +{ + local var= v= t= + + for var in ${_config_vars}; do + local v= + for t; do + eval v=\$${var}_${t} + if [ -n "${v}" ]; then + eval ${var}_${IFVAR}=\$${var}_${t} + continue 2 + fi + done + done +} + +_show_address() +{ + einfo "received address $(_get_inet_address "${IFACE}")" +} + +# Basically sorts our modules into order and saves the list +_gen_module_list() +{ + local x= f= force=$1 + if ! ${force} && [ -s "${MODULESLIST}" -a "${MODULESLIST}" -nt "${MODULESDIR}" ]; then + local update=false + for x in "${MODULESDIR}"/*.sh; do + [ -e "${x}" ] || continue + if [ "${x}" -nt "${MODULESLIST}" ]; then + update=true + break + fi + done + ${update} || return 0 + fi + + einfo "Caching network module dependencies" + # Run in a subshell to protect the main script + ( + after() { + eval ${MODULE}_after="\"\${${MODULE}_after}\${${MODULE}_after:+ }$*\"" + } + + before() { + local mod=${MODULE} + local MODULE= + for MODULE; do + after "${mod}" + done + } + + program() { + if [ "$1" = "start" -o "$1" = "stop" ]; then + local s="$1" + shift + eval ${MODULE}_program_${s}="\"\${${MODULE}_program_${s}}\${${MODULE}_program_${s}:+ }$*\"" + else + eval ${MODULE}_program="\"\${${MODULE}_program}\${${MODULE}_program:+ }$*\"" + fi + } + + provide() { + eval ${MODULE}_provide="\"\${${MODULE}_provide}\${${MODULE}_provide:+ }$*\"" + local x + for x in $*; do + eval ${x}_providedby="\"\${${MODULE}_providedby}\${${MODULE}_providedby:+ }${MODULE}\"" + done + } + + for MODULE in "${MODULESDIR}"/*.sh; do + sh -n "${MODULE}" || continue + . "${MODULE}" || continue + MODULE=${MODULE#${MODULESDIR}/} + MODULE=${MODULE%.sh} + eval ${MODULE}_depend + MODULES="${MODULES} ${MODULE}" + done + + VISITED= + SORTED= + visit() { + case " ${VISITED} " in + *" $1 "*) return;; + esac + VISITED="${VISITED} $1" + + eval AFTER=\$${1}_after + for MODULE in ${AFTER}; do + eval PROVIDEDBY=\$${MODULE}_providedby + if [ -n "${PROVIDEDBY}" ]; then + for MODULE in ${PROVIDEDBY}; do + visit "${MODULE}" + done + else + visit "${MODULE}" + fi + done + + eval PROVIDE=\$${1}_provide + for MODULE in ${PROVIDE}; do + visit "${MODULE}" + done + + eval PROVIDEDBY=\$${1}_providedby + [ -z "${PROVIDEDBY}" ] && SORTED="${SORTED} $1" + } + + for MODULE in ${MODULES}; do + visit "${MODULE}" + done + + printf "" > "${MODULESLIST}" + i=0 + for MODULE in ${SORTED}; do + eval PROGRAM=\$${MODULE}_program + eval PROGRAM_START=\$${MODULE}_program_start + eval PROGRAM_STOP=\$${MODULE}_program_stop + eval PROVIDE=\$${MODULE}_provide + echo "module_${i}='${MODULE}'" >> "${MODULESLIST}" + echo "module_${i}_program='${PROGRAM}'" >> "${MODULESLIST}" + echo "module_${i}_program_start='${PROGRAM_START}'" >> "${MODULESLIST}" + echo "module_${i}_program_stop='${PROGRAM_STOP}'" >> "${MODULESLIST}" + echo "module_${i}_provide='${PROVIDE}'" >> "${MODULESLIST}" + i=$((${i} + 1)) + done + echo "module_${i}=" >> "${MODULESLIST}" + ) + + return 0 +} + +_load_modules() +{ + local starting=$1 mymods= + + # Ensure our list is up to date + _gen_module_list false + if ! . "${MODULESLIST}"; then + _gen_module_list true + . "${MODULESLIST}" + fi + + MODULES= + if [ "${IFACE}" != "lo" -a "${IFACE}" != "lo0" ]; then + eval mymods=\$modules_${IFVAR} + [ -z "${mymods}" ] && mymods=${modules} + fi + + local i=-1 x= mod= f= provides= + while true; do + i=$((${i} + 1)) + eval mod=\$module_${i} + [ -z "${mod}" ] && break + [ -e "${MODULESDIR}/${mod}.sh" ] || continue + + eval set -- \$module_${i}_program + if [ -n "$1" ]; then + x= + for x; do + [ -x "${x}" ] && break + done + [ -x "${x}" ] || continue + fi + if ${starting}; then + eval set -- \$module_${i}_program_start + else + eval set -- \$module_${i}_program_stop + fi + if [ -n "$1" ]; then + x= + for x; do + case "${x}" in + /*) [ -x "${x}" ] && break;; + *) type "${x}" >/dev/null 2>&1 && break;; + esac + unset x + done + [ -n "${x}" ] || continue + fi + + eval provides=\$module_${i}_provide + if ${starting}; then + case " ${mymods} " in + *" !${mod} "*) continue;; + *" !${provides} "*) [ -n "${provides}" ] && continue;; + esac + fi + MODULES="${MODULES}${MODULES:+ }${mod}" + + # Now load and wrap our functions + if ! . "${MODULESDIR}/${mod}.sh"; then + eend 1 "${RC_SVCNAME}: error loading module \`${mod}'" + exit 1 + fi + + [ -z "${provides}" ] && continue + + # Wrap our provides + local f= + for f in pre_start start post_start; do + eval "${provides}_${f}() { [ "$(command -v "${mod}_${f}")" = "${mod}_${f}" ] || return 0; ${mod}_${f} \"\$@\"; }" + done + + eval module_${mod}_provides="${provides}" + eval module_${provides}_providedby="${mod}" + done + + # Wrap our preferred modules + for mod in ${mymods}; do + case " ${MODULES} " in + *" ${mod} "*) + eval x=\$module_${mod}_provides + [ -z "${x}" ] && continue + for f in pre_start start post_start; do + eval "${x}_${f}() { [ "$(command -v "${mod}_${f}")" = "${mod}_${f}" ] || return 0; ${mod}_${f} \"\$@\"; }" + done + eval module_${x}_providedby="${mod}" + ;; + esac + done + + # Finally remove any duplicated provides from our list if we're starting + # Otherwise reverse the list + local LIST="${MODULES}" p= + MODULES= + if ${starting}; then + for mod in ${LIST}; do + eval x=\$module_${mod}_provides + if [ -n "${x}" ]; then + eval p=\$module_${x}_providedby + [ "${mod}" != "${p}" ] && continue + fi + MODULES="${MODULES}${MODULES:+ }${mod}" + done + else + for mod in ${LIST}; do + MODULES="${mod}${MODULES:+ }${MODULES}" + done + fi + + veinfo "Loaded modules: ${MODULES}" +} + +_load_config() +{ + local config="$(_get_array "config_${IFVAR}")" + local fallback="$(_get_array fallback_${IFVAR})" + + config_index=0 + local IFS="$__IFS" + set -- ${config} + + # We should support a space separated array for cidr configs + if [ $# = 1 ]; then + unset IFS + set -- ${config} + # Of course, we may have a single address added old style. + case "$2" in + netmask|broadcast|brd|brd+|peer|pointopoint) + local IFS="$__IFS" + set -- ${config} + ;; + esac + fi + + # Ensure that loopback has the correct address + if [ "${IFACE}" = "lo" -o "${IFACE}" = "lo0" ]; then + if [ "$1" != "null" ]; then + config_0="127.0.0.1/8" + config_index=1 + fi + else + if [ -z "$1" ]; then + ewarn "No configuration specified; defaulting to DHCP" + config_0="dhcp" + config_index=1 + fi + fi + + + # We store our config in an array like vars + # so modules can influence it + for cmd; do + eval config_${config_index}="'${cmd}'" + config_index=$((${config_index} + 1)) + done + # Terminate the list + eval config_${config_index}= + + config_index=0 + for cmd in ${fallback}; do + eval fallback_${config_index}="'${cmd}'" + config_index=$((${config_index} + 1)) + done + # Terminate the list + eval fallback_${config_index}= + + # Don't set to zero, so any net modules don't have to do anything extra + config_index=-1 +} + +# Support functions +_run_if() +{ + local cmd=$1 iface=$2 ifr=${IFACE} ifv=${IFVAR} + # Ensure that we don't stamp on real values + local IFACE= IFVAR= + shift + if [ -n "${iface}" ]; then + IFACE="${iface}" + [ "${iface}" != "${ifr}" ] && IFVAR=$(shell_var "${IFACE}") + else + IFACE=${ifr} + IFVAR=${ifv} + fi + ${cmd} +} +interface_exists() +{ + _run_if _exists "$@" +} +interface_up() +{ + _run_if _up "$@" +} +interface_down() +{ + _run_if _down "$@" +} + +start() +{ + local IFACE=${RC_SVCNAME#*.} oneworked=false fallback=false module= + local IFVAR=$(shell_var "${IFACE}") cmd= our_metric= + local metric=0 + + einfo "Bringing up interface ${IFACE}" + eindent + + if [ -z "${MODULES}" ]; then + local MODULES= + _load_modules true + fi + + # We up the iface twice if we have a preup to ensure it's up if + # available in preup and afterwards incase the user inadvertently + # brings it down + if [ "$(command -v preup)" = "preup" ]; then + _up 2>/dev/null + ebegin "Running preup" + eindent + preup || return 1 + eoutdent + fi + + _up 2>/dev/null + + for module in ${MODULES}; do + if [ "$(command -v "${module}_pre_start")" = "${module}_pre_start" ]; then + ${module}_pre_start || exit $? + fi + done + + if ! _exists; then + eerror "ERROR: interface ${IFACE} does not exist" + eerror "Ensure that you have loaded the correct kernel module for your hardware" + return 1 + fi + + if ! _wait_for_carrier; then + if service_started devd; then + ewarn "no carrier, but devd will start us when we have one" + mark_service_inactive "${RC_SVCNAME}" + else + eerror "no carrier" + fi + return 1 + fi + + local config= config_index= + _load_config + config_index=0 + + eval our_metric=\$metric_${IFVAR} + if [ -n "${our_metric}" ]; then + metric=${our_metric} + elif [ "${IFACE}" != "lo" -a "${IFACE}" != "lo0" ]; then + metric=$((${metric} + $(_ifindex))) + fi + + while true; do + eval config=\$config_${config_index} + [ -z "${config}" ] && break + + set -- ${config} + if [ "$1" != "null" -a "$1" != "noop" ]; then + ebegin "$1" + fi + eindent + case "$1" in + noop) + if [ -n "$(_get_inet_address)" ]; then + oneworked=true + break + fi + ;; + null) :;; + [0-9]*|*:*) _add_address ${config};; + *) + if [ "$(command -v "${config}_start")" = "${config}_start" ]; then + "${config}"_start + else + eerror "nothing provides \`${config}'" + fi + ;; + esac + if eend $?; then + oneworked=true + else + eval config=\$fallback_${config_index} + if [ -n "${config}" ]; then + fallback=true + eoutdent + ewarn "Trying fallback configuration ${config}" + eindent + eval config_${config_index}=\$config + unset fallback_${config_index} + config_index=$((${config_index} - 1)) + fi + fi + eoutdent + config_index=$((${config_index} + 1)) + done + + if ! ${oneworked}; then + if [ "$(command -v failup)" = "failup" ]; then + ebegin "Running failup" + eindent + failup + eoutdent + fi + return 1 + fi + + local hidefirstroute=false first=true routes= + if ${fallback}; then + routes="$(_get_array "fallback_routes_${IFVAR}")" + fi + if [ -z "${routes}" ]; then + routes="$(_get_array "routes_${IFVAR}")" + fi + if [ "${IFACE}" = "lo" -o "${IFACE}" = "lo0" ]; then + if [ "${config_0}" != "null" ]; then + routes="127.0.0.0/8 via 127.0.0.1 +${routes}" + hidefirstroute=true + fi + fi + + local OIFS="${IFS}" SIFS="${IFS-y}" + local IFS="$__IFS" + for cmd in ${routes}; do + unset IFS + if ${first}; then + first=false + einfo "Adding routes" + fi + eindent + ebegin ${cmd} + # Work out if we're a host or a net if not told + case ${cmd} in + -net" "*|-host" "*);; + *" "netmask" "*) cmd="-net ${cmd}";; + *.*.*.*/32*) cmd="-host ${cmd}";; + *.*.*.*/*|0.0.0.0|0.0.0.0" "*) cmd="-net ${cmd}";; + default|default" "*) cmd="-net ${cmd}";; + *) cmd="-host ${cmd}";; + esac + if ${hidefirstroute}; then + _add_route ${cmd} >/dev/null 2>&1 + hidefirstroute=false + else + _add_route ${cmd} >/dev/null + fi + eend $? + eoutdent + done + if [ "${SIFS}" = "y" ]; then + unset IFS + else + IFS="${OIFS}" + fi + + for module in ${MODULES}; do + if [ "$(command -v "${module}_post_start")" = "${module}_post_start" ]; then + ${module}_post_start || exit $? + fi + done + + if [ "$(command -v postup)" = "postup" ]; then + ebegin "Running postup" + eindent + postup + eoutdent + fi + + return 0 +} + +stop() +{ + local IFACE=${RC_SVCNAME#*.} module= + local IFVAR=$(shell_var "${IFACE}") opts= + + einfo "Bringing down interface ${IFACE}" + eindent + + if [ -z "${MODULES}" ]; then + local MODULES= + _load_modules false + fi + + if [ "$(command -v predown)" = "predown" ]; then + ebegin "Running predown" + eindent + predown || return 1 + eoutdent + else + if is_net_fs /; then + eerror "root filesystem is network mounted -- can't stop ${IFACE}" + return 1 + fi + fi + + for module in ${MODULES}; do + if [ "$(command -v "${module}_pre_stop")" = "${module}_pre_stop" ]; then + ${module}_pre_stop || exit $? + fi + done + + for module in ${MODULES}; do + if [ "$(command -v "${module}_stop")" = "${module}_stop" ]; then + ${module}_stop + fi + done + + # Only delete addresses for interfaces that exist + if _exists; then + # PPP can manage it's own addresses when IN_BACKGROUND + # Important in case "demand" set on the ppp link + if ! (yesno ${IN_BACKGROUND} && is_ppp) ; then + _delete_addresses "${IFACE}" + fi + fi + + for module in ${MODULES}; do + if [ "$(command -v "${module}_post_stop")" = "${module}_post_stop" ]; then + ${module}_post_stop + fi + done + + # If not in background, and not loopback then bring the interface down + # unless overridden. + if ! yesno ${IN_BACKGROUND} && \ + [ "${IFACE}" != "lo" -a "${IFACE}" != "lo0" ]; then + eval module=\$ifdown_${IFVAR} + module=${module:-${ifdown:-YES}} + yesno ${module} && _down 2>/dev/null + fi + + type resolvconf >/dev/null 2>&1 && resolvconf -d "${IFACE}" 2>/dev/null + + if [ "$(command -v "postdown")" = "postdown" ]; then + ebegin "Running postdown" + eindent + postdown + eoutdent + fi + + return 0 +} diff --git a/config-archive/etc/init.d/net.lo.dist b/config-archive/etc/init.d/net.lo.dist index 23143639..a9040a38 100755 --- a/config-archive/etc/init.d/net.lo.dist +++ b/config-archive/etc/init.d/net.lo.dist @@ -21,7 +21,7 @@ depend() need localmount after bootmisc provide net - keyword -shutdown -jail -prefix -vserver + keyword -jail -prefix -vserver case "${IFACE}" in lo|lo0);; diff --git a/config-archive/etc/init.d/postgresql-9.1 b/config-archive/etc/init.d/postgresql-9.1 new file mode 100755 index 00000000..a5051a33 --- /dev/null +++ b/config-archive/etc/init.d/postgresql-9.1 @@ -0,0 +1,192 @@ +#!/sbin/runscript +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +opts="${opts} reload" + +depend() { + use net + provide postgresql + provide postgresql-9.1 +} + +checkconfig() { + if [ -z ${DATA_DIR} ] ; then + eerror "DATA_DIR not set" + eerror "HINT: Did you not update /etc/conf.d/postgresql-9.1" + fi + if [ ! -d ${DATA_DIR} ] ; then + eerror "Directory not found: ${DATA_DIR}" + eerror "HINT: Ensure that DATA_DIR points to the right path." + eerror "HINT: Or perhaps you need to create the database cluster:" + eerror " emerge --config dev-db/postgresql-server:9.1" + return 1 + fi + if [ ! -f ${PGDATA}/postgresql.conf -o \ + ! -f ${PGDATA}/pg_hba.conf -o ! -f ${PGDATA}/pg_ident.conf ] ; then + eerror "The following file(s) were not found in ${PGDATA}:" + [ ! -f ${PGDATA}/postgresql.conf ] && eerror " postgresql.conf" + [ ! -f ${PGDATA}/pg_hba.conf ] && eerror " pg_hba.conf" + [ ! -f ${PGDATA}/pg_ident.conf ] && eerror " pg_ident.conf" + eerror "HINT: Try:" + eerror "mv ${DATA_DIR}/*.conf ${PGDATA}" + return 1 + fi + local file + local failed + for file in pg_hba pg_ident postgresql ; do + file="${PGDATA}/${file}.conf" + su postgres -c "test -r ${file}" || failed="${file} ${failed}" + done + if [ -n "${failed}" ] ; then + eerror "The following file(s) are not readable by 'postgres':" + local x + for x in ${failed} ; do + eerror " ${x}" + done + eerror "HINT: Try: 'chmod 644 ${PGDATA}/*.conf'" + return 1 + fi + if [ -e /var/run/postgresql/.s.PGSQL.${PGPORT} ] ; then + eerror "Socket conflict." + eerror "A server is already listening on:" + eerror " /var/run/postgresql/.s.PGSQL.${PGPORT}" + eerror "HINT: Change PGPORT to listen on a different socket." + return 1 + fi +} + +start() { + checkconfig || return 1 + + ebegin "Starting PostgreSQL" + + if [ -f ${DATA_DIR}/postmaster.pid ] ; then + rm -f ${DATA_DIR}/postmaster.pid + fi + + local retval + + su -l postgres \ + -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ + /usr/lib/postgresql-9.1/bin/pg_ctl \ + start ${WAIT_FOR_START} -t ${START_TIMEOUT} -s -D ${DATA_DIR} \ + -o '-D ${PGDATA} --data-directory=${DATA_DIR} --silent-mode=true ${PGOPTS}'" + retval=$? + + if [ $retval -ne 0 ] ; then + eerror "Check the PostgreSQL 9.1 log for a detailed explanation of the above error." + eend $retval + return $retval + fi + + # The following is to catch the case of an already running server + # in which pg_ctl doesn't know to which server it connected to and + # falsely reports the server as 'up' + if [ ! -f ${DATA_DIR}/postmaster.pid ] ; then + eerror "The PID file doesn't exist but pg_ctl reported a running server." + eerror "Please check whether there is another server running on the same port or read the log-file." + eend 1 + return 1 + fi + + eend $retval +} + +stop() { + ebegin "Stopping PostgreSQL (this can take up to $(( ${NICE_TIMEOUT} + ${RUDE_TIMEOUT} + ${FORCE_TIMEOUT} )) seconds)" + + local retval + + if [ "${NICE_QUIT}" != "NO" ] ; then + su -l postgres \ + -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ + /usr/lib/postgresql-9.1/bin/pg_ctl \ + stop ${WAIT_FOR_STOP} -t ${NICE_TIMEOUT} -s -D ${DATA_DIR} \ + -m smart" + retval=$? + + if [ $retval -eq 0 ] ; then + eend $retval + return $retval + fi + + ewarn "Shutting down the server gracefully failed." + ewarn "Probably because some clients did not disconnect within ${NICE_TIMEOUT} seconds." + else + ewarn "NICE_QUIT disabled." + ewarn "You really should have it enabled." + fi + + if [ "${RUDE_QUIT}" != "NO" ] ; then + ewarn "RUDE_QUIT enabled." + ewarn "Going to shutdown the server anyway." + + su -l postgres \ + -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ + /usr/lib/postgresql-9.1/bin/pg_ctl \ + stop ${WAIT_FOR_STOP} -t ${RUDE_TIMEOUT} -s -D ${DATA_DIR} \ + -m fast" + retval=$? + + if [ $retval -eq 0 ] ; then + eend $retval + return $retval + fi + + eerror "Failed to shutdown server." + else + ewarn "RUDE_QUIT disabled." + fi + + if [ "${FORCE_QUIT}" = "YES" ] ; then + ewarn "FORCE_QUIT enabled." + ewarn "Forcing server to shutdown." + ewarn "A recover-run will be executed on the next startup." + + su -l postgres \ + -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ + /usr/lib/postgresql-9.1/bin/pg_ctl \ + stop ${WAIT_FOR_STOP} -t ${FORCE_TIMEOUT} -s -D ${DATA_DIR} \ + -m immediate" + + retval=$? + + if [ $retval -eq 0 ] ; then + ewarn "Server forced down." + eend $retval + return $retval + fi + + eerror "Forced shutdown failed!!!" + eerror "Something is wrong with your system." + eerror "Please take care of it manually." + eerror "Unable to stop server." + eend $retval + return $retval + else + ewarn "FORCE_QUIT disabled." + eerror "Unable to shutdown server." + eend 1 + return 1 + fi +} + +reload() { + ebegin "Reloading PostgreSQL configuration" + su -l postgres \ + -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ + /usr/lib/postgresql-9.1/bin/pg_ctl \ + reload -s -D ${DATA_DIR}" + eend $? +} + +status() { + ebegin "Reloading PostgreSQL configuration" + su -l postgres \ + -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ + /usr/lib/postgresql-9.1/bin/pg_ctl \ + status -D ${DATA_DIR}" + eend $? +} diff --git a/config-archive/etc/init.d/postgresql-9.1.dist b/config-archive/etc/init.d/postgresql-9.1.dist new file mode 100755 index 00000000..01376910 --- /dev/null +++ b/config-archive/etc/init.d/postgresql-9.1.dist @@ -0,0 +1,141 @@ +#!/sbin/runscript +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +extra_started_commands="reload" + +get_config() { + [ -f ${PGDATA}/postgresql.conf ] || return 1 + + eval echo $(sed -e 's:#.*::' ${PGDATA}/postgresql.conf | awk '$1 == "'$1'" { print $2 == "=" ? $3 : $2 }') +} + +depend() { + use net + provide postgresql + + if [ "$(get_config log_destination)" = "syslog" ]; then + use logger + fi +} + +configured_port=$(get_config port) +: ${configured_port:=${PGPORT}} +socket_path=$(get_config unix_socket_path) +: ${socket_path:=/var/run/postgresql} + +checkconfig() { + # Check that DATA_DIR has been set and exists + if [ -z ${DATA_DIR} ] ; then + eerror "DATA_DIR not set" + eerror "HINT: Perhaps you need to update /etc/conf.d/postgresql-9.1" + fi + if [ ! -d ${DATA_DIR} ] ; then + eerror "Directory not found: ${DATA_DIR}" + eerror "HINT: Ensure that DATA_DIR points to the right path." + eerror "HINT: Or perhaps you need to create the database cluster:" + eerror " emerge --config dev-db/postgresql-server:9.1" + return 1 + fi + + # Check for the existence of and PostgreSQL's ability to read the config files. + if [ ! -f ${PGDATA}/postgresql.conf -o \ + ! -f ${PGDATA}/pg_hba.conf -o ! -f ${PGDATA}/pg_ident.conf ] ; then + eerror "The following file(s) were not found in ${PGDATA}:" + [ ! -f ${PGDATA}/postgresql.conf ] && eerror " postgresql.conf" + [ ! -f ${PGDATA}/pg_hba.conf ] && eerror " pg_hba.conf" + [ ! -f ${PGDATA}/pg_ident.conf ] && eerror " pg_ident.conf" + eerror "HINT: Try:" + eerror " mv ${DATA_DIR}/*.conf ${PGDATA}" + return 1 + fi + + local file + local failed + for file in pg_hba pg_ident postgresql ; do + file="${PGDATA}/${file}.conf" + su postgres -c "test -r ${file}" || failed="${file} ${failed}" + done + if [ -n "${failed}" ] ; then + eerror "The following file(s) are not readable by 'postgres':" + local x + for x in ${failed} ; do + eerror " ${x}" + done + eerror "HINT: Try: 'chmod 644 ${PGDATA}/*.conf'" + return 1 + fi + + checkpath -d -m 0770 -o postgres:postgres ${socket_path} + if [ -e ${socket_path}/.s.PGSQL.${configured_port} ] ; then + eerror "Socket conflict." + eerror "A server is already listening on:" + eerror " ${socket_path}/.s.PGSQL.${configured_port}" + eerror "HINT: Change PGPORT to listen on a different socket." + return 1 + fi +} + +start() { + checkconfig || return 1 + + ebegin "Starting PostgreSQL" + + rm -f ${DATA_DIR}/postmaster.pid + + local extraenv + local x + for x in ${PG_EXTRA_ENV} ; do + extraenv="${extraenv} --env ${x}" + done + + start-stop-daemon --start \ + --user postgres \ + --exec /usr/lib/postgresql-9.1/bin/postgres \ + --env "PGPORT=${configured_port}" \ + ${extraenv} \ + --wait $((${START_TIMEOUT}*1000)) \ + --pidfile ${DATA_DIR}/postmaster.pid \ + -- -D ${PGDATA} --data-directory=${DATA_DIR} --silent-mode=true ${PGOPTS} + local retval=$? + + if [ $retval -ne 0 ] ; then + eerror "Check the PostgreSQL 9.1 log for a detailed explanation of the above error." + eend $retval + return $retval + fi + + eend $retval +} + +stop() { + local seconds=$(( ${NICE_TIMEOUT} + ${RUDE_TIMEOUT} + ${FORCE_TIMEOUT} )) + ebegin "Stopping PostgreSQL (this can take up to ${seconds} seconds)" + + local retval + local retries=SIGTERM/${NICE_TIMEOUT} + + if [ "${RUDE_QUIT}" != "NO" ] ; then + einfo "RUDE_QUIT enabled." + retries="${retries}/SIGINT/${RUDE_TIMEOUT}" + fi + if [ "${FORCE_QUIT}" = "YES" ] ; then + einfo "FORCE_QUIT enabled." + ewarn "A recover-run might be executed on next startup." + retries="${retries}/SIGQUIT/${FORCE_TIMEOUT}" + fi + + start-stop-daemon --stop \ + --exec /usr/lib/postgresql-9.1/bin/postgres \ + --retry ${retries} \ + --pidfile ${DATA_DIR}/postmaster.pid + + eend +} + +reload() { + ebegin "Reloading PostgreSQL configuration" + kill -HUP $(head -n1 ${DATA_DIR}/postmaster.pid) + eend $? +} diff --git a/config-archive/etc/init.d/sysfs b/config-archive/etc/init.d/sysfs index 2433d847..dd3fc0ee 100755 --- a/config-archive/etc/init.d/sysfs +++ b/config-archive/etc/init.d/sysfs @@ -50,6 +50,43 @@ mount_misc() eend $? fi fi + + # Setup Kernel Support for configfs + if [ -d /sys/kernel/config ] && ! mountinfo -q /sys/kernel/config; then + if grep -qs configfs /proc/filesystems; then + ebegin "Mounting config filesystem" + mount -n -t configfs -o nodev,noexec,nosuid \ + configfs /sys/kernel/config + eend $? + fi + fi + + # set up kernel support for cgroups + if [ -d /sys/fs/cgroup ] && ! mountinfo -q /sys/fs/cgroup; then + if grep -qs cgroup /proc/filesystems; then + ebegin "Mounting cgroup filesystem" + local opts="nodev,noexec,nosuid,mode=755,size=${rc_cgroupsize:-10m}" + mount -n -t tmpfs -o ${opts} cgroup_root /sys/fs/cgroup + eend $? + fi + fi +} + +mount_cgroups() +{ + yesno ${rc_cgroups:-YES} || return 0 + if [ ! -e /proc/cgroups ]; then + return 0 + fi + + while read name hier groups enabled rest; do + case "${enabled}" in + 1) mkdir /sys/fs/cgroup/${name} + mount -t cgroup -o nodev,noexec,nosuid,${name} \ + ${name} /sys/fs/cgroup/${name} + ;; + esac + done < /proc/cgroups } start() @@ -59,6 +96,11 @@ start() retval=$? if [ $retval -eq 0 ]; then mount_misc + retval=$? + fi + if [ $retval -eq 0 ]; then + mount_cgroups + retval=$? fi return $retval } diff --git a/config-archive/etc/init.d/sysfs.1 b/config-archive/etc/init.d/sysfs.1 new file mode 100755 index 00000000..2433d847 --- /dev/null +++ b/config-archive/etc/init.d/sysfs.1 @@ -0,0 +1,64 @@ +#!/sbin/runscript +# Copyright (c) 2007-2009 Roy Marples +# Released under the 2-clause BSD license. + +description="Mount the sys filesystem." + +depend() +{ + keyword -prefix -vserver +} + +mount_sys() +{ + grep -Eq "[[:space:]]+sysfs$" /proc/filesystems || return 1 + mountinfo -q /sys && return 0 + + if [ ! -d /sys ]; then + if ! mkdir -m 0755 /sys; then + ewarn "Could not create /sys!" + return 1 + fi + fi + + ebegin "Mounting /sys" + if ! fstabinfo --mount /sys; then + mount -n -t sysfs -o noexec,nosuid,nodev sysfs /sys + fi + eend $? +} + +mount_misc() +{ + # Setup Kernel Support for securityfs + if [ -d /sys/kernel/security ] && \ + ! mountinfo -q /sys/kernel/security; then + if grep -qs securityfs /proc/filesystems; then + ebegin "Mounting security filesystem" + mount -n -t securityfs -o nodev,noexec,nosuid \ + securityfs /sys/kernel/security + eend $? + fi + fi + + # Setup Kernel Support for debugfs + if [ -d /sys/kernel/debug ] && ! mountinfo -q /sys/kernel/debug; then + if grep -qs debugfs /proc/filesystems; then + ebegin "Mounting debug filesystem" + mount -n -t debugfs -o nodev,noexec,nosuid \ + debugfs /sys/kernel/debug + eend $? + fi + fi +} + +start() +{ + local retval + mount_sys + retval=$? + if [ $retval -eq 0 ]; then + mount_misc + fi + return $retval +} diff --git a/config-archive/etc/init.d/sysfs.dist b/config-archive/etc/init.d/sysfs.dist index dd3fc0ee..50c98a98 100755 --- a/config-archive/etc/init.d/sysfs.dist +++ b/config-archive/etc/init.d/sysfs.dist @@ -74,15 +74,13 @@ mount_misc() mount_cgroups() { - yesno ${rc_cgroups:-YES} || return 0 - if [ ! -e /proc/cgroups ]; then - return 0 - fi + yesno ${rc_cgroups:-YES} && [ -e /proc/cgroups ] && \ + mountinfo -q /sys/fs/cgroup || return 0 while read name hier groups enabled rest; do case "${enabled}" in 1) mkdir /sys/fs/cgroup/${name} - mount -t cgroup -o nodev,noexec,nosuid,${name} \ + mount -n -t cgroup -o nodev,noexec,nosuid,${name} \ ${name} /sys/fs/cgroup/${name} ;; esac diff --git a/config-archive/etc/ldap.conf.sudo b/config-archive/etc/ldap.conf.sudo new file mode 100644 index 00000000..934f1b99 --- /dev/null +++ b/config-archive/etc/ldap.conf.sudo @@ -0,0 +1,5 @@ +# See ldap.conf(5) and README.LDAP for details\n" +# This file should only be readable by root\n\n" +# supported directives: host, port, ssl, ldap_version\n" +# uri, binddn, bindpw, sudoers_base, sudoers_debug\n" +# tls_{checkpeer,cacertfile,cacertdir,randfile,ciphers,cert,key diff --git a/config-archive/etc/ldap.conf.sudo.dist b/config-archive/etc/ldap.conf.sudo.dist new file mode 100644 index 00000000..c5d51f95 --- /dev/null +++ b/config-archive/etc/ldap.conf.sudo.dist @@ -0,0 +1,6 @@ +# See ldap.conf(5) and README.LDAP for details +# This file should only be readable by root + +# supported directives: host, port, ssl, ldap_version +# uri, binddn, bindpw, sudoers_base, sudoers_debug +# tls_{checkpeer,cacertfile,cacertdir,randfile,ciphers,cert,key diff --git a/config-archive/etc/mysql/my.cnf b/config-archive/etc/mysql/my.cnf new file mode 100644 index 00000000..b324ed2c --- /dev/null +++ b/config-archive/etc/mysql/my.cnf @@ -0,0 +1,149 @@ +# /etc/mysql/my.cnf: The global mysql configuration file. +# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/files/my.cnf-5.1,v 1.2 2010/03/24 18:26:09 robbat2 Exp $ + +# The following options will be passed to all MySQL clients +[client] +#password = your_password +port = 3306 +socket = /var/run/mysqld/mysqld.sock + +[mysql] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 +prompt = MySQL \u@\h:\d >\_ + +[mysqladmin] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqlcheck] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqldump] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqlimport] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqlshow] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[myisamchk] +character-sets-dir=/usr/share/mysql/charsets + +[myisampack] +character-sets-dir=/usr/share/mysql/charsets + +# use [safe_mysqld] with mysql-3 +[mysqld_safe] +err-log = /var/log/mysql/mysql.err + +# add a section [mysqld-4.1] or [mysqld-5.0] for specific configurations +[mysqld] +character-set-server = utf8 +default-character-set = utf8 +user = mysql +port = 3306 +socket = /var/run/mysqld/mysqld.sock +pid-file = /var/run/mysqld/mysqld.pid +log-error = /var/log/mysql/mysqld.err +basedir = /usr +#datadir = /var/lib/mysql +datadir = /data/mysql +skip-external-locking +key_buffer = 16M +max_allowed_packet = 1M +table_cache = 64 +sort_buffer_size = 512K +net_buffer_length = 8K +read_buffer_size = 256K +read_rnd_buffer_size = 512K +myisam_sort_buffer_size = 8M +language = /usr/share/mysql/german + +# security: +# using "localhost" in connects uses sockets by default +# skip-networking +#bind-address = 127.0.0.1 + +log-bin +server-id = 1 + +# point the following paths to different dedicated disks +tmpdir = /tmp/ +#log-update = /path-to-dedicated-directory/hostname + +# you need the debug USE flag enabled to use the following directives, +# if needed, uncomment them, start the server and issue +# #tail -f /tmp/mysqld.sql /tmp/mysqld.trace +# this will show you *exactly* what's happening in your server ;) + +#log = /tmp/mysqld.sql +#gdb +#debug = d:t:i:o,/tmp/mysqld.trace +#one-thread + +# uncomment the following directives if you are using BDB tables +#bdb_cache_size = 4M +#bdb_max_lock = 10000 + +# the following is the InnoDB configuration +# if you wish to disable innodb instead +# uncomment just the next line +#skip-innodb +# +# the rest of the innodb config follows: +# don't eat too much memory, we're trying to be safe on 64Mb boxes +# you might want to bump this up a bit on boxes with more RAM +innodb_buffer_pool_size = 16M +# this is the default, increase it if you have lots of tables +innodb_additional_mem_pool_size = 2M +# +# i'd like to use /var/lib/mysql/innodb, but that is seen as a database :-( +# and upstream wants things to be under /var/lib/mysql/, so that's the route +# we have to take for the moment +#innodb_data_home_dir = /var/lib/mysql/ +#innodb_log_arch_dir = /var/lib/mysql/ +#innodb_log_group_home_dir = /var/lib/mysql/ +# you may wish to change this size to be more suitable for your system +# the max is there to avoid run-away growth on your machine +innodb_data_file_path = ibdata1:10M:autoextend:max:128M +# we keep this at around 25% of of innodb_buffer_pool_size +# sensible values range from 1MB to (1/innodb_log_files_in_group*innodb_buffer_pool_size) +innodb_log_file_size = 5M +# this is the default, increase it if you have very large transactions going on +innodb_log_buffer_size = 8M +# this is the default and won't hurt you +# you shouldn't need to tweak it +innodb_log_files_in_group=2 +# see the innodb config docs, the other options are not always safe +innodb_flush_log_at_trx_commit = 1 +innodb_lock_wait_timeout = 50 +innodb_file_per_table + +[mysqldump] +quick +max_allowed_packet = 16M + +[mysql] +# uncomment the next directive if you are not familiar with SQL +#safe-updates + +[isamchk] +key_buffer = 20M +sort_buffer_size = 20M +read_buffer = 2M +write_buffer = 2M + +[myisamchk] +key_buffer = 20M +sort_buffer_size = 20M +read_buffer = 2M +write_buffer = 2M + +[mysqlhotcopy] +interactive-timeout diff --git a/config-archive/etc/mysql/my.cnf.dist b/config-archive/etc/mysql/my.cnf.dist new file mode 100644 index 00000000..9a439848 --- /dev/null +++ b/config-archive/etc/mysql/my.cnf.dist @@ -0,0 +1,146 @@ +# /etc/mysql/my.cnf: The global mysql configuration file. +# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/files/my.cnf-5.1,v 1.3 2012/02/15 02:07:21 jmbsvicetto Exp $ + +# The following options will be passed to all MySQL clients +[client] +#password = your_password +port = 3306 +socket = /var/run/mysqld/mysqld.sock + +[mysql] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqladmin] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqlcheck] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqldump] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqlimport] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[mysqlshow] +character-sets-dir=/usr/share/mysql/charsets +default-character-set=utf8 + +[myisamchk] +character-sets-dir=/usr/share/mysql/charsets + +[myisampack] +character-sets-dir=/usr/share/mysql/charsets + +# use [safe_mysqld] with mysql-3 +[mysqld_safe] +err-log = /var/log/mysql/mysql.err + +# add a section [mysqld-4.1] or [mysqld-5.0] for specific configurations +[mysqld] +character-set-server = utf8 +user = mysql +port = 3306 +socket = /var/run/mysqld/mysqld.sock +pid-file = /var/run/mysqld/mysqld.pid +log-error = /var/log/mysql/mysqld.err +basedir = /usr +datadir = /data/mysql +skip-external-locking +key_buffer = 16M +max_allowed_packet = 1M +table_open_cache = 64 +sort_buffer_size = 512K +net_buffer_length = 8K +read_buffer_size = 256K +read_rnd_buffer_size = 512K +myisam_sort_buffer_size = 8M +language = /usr/share/mysql/english + +# security: +# using "localhost" in connects uses sockets by default +# skip-networking +bind-address = 127.0.0.1 + +log-bin +server-id = 1 + +# point the following paths to different dedicated disks +tmpdir = /tmp/ +#log-update = /path-to-dedicated-directory/hostname + +# you need the debug USE flag enabled to use the following directives, +# if needed, uncomment them, start the server and issue +# #tail -f /tmp/mysqld.sql /tmp/mysqld.trace +# this will show you *exactly* what's happening in your server ;) + +#log = /tmp/mysqld.sql +#gdb +#debug = d:t:i:o,/tmp/mysqld.trace +#one-thread + +# uncomment the following directives if you are using BDB tables +#bdb_cache_size = 4M +#bdb_max_lock = 10000 + +# the following is the InnoDB configuration +# if you wish to disable innodb instead +# uncomment just the next line +#skip-innodb +# +# the rest of the innodb config follows: +# don't eat too much memory, we're trying to be safe on 64Mb boxes +# you might want to bump this up a bit on boxes with more RAM +innodb_buffer_pool_size = 16M +# this is the default, increase it if you have lots of tables +innodb_additional_mem_pool_size = 2M +# +# i'd like to use /var/lib/mysql/innodb, but that is seen as a database :-( +# and upstream wants things to be under /var/lib/mysql/, so that's the route +# we have to take for the moment +#innodb_data_home_dir = /var/lib/mysql/ +#innodb_log_arch_dir = /var/lib/mysql/ +#innodb_log_group_home_dir = /var/lib/mysql/ +# you may wish to change this size to be more suitable for your system +# the max is there to avoid run-away growth on your machine +innodb_data_file_path = ibdata1:10M:autoextend:max:128M +# we keep this at around 25% of of innodb_buffer_pool_size +# sensible values range from 1MB to (1/innodb_log_files_in_group*innodb_buffer_pool_size) +innodb_log_file_size = 5M +# this is the default, increase it if you have very large transactions going on +innodb_log_buffer_size = 8M +# this is the default and won't hurt you +# you shouldn't need to tweak it +innodb_log_files_in_group=2 +# see the innodb config docs, the other options are not always safe +innodb_flush_log_at_trx_commit = 1 +innodb_lock_wait_timeout = 50 +innodb_file_per_table + +[mysqldump] +quick +max_allowed_packet = 16M + +[mysql] +# uncomment the next directive if you are not familiar with SQL +#safe-updates + +[isamchk] +key_buffer = 20M +sort_buffer_size = 20M +read_buffer = 2M +write_buffer = 2M + +[myisamchk] +key_buffer = 20M +sort_buffer_size = 20M +read_buffer = 2M +write_buffer = 2M + +[mysqlhotcopy] +interactive-timeout diff --git a/config-archive/etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml b/config-archive/etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml new file mode 100644 index 00000000..723a10d3 --- /dev/null +++ b/config-archive/etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config-archive/etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml.dist b/config-archive/etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml.dist new file mode 100644 index 00000000..47e592c4 --- /dev/null +++ b/config-archive/etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml.dist @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/cups/printers.conf b/cups/printers.conf index 445dfb1e..cd7e2c2c 100644 --- a/cups/printers.conf +++ b/cups/printers.conf @@ -1,5 +1,5 @@ # Printer configuration file for CUPS v1.4.8 -# Written by cupsd on 2012-02-15 08:16 +# Written by cupsd on 2012-02-26 08:30 # DO NOT EDIT THIS FILE WHEN CUPSD IS RUNNING Info Kyocera FS-1020D diff --git a/cups/printers.conf.O b/cups/printers.conf.O index cc3babb7..03627cfd 100644 --- a/cups/printers.conf.O +++ b/cups/printers.conf.O @@ -1,5 +1,5 @@ # Printer configuration file for CUPS v1.4.8 -# Written by cupsd on 2012-02-14 18:43 +# Written by cupsd on 2012-02-25 07:37 # DO NOT EDIT THIS FILE WHEN CUPSD IS RUNNING Info Kyocera FS-1020D diff --git a/cups/subscriptions.conf b/cups/subscriptions.conf index 296ddccf..4f651c29 100644 --- a/cups/subscriptions.conf +++ b/cups/subscriptions.conf @@ -1,3 +1,11 @@ # Subscription configuration file for CUPS v1.4.8 -# Written by cupsd on 2012-02-15 08:16 -NextSubscriptionId 130 +# Written by cupsd on 2012-02-25 17:28 +NextSubscriptionId 133 + +Events printer-state-changed printer-restarted printer-shutdown printer-stopped printer-added printer-deleted job-state-changed job-created job-completed job-stopped job-progress +Owner frank +LeaseDuration 86400 +Interval 0 +ExpirationTime 1330273704 +NextEventId 316 + diff --git a/cups/subscriptions.conf.O b/cups/subscriptions.conf.O index 8fe0f129..fc2a6f11 100644 --- a/cups/subscriptions.conf.O +++ b/cups/subscriptions.conf.O @@ -1,11 +1,3 @@ # Subscription configuration file for CUPS v1.4.8 -# Written by cupsd on 2012-02-14 00:40 -NextSubscriptionId 130 - -Events printer-state-changed printer-restarted printer-shutdown printer-stopped printer-added printer-deleted job-state-changed job-created job-completed job-stopped job-progress -Owner frank -LeaseDuration 86400 -Interval 0 -ExpirationTime 1329262791 -NextEventId 627 - +# Written by cupsd on 2012-02-20 16:54 +NextSubscriptionId 132 diff --git a/eselect/postgresql/slots/9.1/._cfg0000_base b/eselect/postgresql/slots/9.1/._cfg0000_base deleted file mode 100644 index 479bd41d..00000000 --- a/eselect/postgresql/slots/9.1/._cfg0000_base +++ /dev/null @@ -1 +0,0 @@ -postgres_ebuilds="${postgres_ebuilds} postgresql-base-9.1.2" diff --git a/eselect/postgresql/slots/9.1/._cfg0000_docs b/eselect/postgresql/slots/9.1/._cfg0000_docs deleted file mode 100644 index 8cec4d40..00000000 --- a/eselect/postgresql/slots/9.1/._cfg0000_docs +++ /dev/null @@ -1 +0,0 @@ -postgres_ebuilds="${postgres_ebuilds} postgresql-docs-9.1.2" diff --git a/eselect/postgresql/slots/9.1/._cfg0000_server b/eselect/postgresql/slots/9.1/._cfg0000_server deleted file mode 100644 index 7a0a9c0f..00000000 --- a/eselect/postgresql/slots/9.1/._cfg0000_server +++ /dev/null @@ -1 +0,0 @@ -postgres_ebuilds="${postgres_ebuilds} postgresql-server-9.1.2-r2" diff --git a/eselect/postgresql/slots/9.1/base b/eselect/postgresql/slots/9.1/base index 25e967a5..479bd41d 100644 --- a/eselect/postgresql/slots/9.1/base +++ b/eselect/postgresql/slots/9.1/base @@ -1 +1 @@ -postgres_ebuilds="${postgres_ebuilds} postgresql-base-9.1.1" +postgres_ebuilds="${postgres_ebuilds} postgresql-base-9.1.2" diff --git a/eselect/postgresql/slots/9.1/docs b/eselect/postgresql/slots/9.1/docs index 133932cf..8cec4d40 100644 --- a/eselect/postgresql/slots/9.1/docs +++ b/eselect/postgresql/slots/9.1/docs @@ -1 +1 @@ -postgres_ebuilds="${postgres_ebuilds} postgresql-docs-9.1.1" +postgres_ebuilds="${postgres_ebuilds} postgresql-docs-9.1.2" diff --git a/eselect/postgresql/slots/9.1/server b/eselect/postgresql/slots/9.1/server index cc2c76ba..7a0a9c0f 100644 --- a/eselect/postgresql/slots/9.1/server +++ b/eselect/postgresql/slots/9.1/server @@ -1 +1 @@ -postgres_ebuilds="${postgres_ebuilds} postgresql-server-9.1.1" +postgres_ebuilds="${postgres_ebuilds} postgresql-server-9.1.2-r2" diff --git a/init.d/._cfg0000_net.lo b/init.d/._cfg0000_net.lo deleted file mode 100755 index a9040a38..00000000 --- a/init.d/._cfg0000_net.lo +++ /dev/null @@ -1,765 +0,0 @@ -#!/sbin/runscript -# Copyright (c) 2007-2009 Roy Marples -# Released under the 2-clause BSD license. - -MODULESDIR="${RC_LIBEXECDIR}/net" -MODULESLIST="${RC_SVCDIR}/nettree" -_config_vars="config routes" - -[ -z "${IN_BACKGROUND}" ] && IN_BACKGROUND="NO" - -description="Configures network interfaces." - -# Handy var so we don't have to embed new lines everywhere for array splitting -__IFS=" -" -depend() -{ - local IFACE=${RC_SVCNAME#*.} - local IFVAR=$(shell_var "${IFACE}") - - need localmount - after bootmisc - provide net - keyword -jail -prefix -vserver - - case "${IFACE}" in - lo|lo0);; - *) after net.lo net.lo0 dbus;; - esac - - if [ "$(command -v "depend_${IFVAR}")" = "depend_${IFVAR}" ]; then - depend_${IFVAR} - fi - - local dep= prov= - for dep in need use before after provide keyword; do - eval prov=\$rc_${dep}_${IFVAR} - if [ -n "${prov}" ]; then - ${dep} ${prov} - fi - done -} - -# Support bash arrays - sigh -_array_helper() -{ - local _a= - - eval _a=\$$1 - _a=$(echo "${_a}" | sed -e 's:^[[:space:]]*::' -e 's:[[:space:]]*$::' -e '/^$/d' -e 's:[[:space:]]\{1,\}: :g') - - [ -n "${_a}" ] && printf "%s\n" "${_a}" -} - -_get_array() -{ - local _a= - if [ -n "${BASH}" ]; then - case "$(declare -p "$1" 2>/dev/null)" in - "declare -a "*) - ewarn "You are using a bash array for $1." - ewarn "This feature will be removed in the future." - ewarn "Please see net.example for the correct format for $1." - eval "set -- \"\${$1[@]}\"" - for _a; do - printf "%s\n" "${_a}" - done - return 0 - ;; - esac - fi - - _array_helper $1 -} - -# Flatten bash arrays to simple strings -_flatten_array() -{ - if [ -n "${BASH}" ]; then - case "$(declare -p "$1" 2>/dev/null)" in - "declare -a "*) - ewarn "You are using a bash array for $1." - ewarn "This feature will be removed in the future." - ewarn "Please see net.example for the correct format for $1." - eval "set -- \"\${$1[@]}\"" - for x; do - printf "'%s' " "$(printf "$x" | sed "s:':'\\\'':g")" - done - return 0 - ;; - esac - fi - - _array_helper $1 -} - -_wait_for_carrier() -{ - local timeout= efunc=einfon - - _has_carrier && return 0 - - eval timeout=\$carrier_timeout_${IFVAR} - timeout=${timeout:-${carrier_timeout:-5}} - - # Incase users don't want this nice feature ... - [ ${timeout} -le 0 ] && return 0 - - yesno ${RC_PARALLEL} && efunc=einfo - ${efunc} "Waiting for carrier (${timeout} seconds) " - while [ ${timeout} -gt 0 ]; do - sleep 1 - if _has_carrier; then - [ "${efunc}" = "einfon" ] && echo - eend 0 - return 0 - fi - : $(( timeout -= 1 )) - [ "${efunc}" = "einfon" ] && printf "." - done - - [ "${efunc}" = "einfon" ] && echo - eend 1 - return 1 -} - -_netmask2cidr() -{ - # Some shells cannot handle hex arithmetic, so we massage it slightly - # Buggy shells include FreeBSD sh, dash and busybox. - # bash and NetBSD sh don't need this. - case $1 in - 0x*) - local hex=${1#0x*} quad= - while [ -n "${hex}" ]; do - local lastbut2=${hex#??*} - quad=${quad}${quad:+.}0x${hex%${lastbut2}*} - hex=${lastbut2} - done - set -- ${quad} - ;; - esac - - local i= len= - local IFS=. - for i in $1; do - while [ ${i} -ne 0 ]; do - : $(( len += i % 2 )) - : $(( i >>= 1 )) - done - done - - echo "${len}" -} - -_configure_variables() -{ - local var= v= t= - - for var in ${_config_vars}; do - local v= - for t; do - eval v=\$${var}_${t} - if [ -n "${v}" ]; then - eval ${var}_${IFVAR}=\$${var}_${t} - continue 2 - fi - done - done -} - -_which() -{ - local i OIFS - # Empty - [ -z "$1" ] && return - # check paths - OIFS="$IFS" - IFS=: - for i in $PATH ; do - [ -x $i/$1 ] && echo $i/$1 && break - done - IFS=$OIFS -} - -# Like _which, but also consider shell builtins, and multiple alternatives -_program_available() -{ - [ -z "$1" ] && return 0 - local x= - for x; do - case "${x}" in - /*) [ -x "${x}" ] && break;; - *) type "${x}" >/dev/null 2>&1 && break;; - esac - unset x - done - [ -n "${x}" ] && echo $x && return 0 - return 1 -} - -_show_address() -{ - einfo "received address $(_get_inet_address "${IFACE}")" -} - -# Basically sorts our modules into order and saves the list -_gen_module_list() -{ - local x= f= force=$1 - if ! ${force} && [ -s "${MODULESLIST}" -a "${MODULESLIST}" -nt "${MODULESDIR}" ]; then - local update=false - for x in "${MODULESDIR}"/*.sh; do - [ -e "${x}" ] || continue - if [ "${x}" -nt "${MODULESLIST}" ]; then - update=true - break - fi - done - ${update} || return 0 - fi - - einfo "Caching network module dependencies" - # Run in a subshell to protect the main script - ( - after() { - eval ${MODULE}_after="\"\${${MODULE}_after}\${${MODULE}_after:+ }$*\"" - } - - before() { - local mod=${MODULE} - local MODULE= - for MODULE; do - after "${mod}" - done - } - - program() { - if [ "$1" = "start" -o "$1" = "stop" ]; then - local s="$1" - shift - eval ${MODULE}_program_${s}="\"\${${MODULE}_program_${s}}\${${MODULE}_program_${s}:+ }$*\"" - else - eval ${MODULE}_program="\"\${${MODULE}_program}\${${MODULE}_program:+ }$*\"" - fi - } - - provide() { - eval ${MODULE}_provide="\"\${${MODULE}_provide}\${${MODULE}_provide:+ }$*\"" - local x - for x in $*; do - eval ${x}_providedby="\"\${${MODULE}_providedby}\${${MODULE}_providedby:+ }${MODULE}\"" - done - } - - for MODULE in "${MODULESDIR}"/*.sh; do - sh -n "${MODULE}" || continue - . "${MODULE}" || continue - MODULE=${MODULE#${MODULESDIR}/} - MODULE=${MODULE%.sh} - eval ${MODULE}_depend - MODULES="${MODULES} ${MODULE}" - done - - VISITED= - SORTED= - visit() { - case " ${VISITED} " in - *" $1 "*) return;; - esac - VISITED="${VISITED} $1" - - eval AFTER=\$${1}_after - for MODULE in ${AFTER}; do - eval PROVIDEDBY=\$${MODULE}_providedby - if [ -n "${PROVIDEDBY}" ]; then - for MODULE in ${PROVIDEDBY}; do - visit "${MODULE}" - done - else - visit "${MODULE}" - fi - done - - eval PROVIDE=\$${1}_provide - for MODULE in ${PROVIDE}; do - visit "${MODULE}" - done - - eval PROVIDEDBY=\$${1}_providedby - [ -z "${PROVIDEDBY}" ] && SORTED="${SORTED} $1" - } - - for MODULE in ${MODULES}; do - visit "${MODULE}" - done - - printf "" > "${MODULESLIST}" - i=0 - for MODULE in ${SORTED}; do - eval PROGRAM=\$${MODULE}_program - eval PROGRAM_START=\$${MODULE}_program_start - eval PROGRAM_STOP=\$${MODULE}_program_stop - eval PROVIDE=\$${MODULE}_provide - echo "module_${i}='${MODULE}'" >> "${MODULESLIST}" - echo "module_${i}_program='${PROGRAM}'" >> "${MODULESLIST}" - echo "module_${i}_program_start='${PROGRAM_START}'" >> "${MODULESLIST}" - echo "module_${i}_program_stop='${PROGRAM_STOP}'" >> "${MODULESLIST}" - echo "module_${i}_provide='${PROVIDE}'" >> "${MODULESLIST}" - : $(( i += 1 )) - done - echo "module_${i}=" >> "${MODULESLIST}" - ) - - return 0 -} - -_load_modules() -{ - local starting=$1 mymods= - - # Ensure our list is up to date - _gen_module_list false - if ! . "${MODULESLIST}"; then - _gen_module_list true - . "${MODULESLIST}" - fi - - MODULES= - if [ "${IFACE}" != "lo" -a "${IFACE}" != "lo0" ]; then - eval mymods=\$modules_${IFVAR} - [ -z "${mymods}" ] && mymods=${modules} - fi - - local i=-1 x= mod= f= provides= - while true; do - : $(( i += 1 )) - eval mod=\$module_${i} - [ -z "${mod}" ] && break - [ -e "${MODULESDIR}/${mod}.sh" ] || continue - - eval set -- \$module_${i}_program - if [ -n "$1" ]; then - if ! _program_available "$@" >/dev/null; then - vewarn "Skipping module $mod due to missing program: $@" - continue - fi - fi - if ${starting}; then - eval set -- \$module_${i}_program_start - else - eval set -- \$module_${i}_program_stop - fi - if [ -n "$1" ]; then - if ! _program_available "$@" >/dev/null; then - vewarn "Skipping module $mod due to missing program: $@" - continue - fi - fi - - eval provides=\$module_${i}_provide - if ${starting}; then - case " ${mymods} " in - *" !${mod} "*) continue;; - *" !${provides} "*) [ -n "${provides}" ] && continue;; - esac - fi - MODULES="${MODULES}${MODULES:+ }${mod}" - - # Now load and wrap our functions - if ! . "${MODULESDIR}/${mod}.sh"; then - eend 1 "${RC_SVCNAME}: error loading module \`${mod}'" - exit 1 - fi - - [ -z "${provides}" ] && continue - - # Wrap our provides - local f= - for f in pre_start start post_start; do - eval "${provides}_${f}() { [ "$(command -v "${mod}_${f}")" = "${mod}_${f}" ] || return 0; ${mod}_${f} \"\$@\"; }" - done - - eval module_${mod}_provides="${provides}" - eval module_${provides}_providedby="${mod}" - done - - # Wrap our preferred modules - for mod in ${mymods}; do - case " ${MODULES} " in - *" ${mod} "*) - eval x=\$module_${mod}_provides - [ -z "${x}" ] && continue - for f in pre_start start post_start; do - eval "${x}_${f}() { [ "$(command -v "${mod}_${f}")" = "${mod}_${f}" ] || return 0; ${mod}_${f} \"\$@\"; }" - done - eval module_${x}_providedby="${mod}" - ;; - esac - done - - # Finally remove any duplicated provides from our list if we're starting - # Otherwise reverse the list - local LIST="${MODULES}" p= - MODULES= - if ${starting}; then - for mod in ${LIST}; do - eval x=\$module_${mod}_provides - if [ -n "${x}" ]; then - eval p=\$module_${x}_providedby - [ "${mod}" != "${p}" ] && continue - fi - MODULES="${MODULES}${MODULES:+ }${mod}" - done - else - for mod in ${LIST}; do - MODULES="${mod}${MODULES:+ }${MODULES}" - done - fi - - veinfo "Loaded modules: ${MODULES}" -} - -_load_config() -{ - local config="$(_get_array "config_${IFVAR}")" - local fallback="$(_get_array fallback_${IFVAR})" - - config_index=0 - local IFS="$__IFS" - set -- ${config} - - # We should support a space separated array for cidr configs - # But only as long as they do not contain other parameters for the address - if [ $# = 1 ]; then - unset IFS - set -- ${config} - # Of course, we may have a single address added old style. - # If the NEXT argument is a v4 or v6 address, it's the next config. - # Otherwise, it's arguments to the first config... - if [ "${2#*.*}" = "${2}" -a "${2#*:*}" = "${2}" ]; then - # Not an IPv4/IPv6 - local IFS="$__IFS" - set -- ${config} - fi - fi - - # Ensure that loopback has the correct address - if [ "${IFACE}" = "lo" -o "${IFACE}" = "lo0" ]; then - if [ "$1" != "null" ]; then - config_0="127.0.0.1/8" - config_index=1 - fi - else - if [ -z "$1" ]; then - ewarn "No configuration specified; defaulting to DHCP" - config_0="dhcp" - config_index=1 - fi - fi - - - # We store our config in an array like vars - # so modules can influence it - for cmd; do - eval config_${config_index}="'${cmd}'" - : $(( config_index += 1 )) - done - # Terminate the list - eval config_${config_index}= - - config_index=0 - for cmd in ${fallback}; do - eval fallback_${config_index}="'${cmd}'" - : $(( config_index += 1 )) - done - # Terminate the list - eval fallback_${config_index}= - - # Don't set to zero, so any net modules don't have to do anything extra - config_index=-1 -} - -# Support functions -_run_if() -{ - local cmd=$1 iface=$2 ifr=${IFACE} ifv=${IFVAR} - # Ensure that we don't stamp on real values - local IFACE= IFVAR= - shift - if [ -n "${iface}" ]; then - IFACE="${iface}" - [ "${iface}" != "${ifr}" ] && IFVAR=$(shell_var "${IFACE}") - else - IFACE=${ifr} - IFVAR=${ifv} - fi - ${cmd} -} -interface_exists() -{ - _run_if _exists "$@" -} -interface_up() -{ - _run_if _up "$@" -} -interface_down() -{ - _run_if _down "$@" -} - -start() -{ - local IFACE=${RC_SVCNAME#*.} oneworked=false fallback=false module= - local IFVAR=$(shell_var "${IFACE}") cmd= our_metric= - local metric=0 _up_before_preup - eval _up_before_preup="\$up_before_preup_${IFVAR}" - [ -z "${_up_before_preup}" ] && _up_before_preup=$up_before_preup - - einfo "Bringing up interface ${IFACE}" - eindent - - if [ -z "${MODULES}" ]; then - local MODULES= - _load_modules true - fi - - # We up the iface twice if we have a preup to ensure it's up if - # available in preup and afterwards incase the user inadvertently - # brings it down - if [ "$(command -v preup)" = "preup" ]; then - yesno "${_up_before_preup:-yes}" && _up 2>/dev/null - ebegin "Running preup" - eindent - preup || return 1 - eoutdent - fi - - _up 2>/dev/null - - for module in ${MODULES}; do - if [ "$(command -v "${module}_pre_start")" = "${module}_pre_start" ]; then - ${module}_pre_start || exit $? - fi - done - - if ! _exists; then - eerror "ERROR: interface ${IFACE} does not exist" - eerror "Ensure that you have loaded the correct kernel module for your hardware" - return 1 - fi - - if ! _wait_for_carrier; then - if service_started devd; then - ewarn "no carrier, but devd will start us when we have one" - mark_service_inactive "${RC_SVCNAME}" - else - eerror "no carrier" - fi - return 1 - fi - - local config= config_index= - _load_config - config_index=0 - - eval our_metric=\$metric_${IFVAR} - if [ -n "${our_metric}" ]; then - metric=${our_metric} - elif [ "${IFACE}" != "lo" -a "${IFACE}" != "lo0" ]; then - : $(( metric += $(_ifindex) )) - fi - - while true; do - eval config=\$config_${config_index} - [ -z "${config}" ] && break - - set -- ${config} - if [ "$1" != "null" -a "$1" != "noop" ]; then - ebegin "$1" - fi - eindent - case "$1" in - noop) - if [ -n "$(_get_inet_address)" ]; then - oneworked=true - break - fi - ;; - null) :;; - [0-9]*|*:*) _add_address ${config};; - *) - if [ "$(command -v "${config}_start")" = "${config}_start" ]; then - "${config}"_start - else - eerror "nothing provides \`${config}'" - fi - ;; - esac - if eend $?; then - oneworked=true - else - eval config=\$fallback_${config_index} - if [ -n "${config}" ]; then - fallback=true - eoutdent - ewarn "Trying fallback configuration ${config}" - eindent - eval config_${config_index}=\$config - unset fallback_${config_index} - : $(( config_index -= 1 )) - fi - fi - eoutdent - : $(( config_index += 1 )) - done - - if ! ${oneworked}; then - if [ "$(command -v failup)" = "failup" ]; then - ebegin "Running failup" - eindent - failup - eoutdent - fi - return 1 - fi - - local hidefirstroute=false first=true routes= - if ${fallback}; then - routes="$(_get_array "fallback_routes_${IFVAR}")" - fi - if [ -z "${routes}" ]; then - routes="$(_get_array "routes_${IFVAR}")" - fi - if [ "${IFACE}" = "lo" -o "${IFACE}" = "lo0" ]; then - if [ "${config_0}" != "null" ]; then - routes="127.0.0.0/8 via 127.0.0.1 -${routes}" - hidefirstroute=true - fi - fi - - local OIFS="${IFS}" SIFS="${IFS-y}" - local IFS="$__IFS" - for cmd in ${routes}; do - unset IFS - if ${first}; then - first=false - einfo "Adding routes" - fi - eindent - ebegin ${cmd} - # Work out if we're a host or a net if not told - case ${cmd} in - -net" "*|-host" "*);; - *" "netmask" "*) cmd="-net ${cmd}";; - *.*.*.*/32*) cmd="-host ${cmd}";; - *.*.*.*/*|0.0.0.0|0.0.0.0" "*) cmd="-net ${cmd}";; - default|default" "*) cmd="-net ${cmd}";; - *) cmd="-host ${cmd}";; - esac - if ${hidefirstroute}; then - _add_route ${cmd} >/dev/null 2>&1 - hidefirstroute=false - else - _add_route ${cmd} >/dev/null - fi - eend $? - eoutdent - done - if [ "${SIFS}" = "y" ]; then - unset IFS - else - IFS="${OIFS}" - fi - - for module in ${MODULES}; do - if [ "$(command -v "${module}_post_start")" = "${module}_post_start" ]; then - ${module}_post_start || exit $? - fi - done - - if [ "$(command -v postup)" = "postup" ]; then - ebegin "Running postup" - eindent - postup - eoutdent - fi - - return 0 -} - -stop() -{ - local IFACE=${RC_SVCNAME#*.} module= - local IFVAR=$(shell_var "${IFACE}") opts= - - einfo "Bringing down interface ${IFACE}" - eindent - - if [ -z "${MODULES}" ]; then - local MODULES= - _load_modules false - fi - - if [ "$(command -v predown)" = "predown" ]; then - ebegin "Running predown" - eindent - predown || return 1 - eoutdent - else - if is_net_fs /; then - eerror "root filesystem is network mounted -- can't stop ${IFACE}" - return 1 - fi - fi - - for module in ${MODULES}; do - if [ "$(command -v "${module}_pre_stop")" = "${module}_pre_stop" ]; then - ${module}_pre_stop || exit $? - fi - done - - for module in ${MODULES}; do - if [ "$(command -v "${module}_stop")" = "${module}_stop" ]; then - ${module}_stop - fi - done - - # Only delete addresses for interfaces that exist - if _exists; then - # PPP can manage it's own addresses when IN_BACKGROUND - # Important in case "demand" set on the ppp link - if ! (yesno ${IN_BACKGROUND} && is_ppp) ; then - _delete_addresses "${IFACE}" - fi - fi - - for module in ${MODULES}; do - if [ "$(command -v "${module}_post_stop")" = "${module}_post_stop" ]; then - ${module}_post_stop - fi - done - - # If not in background, and not loopback then bring the interface down - # unless overridden. - if ! yesno ${IN_BACKGROUND} && \ - [ "${IFACE}" != "lo" -a "${IFACE}" != "lo0" ]; then - eval module=\$ifdown_${IFVAR} - module=${module:-${ifdown:-YES}} - yesno ${module} && _down 2>/dev/null - fi - - type resolvconf >/dev/null 2>&1 && resolvconf -d "${IFACE}" 2>/dev/null - - if [ "$(command -v "postdown")" = "postdown" ]; then - ebegin "Running postdown" - eindent - postdown - eoutdent - fi - - return 0 -} diff --git a/init.d/._cfg0000_postgresql-9.1 b/init.d/._cfg0000_postgresql-9.1 deleted file mode 100755 index 01376910..00000000 --- a/init.d/._cfg0000_postgresql-9.1 +++ /dev/null @@ -1,141 +0,0 @@ -#!/sbin/runscript -# Copyright 1999-2010 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: $ - -extra_started_commands="reload" - -get_config() { - [ -f ${PGDATA}/postgresql.conf ] || return 1 - - eval echo $(sed -e 's:#.*::' ${PGDATA}/postgresql.conf | awk '$1 == "'$1'" { print $2 == "=" ? $3 : $2 }') -} - -depend() { - use net - provide postgresql - - if [ "$(get_config log_destination)" = "syslog" ]; then - use logger - fi -} - -configured_port=$(get_config port) -: ${configured_port:=${PGPORT}} -socket_path=$(get_config unix_socket_path) -: ${socket_path:=/var/run/postgresql} - -checkconfig() { - # Check that DATA_DIR has been set and exists - if [ -z ${DATA_DIR} ] ; then - eerror "DATA_DIR not set" - eerror "HINT: Perhaps you need to update /etc/conf.d/postgresql-9.1" - fi - if [ ! -d ${DATA_DIR} ] ; then - eerror "Directory not found: ${DATA_DIR}" - eerror "HINT: Ensure that DATA_DIR points to the right path." - eerror "HINT: Or perhaps you need to create the database cluster:" - eerror " emerge --config dev-db/postgresql-server:9.1" - return 1 - fi - - # Check for the existence of and PostgreSQL's ability to read the config files. - if [ ! -f ${PGDATA}/postgresql.conf -o \ - ! -f ${PGDATA}/pg_hba.conf -o ! -f ${PGDATA}/pg_ident.conf ] ; then - eerror "The following file(s) were not found in ${PGDATA}:" - [ ! -f ${PGDATA}/postgresql.conf ] && eerror " postgresql.conf" - [ ! -f ${PGDATA}/pg_hba.conf ] && eerror " pg_hba.conf" - [ ! -f ${PGDATA}/pg_ident.conf ] && eerror " pg_ident.conf" - eerror "HINT: Try:" - eerror " mv ${DATA_DIR}/*.conf ${PGDATA}" - return 1 - fi - - local file - local failed - for file in pg_hba pg_ident postgresql ; do - file="${PGDATA}/${file}.conf" - su postgres -c "test -r ${file}" || failed="${file} ${failed}" - done - if [ -n "${failed}" ] ; then - eerror "The following file(s) are not readable by 'postgres':" - local x - for x in ${failed} ; do - eerror " ${x}" - done - eerror "HINT: Try: 'chmod 644 ${PGDATA}/*.conf'" - return 1 - fi - - checkpath -d -m 0770 -o postgres:postgres ${socket_path} - if [ -e ${socket_path}/.s.PGSQL.${configured_port} ] ; then - eerror "Socket conflict." - eerror "A server is already listening on:" - eerror " ${socket_path}/.s.PGSQL.${configured_port}" - eerror "HINT: Change PGPORT to listen on a different socket." - return 1 - fi -} - -start() { - checkconfig || return 1 - - ebegin "Starting PostgreSQL" - - rm -f ${DATA_DIR}/postmaster.pid - - local extraenv - local x - for x in ${PG_EXTRA_ENV} ; do - extraenv="${extraenv} --env ${x}" - done - - start-stop-daemon --start \ - --user postgres \ - --exec /usr/lib/postgresql-9.1/bin/postgres \ - --env "PGPORT=${configured_port}" \ - ${extraenv} \ - --wait $((${START_TIMEOUT}*1000)) \ - --pidfile ${DATA_DIR}/postmaster.pid \ - -- -D ${PGDATA} --data-directory=${DATA_DIR} --silent-mode=true ${PGOPTS} - local retval=$? - - if [ $retval -ne 0 ] ; then - eerror "Check the PostgreSQL 9.1 log for a detailed explanation of the above error." - eend $retval - return $retval - fi - - eend $retval -} - -stop() { - local seconds=$(( ${NICE_TIMEOUT} + ${RUDE_TIMEOUT} + ${FORCE_TIMEOUT} )) - ebegin "Stopping PostgreSQL (this can take up to ${seconds} seconds)" - - local retval - local retries=SIGTERM/${NICE_TIMEOUT} - - if [ "${RUDE_QUIT}" != "NO" ] ; then - einfo "RUDE_QUIT enabled." - retries="${retries}/SIGINT/${RUDE_TIMEOUT}" - fi - if [ "${FORCE_QUIT}" = "YES" ] ; then - einfo "FORCE_QUIT enabled." - ewarn "A recover-run might be executed on next startup." - retries="${retries}/SIGQUIT/${FORCE_TIMEOUT}" - fi - - start-stop-daemon --stop \ - --exec /usr/lib/postgresql-9.1/bin/postgres \ - --retry ${retries} \ - --pidfile ${DATA_DIR}/postmaster.pid - - eend -} - -reload() { - ebegin "Reloading PostgreSQL configuration" - kill -HUP $(head -n1 ${DATA_DIR}/postmaster.pid) - eend $? -} diff --git a/init.d/._cfg0000_sysfs b/init.d/._cfg0000_sysfs deleted file mode 100755 index 50c98a98..00000000 --- a/init.d/._cfg0000_sysfs +++ /dev/null @@ -1,104 +0,0 @@ -#!/sbin/runscript -# Copyright (c) 2007-2009 Roy Marples -# Released under the 2-clause BSD license. - -description="Mount the sys filesystem." - -depend() -{ - keyword -prefix -vserver -} - -mount_sys() -{ - grep -Eq "[[:space:]]+sysfs$" /proc/filesystems || return 1 - mountinfo -q /sys && return 0 - - if [ ! -d /sys ]; then - if ! mkdir -m 0755 /sys; then - ewarn "Could not create /sys!" - return 1 - fi - fi - - ebegin "Mounting /sys" - if ! fstabinfo --mount /sys; then - mount -n -t sysfs -o noexec,nosuid,nodev sysfs /sys - fi - eend $? -} - -mount_misc() -{ - # Setup Kernel Support for securityfs - if [ -d /sys/kernel/security ] && \ - ! mountinfo -q /sys/kernel/security; then - if grep -qs securityfs /proc/filesystems; then - ebegin "Mounting security filesystem" - mount -n -t securityfs -o nodev,noexec,nosuid \ - securityfs /sys/kernel/security - eend $? - fi - fi - - # Setup Kernel Support for debugfs - if [ -d /sys/kernel/debug ] && ! mountinfo -q /sys/kernel/debug; then - if grep -qs debugfs /proc/filesystems; then - ebegin "Mounting debug filesystem" - mount -n -t debugfs -o nodev,noexec,nosuid \ - debugfs /sys/kernel/debug - eend $? - fi - fi - - # Setup Kernel Support for configfs - if [ -d /sys/kernel/config ] && ! mountinfo -q /sys/kernel/config; then - if grep -qs configfs /proc/filesystems; then - ebegin "Mounting config filesystem" - mount -n -t configfs -o nodev,noexec,nosuid \ - configfs /sys/kernel/config - eend $? - fi - fi - - # set up kernel support for cgroups - if [ -d /sys/fs/cgroup ] && ! mountinfo -q /sys/fs/cgroup; then - if grep -qs cgroup /proc/filesystems; then - ebegin "Mounting cgroup filesystem" - local opts="nodev,noexec,nosuid,mode=755,size=${rc_cgroupsize:-10m}" - mount -n -t tmpfs -o ${opts} cgroup_root /sys/fs/cgroup - eend $? - fi - fi -} - -mount_cgroups() -{ - yesno ${rc_cgroups:-YES} && [ -e /proc/cgroups ] && \ - mountinfo -q /sys/fs/cgroup || return 0 - - while read name hier groups enabled rest; do - case "${enabled}" in - 1) mkdir /sys/fs/cgroup/${name} - mount -n -t cgroup -o nodev,noexec,nosuid,${name} \ - ${name} /sys/fs/cgroup/${name} - ;; - esac - done < /proc/cgroups -} - -start() -{ - local retval - mount_sys - retval=$? - if [ $retval -eq 0 ]; then - mount_misc - retval=$? - fi - if [ $retval -eq 0 ]; then - mount_cgroups - retval=$? - fi - return $retval -} diff --git a/init.d/net.lo b/init.d/net.lo index 23143639..a9040a38 100755 --- a/init.d/net.lo +++ b/init.d/net.lo @@ -21,7 +21,7 @@ depend() need localmount after bootmisc provide net - keyword -shutdown -jail -prefix -vserver + keyword -jail -prefix -vserver case "${IFACE}" in lo|lo0);; diff --git a/init.d/postgresql-9.1 b/init.d/postgresql-9.1 index a5051a33..01376910 100755 --- a/init.d/postgresql-9.1 +++ b/init.d/postgresql-9.1 @@ -3,18 +3,33 @@ # Distributed under the terms of the GNU General Public License v2 # $Header: $ -opts="${opts} reload" +extra_started_commands="reload" + +get_config() { + [ -f ${PGDATA}/postgresql.conf ] || return 1 + + eval echo $(sed -e 's:#.*::' ${PGDATA}/postgresql.conf | awk '$1 == "'$1'" { print $2 == "=" ? $3 : $2 }') +} depend() { - use net - provide postgresql - provide postgresql-9.1 + use net + provide postgresql + + if [ "$(get_config log_destination)" = "syslog" ]; then + use logger + fi } +configured_port=$(get_config port) +: ${configured_port:=${PGPORT}} +socket_path=$(get_config unix_socket_path) +: ${socket_path:=/var/run/postgresql} + checkconfig() { + # Check that DATA_DIR has been set and exists if [ -z ${DATA_DIR} ] ; then eerror "DATA_DIR not set" - eerror "HINT: Did you not update /etc/conf.d/postgresql-9.1" + eerror "HINT: Perhaps you need to update /etc/conf.d/postgresql-9.1" fi if [ ! -d ${DATA_DIR} ] ; then eerror "Directory not found: ${DATA_DIR}" @@ -23,16 +38,19 @@ checkconfig() { eerror " emerge --config dev-db/postgresql-server:9.1" return 1 fi + + # Check for the existence of and PostgreSQL's ability to read the config files. if [ ! -f ${PGDATA}/postgresql.conf -o \ ! -f ${PGDATA}/pg_hba.conf -o ! -f ${PGDATA}/pg_ident.conf ] ; then eerror "The following file(s) were not found in ${PGDATA}:" [ ! -f ${PGDATA}/postgresql.conf ] && eerror " postgresql.conf" [ ! -f ${PGDATA}/pg_hba.conf ] && eerror " pg_hba.conf" [ ! -f ${PGDATA}/pg_ident.conf ] && eerror " pg_ident.conf" - eerror "HINT: Try:" - eerror "mv ${DATA_DIR}/*.conf ${PGDATA}" + eerror "HINT: Try:" + eerror " mv ${DATA_DIR}/*.conf ${PGDATA}" return 1 fi + local file local failed for file in pg_hba pg_ident postgresql ; do @@ -48,10 +66,12 @@ checkconfig() { eerror "HINT: Try: 'chmod 644 ${PGDATA}/*.conf'" return 1 fi - if [ -e /var/run/postgresql/.s.PGSQL.${PGPORT} ] ; then + + checkpath -d -m 0770 -o postgres:postgres ${socket_path} + if [ -e ${socket_path}/.s.PGSQL.${configured_port} ] ; then eerror "Socket conflict." eerror "A server is already listening on:" - eerror " /var/run/postgresql/.s.PGSQL.${PGPORT}" + eerror " ${socket_path}/.s.PGSQL.${configured_port}" eerror "HINT: Change PGPORT to listen on a different socket." return 1 fi @@ -62,18 +82,23 @@ start() { ebegin "Starting PostgreSQL" - if [ -f ${DATA_DIR}/postmaster.pid ] ; then - rm -f ${DATA_DIR}/postmaster.pid - fi + rm -f ${DATA_DIR}/postmaster.pid - local retval + local extraenv + local x + for x in ${PG_EXTRA_ENV} ; do + extraenv="${extraenv} --env ${x}" + done - su -l postgres \ - -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ - /usr/lib/postgresql-9.1/bin/pg_ctl \ - start ${WAIT_FOR_START} -t ${START_TIMEOUT} -s -D ${DATA_DIR} \ - -o '-D ${PGDATA} --data-directory=${DATA_DIR} --silent-mode=true ${PGOPTS}'" - retval=$? + start-stop-daemon --start \ + --user postgres \ + --exec /usr/lib/postgresql-9.1/bin/postgres \ + --env "PGPORT=${configured_port}" \ + ${extraenv} \ + --wait $((${START_TIMEOUT}*1000)) \ + --pidfile ${DATA_DIR}/postmaster.pid \ + -- -D ${PGDATA} --data-directory=${DATA_DIR} --silent-mode=true ${PGOPTS} + local retval=$? if [ $retval -ne 0 ] ; then eerror "Check the PostgreSQL 9.1 log for a detailed explanation of the above error." @@ -81,112 +106,36 @@ start() { return $retval fi - # The following is to catch the case of an already running server - # in which pg_ctl doesn't know to which server it connected to and - # falsely reports the server as 'up' - if [ ! -f ${DATA_DIR}/postmaster.pid ] ; then - eerror "The PID file doesn't exist but pg_ctl reported a running server." - eerror "Please check whether there is another server running on the same port or read the log-file." - eend 1 - return 1 - fi - eend $retval } stop() { - ebegin "Stopping PostgreSQL (this can take up to $(( ${NICE_TIMEOUT} + ${RUDE_TIMEOUT} + ${FORCE_TIMEOUT} )) seconds)" + local seconds=$(( ${NICE_TIMEOUT} + ${RUDE_TIMEOUT} + ${FORCE_TIMEOUT} )) + ebegin "Stopping PostgreSQL (this can take up to ${seconds} seconds)" local retval - - if [ "${NICE_QUIT}" != "NO" ] ; then - su -l postgres \ - -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ - /usr/lib/postgresql-9.1/bin/pg_ctl \ - stop ${WAIT_FOR_STOP} -t ${NICE_TIMEOUT} -s -D ${DATA_DIR} \ - -m smart" - retval=$? - - if [ $retval -eq 0 ] ; then - eend $retval - return $retval - fi - - ewarn "Shutting down the server gracefully failed." - ewarn "Probably because some clients did not disconnect within ${NICE_TIMEOUT} seconds." - else - ewarn "NICE_QUIT disabled." - ewarn "You really should have it enabled." - fi + local retries=SIGTERM/${NICE_TIMEOUT} if [ "${RUDE_QUIT}" != "NO" ] ; then - ewarn "RUDE_QUIT enabled." - ewarn "Going to shutdown the server anyway." - - su -l postgres \ - -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ - /usr/lib/postgresql-9.1/bin/pg_ctl \ - stop ${WAIT_FOR_STOP} -t ${RUDE_TIMEOUT} -s -D ${DATA_DIR} \ - -m fast" - retval=$? - - if [ $retval -eq 0 ] ; then - eend $retval - return $retval - fi - - eerror "Failed to shutdown server." - else - ewarn "RUDE_QUIT disabled." + einfo "RUDE_QUIT enabled." + retries="${retries}/SIGINT/${RUDE_TIMEOUT}" fi - if [ "${FORCE_QUIT}" = "YES" ] ; then - ewarn "FORCE_QUIT enabled." - ewarn "Forcing server to shutdown." - ewarn "A recover-run will be executed on the next startup." - - su -l postgres \ - -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ - /usr/lib/postgresql-9.1/bin/pg_ctl \ - stop ${WAIT_FOR_STOP} -t ${FORCE_TIMEOUT} -s -D ${DATA_DIR} \ - -m immediate" - - retval=$? - - if [ $retval -eq 0 ] ; then - ewarn "Server forced down." - eend $retval - return $retval - fi - - eerror "Forced shutdown failed!!!" - eerror "Something is wrong with your system." - eerror "Please take care of it manually." - eerror "Unable to stop server." - eend $retval - return $retval - else - ewarn "FORCE_QUIT disabled." - eerror "Unable to shutdown server." - eend 1 - return 1 + einfo "FORCE_QUIT enabled." + ewarn "A recover-run might be executed on next startup." + retries="${retries}/SIGQUIT/${FORCE_TIMEOUT}" fi -} -reload() { - ebegin "Reloading PostgreSQL configuration" - su -l postgres \ - -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ - /usr/lib/postgresql-9.1/bin/pg_ctl \ - reload -s -D ${DATA_DIR}" - eend $? + start-stop-daemon --stop \ + --exec /usr/lib/postgresql-9.1/bin/postgres \ + --retry ${retries} \ + --pidfile ${DATA_DIR}/postmaster.pid + + eend } -status() { +reload() { ebegin "Reloading PostgreSQL configuration" - su -l postgres \ - -c "env PGPORT=\"${PGPORT}\" ${PG_EXTRA_ENV} \ - /usr/lib/postgresql-9.1/bin/pg_ctl \ - status -D ${DATA_DIR}" + kill -HUP $(head -n1 ${DATA_DIR}/postmaster.pid) eend $? } diff --git a/init.d/sysfs b/init.d/sysfs index dd3fc0ee..50c98a98 100755 --- a/init.d/sysfs +++ b/init.d/sysfs @@ -74,15 +74,13 @@ mount_misc() mount_cgroups() { - yesno ${rc_cgroups:-YES} || return 0 - if [ ! -e /proc/cgroups ]; then - return 0 - fi + yesno ${rc_cgroups:-YES} && [ -e /proc/cgroups ] && \ + mountinfo -q /sys/fs/cgroup || return 0 while read name hier groups enabled rest; do case "${enabled}" in 1) mkdir /sys/fs/cgroup/${name} - mount -t cgroup -o nodev,noexec,nosuid,${name} \ + mount -n -t cgroup -o nodev,noexec,nosuid,${name} \ ${name} /sys/fs/cgroup/${name} ;; esac diff --git a/ldap.conf.sudo b/ldap.conf.sudo index 934f1b99..c5d51f95 100644 --- a/ldap.conf.sudo +++ b/ldap.conf.sudo @@ -1,5 +1,6 @@ -# See ldap.conf(5) and README.LDAP for details\n" -# This file should only be readable by root\n\n" -# supported directives: host, port, ssl, ldap_version\n" -# uri, binddn, bindpw, sudoers_base, sudoers_debug\n" +# See ldap.conf(5) and README.LDAP for details +# This file should only be readable by root + +# supported directives: host, port, ssl, ldap_version +# uri, binddn, bindpw, sudoers_base, sudoers_debug # tls_{checkpeer,cacertfile,cacertdir,randfile,ciphers,cert,key diff --git a/mysql/._cfg0000_my.cnf b/mysql/._cfg0000_my.cnf deleted file mode 100644 index 9a439848..00000000 --- a/mysql/._cfg0000_my.cnf +++ /dev/null @@ -1,146 +0,0 @@ -# /etc/mysql/my.cnf: The global mysql configuration file. -# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/files/my.cnf-5.1,v 1.3 2012/02/15 02:07:21 jmbsvicetto Exp $ - -# The following options will be passed to all MySQL clients -[client] -#password = your_password -port = 3306 -socket = /var/run/mysqld/mysqld.sock - -[mysql] -character-sets-dir=/usr/share/mysql/charsets -default-character-set=utf8 - -[mysqladmin] -character-sets-dir=/usr/share/mysql/charsets -default-character-set=utf8 - -[mysqlcheck] -character-sets-dir=/usr/share/mysql/charsets -default-character-set=utf8 - -[mysqldump] -character-sets-dir=/usr/share/mysql/charsets -default-character-set=utf8 - -[mysqlimport] -character-sets-dir=/usr/share/mysql/charsets -default-character-set=utf8 - -[mysqlshow] -character-sets-dir=/usr/share/mysql/charsets -default-character-set=utf8 - -[myisamchk] -character-sets-dir=/usr/share/mysql/charsets - -[myisampack] -character-sets-dir=/usr/share/mysql/charsets - -# use [safe_mysqld] with mysql-3 -[mysqld_safe] -err-log = /var/log/mysql/mysql.err - -# add a section [mysqld-4.1] or [mysqld-5.0] for specific configurations -[mysqld] -character-set-server = utf8 -user = mysql -port = 3306 -socket = /var/run/mysqld/mysqld.sock -pid-file = /var/run/mysqld/mysqld.pid -log-error = /var/log/mysql/mysqld.err -basedir = /usr -datadir = /data/mysql -skip-external-locking -key_buffer = 16M -max_allowed_packet = 1M -table_open_cache = 64 -sort_buffer_size = 512K -net_buffer_length = 8K -read_buffer_size = 256K -read_rnd_buffer_size = 512K -myisam_sort_buffer_size = 8M -language = /usr/share/mysql/english - -# security: -# using "localhost" in connects uses sockets by default -# skip-networking -bind-address = 127.0.0.1 - -log-bin -server-id = 1 - -# point the following paths to different dedicated disks -tmpdir = /tmp/ -#log-update = /path-to-dedicated-directory/hostname - -# you need the debug USE flag enabled to use the following directives, -# if needed, uncomment them, start the server and issue -# #tail -f /tmp/mysqld.sql /tmp/mysqld.trace -# this will show you *exactly* what's happening in your server ;) - -#log = /tmp/mysqld.sql -#gdb -#debug = d:t:i:o,/tmp/mysqld.trace -#one-thread - -# uncomment the following directives if you are using BDB tables -#bdb_cache_size = 4M -#bdb_max_lock = 10000 - -# the following is the InnoDB configuration -# if you wish to disable innodb instead -# uncomment just the next line -#skip-innodb -# -# the rest of the innodb config follows: -# don't eat too much memory, we're trying to be safe on 64Mb boxes -# you might want to bump this up a bit on boxes with more RAM -innodb_buffer_pool_size = 16M -# this is the default, increase it if you have lots of tables -innodb_additional_mem_pool_size = 2M -# -# i'd like to use /var/lib/mysql/innodb, but that is seen as a database :-( -# and upstream wants things to be under /var/lib/mysql/, so that's the route -# we have to take for the moment -#innodb_data_home_dir = /var/lib/mysql/ -#innodb_log_arch_dir = /var/lib/mysql/ -#innodb_log_group_home_dir = /var/lib/mysql/ -# you may wish to change this size to be more suitable for your system -# the max is there to avoid run-away growth on your machine -innodb_data_file_path = ibdata1:10M:autoextend:max:128M -# we keep this at around 25% of of innodb_buffer_pool_size -# sensible values range from 1MB to (1/innodb_log_files_in_group*innodb_buffer_pool_size) -innodb_log_file_size = 5M -# this is the default, increase it if you have very large transactions going on -innodb_log_buffer_size = 8M -# this is the default and won't hurt you -# you shouldn't need to tweak it -innodb_log_files_in_group=2 -# see the innodb config docs, the other options are not always safe -innodb_flush_log_at_trx_commit = 1 -innodb_lock_wait_timeout = 50 -innodb_file_per_table - -[mysqldump] -quick -max_allowed_packet = 16M - -[mysql] -# uncomment the next directive if you are not familiar with SQL -#safe-updates - -[isamchk] -key_buffer = 20M -sort_buffer_size = 20M -read_buffer = 2M -write_buffer = 2M - -[myisamchk] -key_buffer = 20M -sort_buffer_size = 20M -read_buffer = 2M -write_buffer = 2M - -[mysqlhotcopy] -interactive-timeout diff --git a/mysql/my.cnf b/mysql/my.cnf index b324ed2c..775dce06 100644 --- a/mysql/my.cnf +++ b/mysql/my.cnf @@ -1,5 +1,5 @@ # /etc/mysql/my.cnf: The global mysql configuration file. -# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/files/my.cnf-5.1,v 1.2 2010/03/24 18:26:09 robbat2 Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql/files/my.cnf-5.1,v 1.3 2012/02/15 02:07:21 jmbsvicetto Exp $ # The following options will be passed to all MySQL clients [client] @@ -58,6 +58,7 @@ skip-external-locking key_buffer = 16M max_allowed_packet = 1M table_cache = 64 +table_open_cache = 64 sort_buffer_size = 512K net_buffer_length = 8K read_buffer_size = 256K diff --git a/postfix/main.cf b/postfix/main.cf index dba4ff00..76d1551d 100644 --- a/postfix/main.cf +++ b/postfix/main.cf @@ -264,7 +264,7 @@ unknown_local_recipient_reject_code = 550 #mynetworks = 168.100.189.0/28, 127.0.0.0/8 #mynetworks = $config_directory/mynetworks #mynetworks = hash:/etc/postfix/network_table -mynetworks = 10.12.11.0/24 +mynetworks = 10.12.11.0/24, 127.0.0.0/8, [::1]/128, [2001:6f8:1db7::]/64 # The relay_domains parameter restricts what destinations this system will # relay mail to. See the smtpd_recipient_restrictions description in diff --git a/syslog-ng/syslog-ng.conf b/syslog-ng/syslog-ng.conf index 3a3c4f16..20e93366 100644 --- a/syslog-ng/syslog-ng.conf +++ b/syslog-ng/syslog-ng.conf @@ -53,6 +53,13 @@ destination d_console_12 { file("/dev/tty12"); }; #destination d_xconsole { pipe("/dev/xconsole"); }; destination d_xconsole { pipe("/dev/console"); }; +# By default messages are logged to tty12... +#destination console_all { file("/dev/tty12"); }; +# ...if you intend to use /dev/console for programs like xconsole +# you can comment out the destination line above that references /dev/tty12 +# and uncomment the line below. +#destination console_all { file("/dev/console"); }; + ######################################################### # Filter-Definitionen @@ -86,12 +93,5 @@ log { source(src); filter(f_syslog); destination(d_syslog); }; log { source(src); filter(f_debug); destination(d_debug); }; log { source(src); destination(d_all); }; -# By default messages are logged to tty12... -destination console_all { file("/dev/tty12"); }; -# ...if you intend to use /dev/console for programs like xconsole -# you can comment out the destination line above that references /dev/tty12 -# and uncomment the line below. -#destination console_all { file("/dev/console"); }; - #log { source(src); destination(messages); }; #log { source(src); destination(console_all); }; diff --git a/xdg/xfce4/xfconf/xfce-perchannel-xml/._cfg0000_xfce4-keyboard-shortcuts.xml b/xdg/xfce4/xfconf/xfce-perchannel-xml/._cfg0000_xfce4-keyboard-shortcuts.xml deleted file mode 100644 index 47e592c4..00000000 --- a/xdg/xfce4/xfconf/xfce-perchannel-xml/._cfg0000_xfce4-keyboard-shortcuts.xml +++ /dev/null @@ -1,71 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml b/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml index 723a10d3..47e592c4 100644 --- a/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml +++ b/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml @@ -8,6 +8,8 @@ + +