Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^5: System and CGI - File Created but not the Content

by moritz (Cardinal)
on Sep 18, 2007 at 12:53 UTC ( #639631=note: print w/ replies, xml ) Need Help??


in reply to Re^4: System and CGI - File Created but not the Content
in thread System and CGI - File Created but not the Content

Here is an example how you write a perl script that moves itself into the background (might not work on windows...):

!/usr/bin/perl use strict; use warnings; my $ret_val = fork(); if (! defined $ret_val){ die "Can't fork(): $!"; } elsif ($ret_val == 0){ # do your daemon tasks here sleep 5; print "Exiting\n"; } else { exit 0; }

As for the server you should check the Net::Server module.

Replies are listed 'Best First'.
Re^6: System and CGI - File Created but not the Content
by girarde (Hermit) on Sep 18, 2007 at 13:30 UTC
    Here is an example how you write a perl script that moves itself into the background (might not work on windows...):

    That's OK. The original script almost certainly would.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://639631]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2016-06-27 05:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (336 votes). Check out past polls.