I think that you want
system instead of
exec. Note that
exec will never return. (see both entries in perlfunc). Or you might want to just
fork the other program off... Also check out the Q&A section under
QandASection: programs and processes
also,
chiefdaemon.cgi sounds like it might be better suited as a cronjob (or set of cronjobs) .. do you have crontab access? And also, why is a cgi program doing cron'd ("timed loop") stuff (as opposed to a standalone script, perhaps w/shared code)?