[ome-users] Deploying OMERO.web with Apache/mod_python

Aleksandra Tarkowska aleksandrat at lifesci.dundee.ac.uk
Sun Oct 25 15:28:36 GMT 2009


Hi Curtis

Thanks for testing deployment

On 24 Oct 2009, at 00:00, Curtis Rueden wrote:

> Hi everyone,
>
> I installed OMERO-Beta4.1 successfully on an Ubuntu Linux 9.04  
> (Jaunty) server.
>
> However, I ran into problems trying to get OMERO.web working with  
> Apache+mod_python as described on the "Web on production" page at:
>   http://www.openmicroscopy.org.uk/site/support/omero4/server/install_web
>
> I was able to overcome them, so I thought I would pass on the steps  
> to do so, in case anyone else has similar difficulties.
>
> 1) In the "Configure mod_python" step, presumably you are supposed  
> to edit /etc/apache2/sites-available/default (or other Apache  
> configuration file), placing those lines inside the relevant  
> VirtualHost block, but it never indicates that anywhere. I suggest  
> placing the Location block just before the "</VirtualHost>" at the  
> bottom of the file.
>
> After editing the Apache configuration file, as you might expect  
> (but is not documented anywhere), you should execute:
>   sudo /etc/init.d/apache2 reload

Good idea

> 2) When I ran the "syncdb" step, it initially blew up. The fix  
> required two changes:
>
>   A) Install Django:
>     sudo aptitude install python-django
>
>   B) Chown the webdb and weblog folders back to omero:omero  
> temporarily:
>     sudo chown -R omero:omero ~omero/omero/webdb ~omero/omero/weblog
>   And then back to www-data:www-data afterward.

The command should be
sudo -u apache_user PYTHONPATH=/home/omero/omero_dist/lib/python/ bin/ 
omero web syncdb
Django package is delivered with OMERO.server and does not need to be  
installed separately because it require particular version 1.0.
Doc is already fixed.

> 3) I then ran into a problem accessing the URL in the web browser.  
> The modules "webadmin.controller" and "webclient.controller" were  
> not found. Looking in the OMERO distribution's lib/python folder, it  
> appears that some modules are nested in a subdirectory called  
> "omeroweb" -- so to fix the problem, I edited the Apache  
> configuration file again, changing:
>         PythonPath "['/home/omero/omero_dist/lib/python'] + sys.path"
> To:
>         PythonPath "['/home/omero/omero_dist/lib/python'] + ['/home/ 
> omero/omero_dist/lib/python/omeroweb'] + sys.path"
>
> Make sure these paths match where you actually have your omero_dist  
> tree. Then restart your Apache again ("sudo /etc/init.d/apache2  
> reload").

That is also fixed. Thanks

> With these steps I was able to get OMERO.web working with Apache 
> +mod_python; I hope it is helpful to others as well.


>
> Three additional comments for the developers:
>
> 1) When editing default.xml in the "Configuration Guide for  
> mod_python" section, regarding the line with id="Web" and act="on- 
> demand" is not commented out: the instructions are inconsistent. One  
> place says to "comment the following" while another says to "re- 
> configure the Web server in default.xml to be on-demand." Reading  
> the lightweight OMERO.web instructions, it suggests changing "on- 
> demand" to "always" so I am guessing this step means to change it  
> back from "always" to "on-demand"? (I left the line alone and things  
> are working for me.)

Yes, that step says that if you have ever changed to "always", turn it  
back.

> 2) On the OMERO server install page, I would suggest splitting out  
> the Django server OMERO.web installation instructions into their own  
> page as well, and just providing two links: one to the Django  
> instructions (marked "easier but only suitable for localhost  
> configuration") and the Apache/mod_python ones (marked "more  
> involved but suitable for a production environment"). Right now it  
> is not clear which, if any, of the OMERO.web instructions from the  
> main page are applicable to the Apache/mod_python way of doing things.

We have just merged two docs in one installation page because  
beginners, who want to run demo on their own machine, didn't know they  
needed to configure OMERO.web. From the other side, sysadmins had no  
problems with finding right docs.

> 3) FYI, the log in ~omero/weblog still reports: "2009-10-23  
> 17:40:24,601 omero.util.UpgradeCheck: WARNING  UPGRADE  
> AVAILABLE:Please upgrade to Beta-4.1-RC1 See http://trac.openmicroscopy.org.uk/omero 
>  for the latest version"

Upgrade check contained old version, now should be fine.

THanks Curtis for help.

>
> Regards,
> Curtis
>
> _______________________________________________
> ome-users mailing list
> ome-users at lists.openmicroscopy.org.uk
> http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-users

Thanks
Ola

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openmicroscopy.org.uk/pipermail/ome-users/attachments/20091025/05b7fca6/attachment.html>


More information about the ome-users mailing list