I tried booting with systemd and two custom hooks I have that create the
/var directory on tmpfs didn't work. Google doesn't help here and my
experience with systemd is in its infancy, so is there specific action I
My custom hooks are set to run during sysinit_postmount and
shutdown_preumount, see attached file for full source.
Thanks in advance,
function varsync_start ()
# Assuming that we mounted /var as tmpfs in the previous step
stat_busy "Rsyncing /var-sync/ to /var/"
/usr/bin/rsync -ax /var-sync/ /var/
function varsync_stop ()
# saving the /var filesystem from the tmpfs
echo -e 'y
y' | /usr/bin/pacman -Scc >/dev/null
stat_busy "Rsyncing /var/ to /var-sync/"
/usr/bin/rsync -ax --delete /var/ /var-sync/