/lib/systemd/system-shutdown/mdadm.shutdown is in mdadm 4.0-2ubuntu1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 | #!/bin/sh
# We need to ensure all md arrays with external metadata
# (e.g. IMSM, DDF) are clean before completing the shutdown.
/sbin/mdadm --wait-clean --scan
|