Bug 188893 - [patch] periodic(8): ZFS periodic information - improvement
Summary: [patch] periodic(8): ZFS periodic information - improvement
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: conf (show other bugs)
Version: unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-04-22 16:20 UTC by dirkx
Modified: 2017-12-31 22:23 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description dirkx 2014-04-22 16:20:01 UTC
Would be nice to have something like below in /etc/periodic/daily - as
to show the status of the ZFS file system when such is enabled.

Thanks,

Dw.

Fix: 

#!/bin/sh -
#
# $FreeBSD$
#

if [ -r /etc/defaults/periodic.conf ]; then
	. /etc/defaults/periodic.conf
	source_periodic_confs
fi

rc=0

case "${zfs_enable:-YES}" in
	[Nn][Oo])
	;;
	*)
	echo ZFS Pool status
	echo ===============
	echo
	zpool status || rc=$?
	echo
	echo Recent changes:
	zpool history  | grep -e `date +%Y-%m-%d` -e `date -v-24H +%Y-%m-%d`
	echo
	;;
esac

exit $rc
Comment 1 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 07:59:26 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped