zfs/cmd/zed/zed.d
Prawn 77f09e2932
ZED/zfs-list-cacher.sh: don't exit on ignored event type
Check for the history_event type instead.

The zfs-list-cacher.sh script currently respects the event types
excluded from syslog(!) in ZED_SYSLOG_SUBCLASS_EXCLUDE.
This makes little sense in this single-purpose script and
silently breaks when history_events are excluded from syslog,
which is the default since 13d65987a9.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: InsanePrawn <insane.prawny@gmail.com>
Closes #11164
Closes #11347
2020-12-18 09:34:10 -08:00
..
.gitignore
Makefile.am Centralize variable substitution 2020-07-14 17:33:44 -07:00
README
all-debug.sh
all-syslog.sh zed syslog entries drop important info 2020-10-19 11:01:00 -07:00
data-notify.sh
generic-notify.sh
history_event-zfs-list-cacher.sh.in ZED/zfs-list-cacher.sh: don't exit on ignored event type 2020-12-18 09:34:10 -08:00
pool_import-led.sh
resilver_finish-notify.sh
resilver_finish-start-scrub.sh Add device rebuild feature 2020-07-03 11:05:50 -07:00
scrub_finish-notify.sh
statechange-led.sh
statechange-notify.sh
trim_finish-notify.sh Add trim_finish notify script for ZED 2020-06-24 16:57:13 -07:00
vdev_attach-led.sh
vdev_clear-led.sh
zed-functions.sh
zed.rc zed syslog entries drop important info 2020-10-19 11:01:00 -07:00

README

Shell scripts are the recommended choice for ZEDLETs that mostly call
other utilities and do relatively little data manipulation.

Shell scripts MUST work on both bash and dash.

Shell scripts MUST run cleanly through ShellCheck:
  http://www.shellcheck.net/

General functions reside in "zed-functions.sh".  Use them where applicable.

Additional references that may be of use:

  Google Shell Style Guide
  https://github.com/google/styleguide/blob/gh-pages/shell.xml

  Dash as /bin/sh
  https://wiki.ubuntu.com/DashAsBinSh

  Common shell script mistakes
  http://www.pixelbeat.org/programming/shell_script_mistakes.html

  Filenames and Pathnames in Shell: How to do it Correctly
  http://www.dwheeler.com/essays/filenames-in-shell.html

  Autoconf: Portable Shell Programming
  https://www.gnu.org/software/autoconf/manual/autoconf.html#Portable-Shell

Please BE CONSISTENT with the existing style, check for errors,
minimize dependencies where possible, try to be portable,
and comment anything non-obvious.  Festina lente.