Deleted Added
full compact
440.status-mailq (107674) 440.status-mailq (155422)
1#!/bin/sh
2#
1#!/bin/sh
2#
3# $FreeBSD: head/etc/periodic/daily/440.status-mailq 107674 2002-12-07 23:37:44Z keramida $
3# $FreeBSD: head/etc/periodic/daily/440.status-mailq 155422 2006-02-07 08:21:06Z matteo $
4#
5
6# If there is a global system configuration file, suck it in.
7#
8if [ -r /etc/defaults/periodic.conf ]
9then
10 . /etc/defaults/periodic.conf
11 source_periodic_confs

--- 16 unchanged lines hidden (view full) ---

28 egrep -e '^[[:space:]]+[^[:space:]]+@' |
29 sort |
30 uniq -c |
31 sort -nr |
32 awk '$1 > 1 {print $1, $2}';;
33 *)
34 mailq;;
35 esac | tee /dev/stderr | fgrep -v 'mqueue is empty' | wc -l)
4#
5
6# If there is a global system configuration file, suck it in.
7#
8if [ -r /etc/defaults/periodic.conf ]
9then
10 . /etc/defaults/periodic.conf
11 source_periodic_confs

--- 16 unchanged lines hidden (view full) ---

28 egrep -e '^[[:space:]]+[^[:space:]]+@' |
29 sort |
30 uniq -c |
31 sort -nr |
32 awk '$1 > 1 {print $1, $2}';;
33 *)
34 mailq;;
35 esac | tee /dev/stderr | fgrep -v 'mqueue is empty' | wc -l)
36 [ $rc -gt 1 ] && rc=1
36 [ $rc -gt 1 ] && rc=1 || rc=0
37
38 case "$daily_status_include_submit_mailq" in
39 [Yy][Ee][Ss])
40 if [ -f /etc/mail/submit.cf ]
41 then
42 echo ""
43 echo "Mail in submit queue:"
44
37
38 case "$daily_status_include_submit_mailq" in
39 [Yy][Ee][Ss])
40 if [ -f /etc/mail/submit.cf ]
41 then
42 echo ""
43 echo "Mail in submit queue:"
44
45 rc=$(case "$daily_status_mailq_shorten" in
45 rc_submit=$(case "$daily_status_mailq_shorten" in
46 [Yy][Ee][Ss])
47 mailq -Ac |
48 egrep -e '^[[:space:]]+[^[:space:]]+@' |
49 sort |
50 uniq -c |
51 sort -nr |
52 awk '$1 > 1 {print $1, $2}';;
53 *)
54 mailq -Ac;;
55 esac | tee /dev/stderr | fgrep -v 'mqueue is empty' | wc -l)
46 [Yy][Ee][Ss])
47 mailq -Ac |
48 egrep -e '^[[:space:]]+[^[:space:]]+@' |
49 sort |
50 uniq -c |
51 sort -nr |
52 awk '$1 > 1 {print $1, $2}';;
53 *)
54 mailq -Ac;;
55 esac | tee /dev/stderr | fgrep -v 'mqueue is empty' | wc -l)
56 [ $rc -gt 1 ] && rc=1
56 [ $rc_submit -gt 1 ] && rc=1
57 fi;;
58 esac
59 fi;;
60
61 *) rc=0;;
62esac
63
64exit $rc
57 fi;;
58 esac
59 fi;;
60
61 *) rc=0;;
62esac
63
64exit $rc