Alright, design question here. I've read up on security and whatnot for CGI scriting. The realization that CGI is hard has lead me to be wary of performing certain kinds of things with CGI scripting without asking the gurus first. Especially since I'm not messing with my own server, or even my own account on somebody elses server.

The situation: A CGI script makes little files with little bits of configuration information in them. The script can latter be invoked with this configuration info, through a proper request method. After a certain period of time the files expire and are deleted. The current system has every nth user get caught with the performance hit of doing a scan and delete of these config files.

The question: would it be legit (safe, reasonable, etc) to have every nth user fork a seperate process to do this sort of scanning, and have the parent go on without waiting for the child. I haven't worked alot with multiple processes, so it'd be helpful to hear what sort of considerations this kind of design must take.

Cheers,
Erik

Light a man a fire, he's warm for a day. Catch a man on fire, and he's warm for the rest of his life. - Terry Pratchet


In reply to CGI scripting and multiple processes by erikharrison

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.