FAQ

1. Can CGIwithR be used with a web server running under Microsoft Windows? The short answer is no. The longer answer is probably yes, provided that the web server supports CGI, and that standard unix tools (including bash) are installed, e.g., from http://www.cygwin.com. Probably some tweaking of the R.cgi shell script will also be needed.
News March 2004: Adam Lyon kindly emailed me to say he has succeeded in getting CGIwithR to work under Windows. The details are in file windows.txt.
News Oct 2004: File windows.txt is updated to include some further helpful advice from Kurt Sys.
News Sep 2005: File windows.txt is updated to include yet more helpful advice from Carlos Rendon.

2. When trying to use CGIwithR, for example with the trivial.R example, I get no response from the webserver and this error message in the httpd log file:

    Premature end of script headers: /usr/var/cgi-bin/R.cgi
Why? Almost certainly this is because one or more of R.cgi, .Rprofile and trivial.R has been put in the wrong place on your system.

3. I have recently updated R and now my CGIwithR scripts don't work any more. I have checked that my installed CGIwithR package is the latest version. Any clues? Did you perhaps forget to install the new R.cgi file? This comes inside the inst subdirectory of the CGIwithR package, and it needs to be installed in your "cgi-bin" (or whatever it's called on your system) directory.

4. I am getting messages in the Web server's error log of the form cat argument list too long See 5. - How do I deal with large POST submissions.

5. How do I deal with large POST submissions? Don't use R.cgi, but rather Rbigpost.cgi. That is the form should submit to http://..../cgi-bin/Rbigpost.cgi/myScript.R rather than http://..../cgi-bin/R.cgi/myScript.R. This handles passing the data to the code in myScript.R in a different way that overcomes restrictions by the UNIX shell on the size of data being processed.


Duncan Temple Lang <duncan@wald.ucdavis.edu>
Last modified: Tue Nov 29 08:32:43 PST 2005