]>
Commit | Line | Data |
---|---|---|
d0ff1643 | 1 | #!/bin/sh |
568331c6 | 2 | PATH=/bin:/usr/ucb:/usr/bin |
bd913bc7 | 3 | root=/usr/local/sendmail |
f4f32185 | 4 | |
d0ff1643 | 5 | MR_MKCRED=47836474 |
568331c6 | 6 | |
bd913bc7 | 7 | cat $root/etc/aliases.legacy > $root/etc/aliases.tmp |
8 | cat $root/etc/aliases.new >> $root/etc/aliases.tmp | |
9 | cat $root/etc/aliases.local >> $root/etc/aliases.tmp | |
10 | mv $root/etc/aliases.tmp $root/etc/aliases.new | |
48eeb70c | 11 | |
bd913bc7 | 12 | cp /dev/null $root/etc/aliases.new.db |
48eeb70c | 13 | |
bd913bc7 | 14 | $root/sbin/sendmail -bi -oA$root/etc/aliases.new |
d0ff1643 | 15 | if [ $? != 0 ]; then |
16 | exit $MR_MKCRED | |
bd913bc7 | 17 | fi |
d0ff1643 | 18 | |
bd913bc7 | 19 | kill `ps -el | grep "sendmail" | egrep -v "grep|mqueue.stall" | awk '{print $4}'` |
48eeb70c | 20 | sleep 60 |
21 | ||
bd913bc7 | 22 | mv $root/etc/aliases $root/etc/aliases.old |
23 | mv $root/etc/aliases.db $root/etc/aliases.old.db | |
24 | mv $root/etc/aliases.new $root/etc/aliases | |
25 | mv $root/etc/aliases.new.db $root/etc/aliases.db | |
48eeb70c | 26 | |
27 | cd /usr/spool/mqueue | |
28 | rm -f xf* tf* lf* nf* | |
29 | ||
bd913bc7 | 30 | #$root/sbin/sendmail -bd |
31 | #$root/sbin/sendmail -q20m | |
32 | ||
33 | sh /etc/init.d/sendmail start | |
d0ff1643 | 34 | |
568331c6 | 35 | rm -f $0 |
d0ff1643 | 36 | exit 0 |
37 | ||
38 | # $Header$ |