Install - Web
OMERO.web Install and Configuration
OMERO.web is the web application component of the OMERO platform which allows for the management, viewing (a fully multi-dimensional image viewer), attachment and association of files to images, datasets, and projects from one or more OMERO.server's. It also includes webadmin for managing users and groups. With one or two commands, OMERO.web can be started with the Django lightweight development Web server bound to port 8000 on 127.0.0.1 when you deploy your OMERO.server instance.
We do not recommend using this server in a production setting. It has not gone through security audits or performance tests. Apache with mod_python is the preferred setup for deploying a Django application on a production server. You can find more information on the Django site here.
Prerequisites
If you are using Python 2.4, you will need pysqlite. Use version 2.0.3 or higher. Python 2.5 ships with an SQLite wrapper in the standard library, so you do not need to install anything extra in that case.
Python Imaging Library and Matplot Lib
PIL and Matplot Lib are an optional requirement for drive space utilization graphs
PYTHONPATH
on non-Windows platform:
$ export PYTHONPATH=$PYTHONPATH:/home/omero/omero_dist/lib/python/
$ echo $PYTHONPATH
/opt/local/share/ice/python:/home/omero/omero_dist/lib/python/:
on Windows platform:
C:\>set PYTHONPATH=%PYTHONPATH%;C:\OMERO\lib\python
C:\>echo %PYTHONPATH%
C:\Ice-3.3.0\python;C:\omero-Beta4.0.0\lib\python
Configuration for Django Web server (non-production)
On non-Windows* platforms, OMERO.web is configured to be started with a single command
Use:
Start up OMERO.web manually:
$ cd /home/omero/omero-dist/ $ bin/omero admin ice Ice 3.3.0 Copyright 2003-2008 ZeroC, Inc. >>> server enable Web >>> server start Web >>> exitShut down OMERO.web manually:
$ cd /home/omero/omero-dist/ $ bin/omero admin ice Ice 3.3.0 Copyright 2003-2008 ZeroC, Inc. >>> server disable Web >>> server stop Web >>> exitOr have it started automatically:
If you wish to have the server always on, configure the following in
/home/omero/omero_dist/etc/grid/default.xml:<server-instance template="ShellTemplate" id="Web" act="always"/>If you require to configure the out of the box setup to listen for webadmin and webclient connections on different host configure the following:
Configure the following in
/home/omero/omero_dist/etc/grid/templates.xmlby adding after --noreload:<server-template id="WebTemplate"> <parameter name="act" default="on-demand"/> <server id="Web" exe="python" activation="${act}" pwd="${OMEROPY_HOME}omeroweb"> <option>manage.py</option> <option>runserver</option> <option>--noreload</option> <option>10.0.0.1:8000</option><!-- your ip & port here --> <env>${PYTHONPATH}</env> <adapter name="WebAdapter" register-process="true" endpoints="tcp" server-lifetime="false"/> </server> </server-template>In your
/home/omero/omero_dist/lib/python/omero/plugins/directory configure the following inserver.py:django = ["python","manage.py","runserver","0.0.0.0:8080","--noreload"]+list(args)On Windows* platforms, please follow the instruction on OMERO install - windows
Configuration Guide for mod_python (production)
If you've enabled the OMERO.web instance that is using the Django lightweight development web server, you will need to shut it down:
Shut down the OMERO.web manually:
$ cd /home/omero/omero_dist/ $ bin/omero admin ice Ice 3.3.0 Copyright 2003-2008 ZeroC, Inc. >>> server disable Web >>> server stop WebIn your
/home/omero/omero_dist/etc/grid/directory re-configure the Web server indefault.xmlto be on-demand:<server-instance template="ShellTemplate" id="Web" act="on-demand"/>In your
/home/omero/omero_dist/lib/python/omeroweb/directory configure the following insettings.py:DATABASE_NAME
DATABASE_NAME = '/home/omero/webdb/db.sqlite3'LOGDIR
# LOGS # to change the log place, please specify new path for LOGDIR. # LOGDIR = os.path.join(os.path.dirname(__file__), 'log') # LOGDIR = os.path.join(os.path.join(os.path.join(os.path.join(os.path.dirname(__file__), '../'), '../'), 'var'), 'log') LOGDIR = '/home/omero/weblog/'Notification options: EMAIL_NOTIFICATION, EMAIL_SENDER_ADDRESS and EMAIL_SMTP_SERVER
# Notification # Application allows to notify user about new shares EMAIL_NOTIFICATION = True EMAIL_SENDER_ADDRESS = 'omero-admin@example.com' EMAIL_SMTP_SERVER = 'smtp.example.com' # Optional settings # EMAIL_SMTP_PORT = 25 # EMAIL_SMTP_USER = 'login' # EMAIL_SMTP_PASSWORD = 'password' # EMAIL_SMTP_TLS = TrueNotification option for sharing:
# If web server is running behind a proxy server please set the host. # That option is required by share notification sendere. APPLICATION_HOST='http://www.domain.com:80'
Create log and database directories with
apache_user:apache_groupownership:mkdir /home/omero/weblog chown apache_user:apache_group /home/omero/weblog mkdir /home/omero/webdb chown apache_user:apache_group /home/omero/webdbInitialize the Django settings database, specifying an OMERO.web superuser username, password and e-mail address:
# cd /home/omero/omero_dist/lib/python/omeroweb/ # sudo -u apache_user PYTHONPATH=/home/omero/omero_dist/lib/python/ python manage.py syncdb Creating table django_admin_log Creating table auth_permission Creating table auth_group Creating table auth_user Creating table auth_message Creating table django_content_type Creating table django_session Creating table django_site Creating table webadmin_gateway You just installed Django's auth system, which means you don't have any superusers defined. Would you like to create one now? (yes/no): yes Username (Leave blank to use 'omero'): omero E-mail address: omero-admin@example.com Password: Password (again): Superuser created successfully. Installing custom SQL for webadmin.Gateway model Installing index for admin.LogEntry model Installing index for auth.Permission model Installing index for auth.Message modelConfigure
mod_python:<Location "/"> SetHandler python-program PythonHandler django.core.handlers.modpython SetEnv DJANGO_SETTINGS_MODULE omeroweb.settings PythonDebug On (for 4.0.0) PythonPath "['/home/omero/omero_dist/lib', '/home/omero/omero_dist/lib/python', '/home/omero/omero_dist/lib/omeroweb'] + sys.path" (as of 4.0.1) PythonPath "['/home/omero/omero_dist/lib/python', '/home/omero/omero_dist/lib/python/omeroweb'] + sys.path" </Location>Go to the link http://your_host/webclient/ or http://your_host/webadmin/
If you wish to modify the predefined list of the OMERO.servers please go to admin panel: http://your_host/admin/webadmin/gateway/. To login, use the user superuser username and password created you created when initializing the Django settings database above.
Once you have deployed and started the server you can use your browser to access the OMERO.webadmin or OMERO.webclient:
http://your_host/webadmin
http://your_host/webclient
Troubleshooting
My OMERO install doesn't work! What do I do now!?! Examine the Troubleshooting page and if all else fails post a message to our ome-users mailing list discussed on the Community page.

