extract pack-dir to process single storage group directory
this allows better usage of traps to clean up artifacts on exit or interrupt
Skip flag files if an answer file already exists
Improve logging and cleanup
Use lock directory instead of lock file, because
mkdir is supposed to be atomic (also on NFS?)
filter files in flag file directory to match pnfsid pattern