in reply to problems with fork
Your getstore is being executed by the parent. fork returns the PID to the parent, so the truth result of your if conditional means you are in the parent. A return value of 0 means you're inside the child. Also check a return of undef to make sure fork didn't puke.
In Section
Seekers of Perl Wisdom