[Last Call] Learn how to a build a cloud-first strategyRegister Now


If you run a perl program using SSI, does it fork a new process each time, like CGI?

Posted on 2006-05-18
Medium Priority
Last Modified: 2013-12-25

I am trying to compare web development using Java - jsp,servlet and Perl - SSI,CGI. I know that CGI forks a new process for a perl program each time (unless you use mod_perl), but I dont know if this is the same for SSI calling a perl program?

I just want to know do the same inefficiencies apply to SSI? Also, SSI cant do as much as CGI - right? What exactly cant SSI do?

Thanks in advance

Question by:bazbazbaz
  • 2
  • 2

Accepted Solution

Perl_Diver earned 300 total points
ID: 16711559
Each time an SSI tag runs a perl script a new process is started on the server. All the SSI tag is doing is invoking the perl script to run just like starting a CGI process, so I have to assume they are the same as far as the server goes. Hopefully you are running your perl scripts from a non-web accesible folder when you use SSI, otherwise your scripts could be triggered from calling the URI of the script.

Author Comment

ID: 16711887
I'm not really using them, I'm just trying to compare them in theory.

If I want to talk about Perl for web development, I can talk about CGI, and SSI - which are very much alike really, yes? I you can use SSI to run a perl script like CGI?

Just a general comparison is all i need. Thanks

Expert Comment

ID: 16712578
It's  possible to use SSI to invoke a perl scriptc  similar to a CGI request. You would use the virtual tag and append any necessary data to the URI string.

<!--#include virtual="../cgi-bin/yourscript.pl?name=value&name=value&name=value" -->

which would be subject to the restrictions of the GET method. SSI is a poor mans scripting language, but is still useable for simple things. If you are doing anything complicated PHP or other scripting language is probably gpoing to be much better, certainly more powerful.

Author Comment

ID: 16712785
Thats great, thanks

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It is a general practice to get rid of old user profiles on a computer  in a LAN environment. As I have been working with a company in a LAN environment where users move from one place to some other place at times. This will make many user profil…
Measuring Server's processing rate with a simple powershell command. The differences in processing rate also was recorded in different use-cases, when a server in free and busy states.
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Suggested Courses
Course of the Month18 days, 8 hours left to enroll

825 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question