TCM
UoC crest

Serving Larger Files from TCM's Webserver

Some files that one might wish to put on the web are a little too large, or too ephemeral, to be conveniently placed in one's home directory. In the past we provided access to the hard-disk of the web server itself for such files. Though serving them from there was very efficient, there was no protection against loss, maintaining mechanisms for getting the files there was tedious, and once there, people forgot about them. Moreover, we have now moved to using a VM as our web server, so there simply is no spare space on a physical disk in a physical machine.

The current alternative is that we provide a web server which serves files from one's /rscratch directory. This is optimised for serving data, and not doing much fancy stuff. So no SSI, no SSL, no following of symbolic links (hard links are followed).

The advantages compared to the old system are that it is very easy to get data to it, and it does have the protection of being on a RAID6 array.

The recipe is simply that URLs of the form

  http://files.tcm.phy.cam.ac.uk/~spqr1/
(replace spqr1 by your userid) will map to the directory /rscratch/spqr1/public_html/. This directory is not created automatically, but it is easy to create. As usual if one has modified the default permissions in one's /rscratch directory so that no-one can read it, neither will the web server be able to do so. Recommended minimum permissions are given by

  chmod 711 /rscratch/spqr1

The assumption is that people will simply create direct hyperlinks to large, presumably non-HTML, files, from pages hosted in their usual public_html directory in their home directory. This area is not really intended to serve complete web sites.

Added Features

One can ask the web server to generate an index automatically for a directory, by having in that directory a file called .htaccess with the contents:

Options Indexes

One can also control access as described here.