There's already a tool to do exactly that: checkpath (see man 8 runscript), for example "checkpath -d -m 0770 -o <user>:<group> /var/run/heartbeat, but apart from that, your fix seems correct.
Regards, Luis
signature.asc
Description: PGP signature
There's already a tool to do exactly that: checkpath (see man 8 runscript), for example "checkpath -d -m 0770 -o <user>:<group> /var/run/heartbeat, but apart from that, your fix seems correct.
Regards, Luis
signature.asc
Description: PGP signature