Thanks Chris. As it happens, Bernhard Holländer found the solution, which he mentioned in a
thread on the ome-users mailing list today.
Essentially the problem was that the Django cache folder in /var/tmp/django_cache was owned by the omero Unix user we had set up, rather than being owned by the Apache user (www-data). By renaming this folder and attempting to log in to the web client, OMERO.web successfully recreated the cache owned by www-data and all is well!