Core File Deletion
In this example, we automatically and routinely delete core files on data disks.
The DeleteCoreFiles script just operates silently (although every file removal command is logged in the alert's log file).
DeleteCoreFiles makes reference to the =dirsuser_obj macro, which resolves to the name of the DirsUser.obj file. The script follows.
DeleteCoreFiles init status =piktstatus level =piktlevel task "Automatically delete core files on data disks" input file "=dirsuser_obj" dat $filesystem 1 rule =exec "=find $filesystem -type f -name core -exec =lld {} \\; >> =notice_log -exec =rm {} \\; 2>/dev/null"
For more examples, see Samples.