The perlipc documentation for Perl details how to properly daemonize a process on Unix. Programs that do not implement this code require shell workarounds to run properly in the background. Other options include:
- POE - portable multitasking and networking framework for Perl. Allows for nifty services such as pastebot.
- Various other modules on the Comprehensive Perl Archive Network (CPAN).
- Win32::Daemon - allow Perl scripts to run as Windows services. Example schedule_cfexecd.pl script that ensures another process, cfexecd, runs periodically. Written as Windows task scheduler randomly corrupted itself on Windows XP systems.
Perl threads are a horrible solution to most any problem. Avoid them.