Package: man-db
Version: 2.5.7-8
Severity: wishlist
Warnings and error messages are important to show possible
defects in a manual. Redirecting them to a file (e.g.
"/var/log/mandb.err") is better than discarding them.
I changed the file "man-db" in both "/etc/cron.daily" and
"/etc/cron.weekly" to catch errors in man pages.
The last part of my file in "cron.daily" is
#--Start of example----#
# regenerate man database
if [ -x /usr/bin/mandb ]; then
temp_err=$(mktemp --tmpdir cron.daily.man-db.$$.XXXX)
err_file='/var/log/mandb.err'
# --pidfile /dev/null so it always starts; mandb isn't really a daemon,
# but we want to start it like one.
start-stop-daemon --start --pidfile /dev/null \
--startas /usr/bin/mandb --oknodo --chuid man \
$iosched_idle \
-- --no-purge 2>&1 | \
tr '\015' '\012' | \
grep -F -e 'mandb' -e 'warn' > \
$temp_err || :
if test -s $temp_err
then
{ date ; echo '####' ; cat $temp_err ;\
echo '#####' ; } >> $err_file
fi
rm $temp_err
fi
exit 0
#--End of example----#
For the file in "/etc/cron.weekly" the name "cron.daily" is
changed to "cron.weekly".
Example of the output to file "$err_file" is:
Sat Aug 27 19:05:33 GMT 2011
####
/usr/bin/mandb: warning: /usr/share/man/man1/dotlockfile.1.gz: whatis parse for
dotlockfile(1) failed
/usr/bin/mandb: warning: /usr/share/man/man1/vlna.1.gz: whatis parse for
vlna(1) failed
#####
A rule for logrotate could be put into "/etc/logrotate.conf",
e.g.
/var/log/mandb.err {
missingok
size=10k
}
-- System Information:
Debian Release: 6.0.2
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: i386 (i586)
Kernel: Linux 2.6.32-35squeeze2
Locale: LANG=is_IS, LC_CTYPE=is_IS (charmap=ISO-8859-1)
Shell: /bin/sh linked to /bin/bash
Versions of packages man-db depends on:
ii bsdmainutils 8.0.13 collection of more utilities from
ii debconf [debconf-2.0] 1.5.36.1 Debian configuration management sy
ii dpkg 1.15.8.11 Debian package management system
ii groff-base 1.20.1-10 GNU troff text-formatting system (
ii libc6 2.11.2-10 Embedded GNU C Library: Shared lib
ii libgdbm3 1.8.3-9 GNU dbm database routines (runtime
ii zlib1g 1:1.2.3.4.dfsg-3 compression library - runtime
man-db recommends no packages.
Versions of packages man-db suggests:
ii groff 1.20.1-10 GNU troff text-formatting system
ii iceweasel [www-browser] 3.5.16-9 Web browser based on Firefox
ii less 436-1 pager program similar to more
ii w3m [www-browser] 0.5.2-9 WWW browsable pager with excellent
-- Configuration Files:
/etc/cron.daily/man-db changed [not included]
/etc/cron.weekly/man-db changed [not included]
-- debconf information:
man-db/build-database: true
* man-db/rebuild-database: false
* man-db/install-setuid: false
man-db/auto-update: true
--
Bjarni I. Gíslason
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]