http://www.perlmonks.org?node_id=1052992


in reply to Execute a script on a server

You want a daemon. Use one of the various daemonize modules.