Re: Problems with upgrading 5.1.2 to 5.2
Posted: Mon Nov 09, 2015 1:15 pm
atarkowska wrote:Hi Phillipe, I think you responded to Simon's question from Thursday
Ola
Hi Ola,
you're right
The OME community
https://www.openmicroscopy.org/community/
https://www.openmicroscopy.org/community/viewtopic.php?f=5&t=7924
atarkowska wrote:Hi Phillipe, I think you responded to Simon's question from Thursday
Ola
tail /var/log/httpd/ssl_error_log
[Tue Nov 10 12:18:45 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:19:15 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:19:45 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:20:15 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:20:45 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:21:08 2015] [error] [client 192.168.188.18] File does not exist: /var/www/html/omero
[Tue Nov 10 12:21:15 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:21:45 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:22:15 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
[Tue Nov 10 12:22:45 2015] [error] [client 192.168.111.149] Directory index forbidden by Options directive: /var/www/html/
###
# apache config for omero
# this file should be loaded *after* ssl.conf
#
# -D options to control configurations
# OmeroForceSSL - redirect all http requests to https
###
### Example SSL stanza for OMERO.web created 2015-11-10 12:19:45.861349
###
# Eliminate overlap warnings with the default ssl vhost
# Requires SNI (http://wiki.apache.org/httpd/NameBasedSSLVHostsWithSNI)
# support most later versions of mod_ssl and OSes will support it if you see
# "You should not use name-based virtual hosts in conjunction with SSL!!"
# or similar start apache with -D DISABLE_SNI and modify ssl.conf
#<IfDefine !DISABLE_SNI>
# NameVirtualHost *:443
#</IfDefine>
#
## force https/ssl
#<IfDefine OmeroForceSSL>
# RewriteEngine on
# RewriteCond %{HTTPS} !on
# RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [L]
#</IfDefine>
#
#<VirtualHost _default_:443>
#
# ErrorLog logs/ssl_error_log
# TransferLog logs/ssl_access_log
# LogLevel warn
#
# SSLEngine on
# SSLProtocol all -SSLv2
# SSLCipherSuite ALL:!ADH:!EXPORT:!SSLv2:RC4+RSA:+HIGH:+MEDIUM:+LOW
# SSLCertificateFile /etc/pki/tls/certs/server.crt
# SSLCertificateKeyFile /etc/pki/tls/private/server.key
#
# # SSL Protocol Adjustments:
# SetEnvIf User-Agent ".*MSIE.*" \
# nokeepalive ssl-unclean-shutdown \
# downgrade-1.0 force-response-1.0
#
# # Per-Server Logging:
# CustomLog logs/ssl_request_log \
# "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
#
#</VirtualHost>
###
### Stanza for OMERO.web created 2015-11-10 12:19:45.861349
###
<VirtualHost _default_:80>
DocumentRoot /opt/OMERO.server/lib/python/omeroweb
WSGIDaemonProcess omeroweb_omero processes=5 threads=1 display-name=%{GROUP} user=omero python-path=/opt/Ice-3.5.1/python:/opt/OMERO.server/lib/python:/opt/OMERO.server/lib/fallback:/opt/OMERO.server/lib/python/omeroweb
WSGIProcessGroup omeroweb_omero
WSGIScriptAlias /omero /opt/OMERO.server/lib/python/omeroweb/wsgi.py
<Directory "/opt/OMERO.server/lib/python/omeroweb">
Order allow,deny
Allow from all
</Directory>
Alias /omero/static /opt/OMERO.server/lib/python/omeroweb/static
<Directory "/opt/OMERO.server/lib/python/omeroweb/static">
Options -Indexes FollowSymLinks
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
# see https://code.google.com/p/modwsgi/wiki/ConfigurationIssues
WSGISocketPrefix run/wsgi
# WSGISocketPrefix /var/run/wsgi
ldd /etc/httpd/modules/mod_wsgi.so
ldd /etc/httpd/modules/mod_wsgi.so
libpython2.7.so.1.0 => /opt/rh/python27/root/usr/lib64/libpython2.7.so.1.0 (0x00007ff8a9063000)
atarkowska wrote:Hi Philippe,
As mentioned before, did you recompile mod_wsgi by hand? You cannot yum install it
What is an output of
- Code: Select all
ldd /etc/httpd/modules/mod_wsgi.so
It should link to
- Code: Select all
ldd /etc/httpd/modules/mod_wsgi.so
libpython2.7.so.1.0 => /opt/rh/python27/root/usr/lib64/libpython2.7.so.1.0 (0x00007ff8a9063000)
Ola
ldd /etc/httpd/modules/mod_wsgi.so
linux-vdso.so.1 => (0x00007fffd6748000)
libpython2.7.so.1.0 => /opt/rh/python27/root/usr/lib64/libpython2.7.so.1.0 (0x00007f144743d000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f1447206000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007f1447002000)
libutil.so.1 => /lib64/libutil.so.1 (0x00007f1446dff000)
libm.so.6 => /lib64/libm.so.6 (0x00007f1446b7a000)
libc.so.6 => /lib64/libc.so.6 (0x00007f14467e6000)
/lib64/ld-linux-x86-64.so.2 (0x0000003fe2800000)
python-path=/opt/Ice-3.5.1/python
python-path=/usr/lib64/python2.6/site-packages/Ice
user_base = getuserbase() # this will also set USER_BASE
File "/usr/local/lib/python2.7/site.py", line 231, in getuserbase
USER_BASE = get_config_var('userbase')
File "/usr/local/lib/python2.7/sysconfig.py", line 520, in get_config_var
return get_config_vars().get(name)
File "/usr/local/lib/python2.7/sysconfig.py", line 453, in get_config_vars
import re
File "/usr/local/lib/python2.7/re.py", line 108, in <module>
import _locale
SystemError: dynamic module not initialized properly
/usr/local/lib/python2.7/re.py
/usr/local/bin/python2.7
$ which python
/usr/bin/python
$ source /opt/rh/python27/enable
$ which python
/opt/rh/python27/root/usr/bin/python
ICE_HOME=/opt/Ice-3.5.1
export LD_LIBRARY_PATH="${ICE_HOME}/lib64:${ICE_HOME}/lib:$LD_LIBRARY_PATH"
atarkowska wrote:Hi Philippe,
I am glade you managed to compile mod_wsgi with SCL python.
As you can see from the stacktrace it is trying to use python located in.
- Code: Select all
/usr/local/lib/python2.7/re.py
Did you create an alias? Where does it come from exactly?
- Code: Select all
/usr/local/bin/python2.7
For me works:
default 2.6:
- Code: Select all
$ which python
/usr/bin/python
as opposite to SCL Python
- Code: Select all
$ source /opt/rh/python27/enable
$ which python
/opt/rh/python27/root/usr/bin/python
Once you sort it out, you will still need to set LD_LIBRARY_PATH in your apache init /etc/sysconfig/httpd
- Code: Select all
ICE_HOME=/opt/Ice-3.5.1
export LD_LIBRARY_PATH="${ICE_HOME}/lib64:${ICE_HOME}/lib:$LD_LIBRARY_PATH"
Ola
which python
/opt/rh/python27/root/usr/bin/python
source /opt/rh/python27/enable
[omero@omero ~]$ which python
/opt/rh/python27/root/usr/bin/python
ls -l /usr/local/bin/python
lrwxrwxrwx. 1 root root 24 4 nov. 11:43 /usr/local/bin/python -> /usr/local/bin/python2.7
tail -50 /var/log/httpd/error_log
[Tue Nov 10 16:31:31 2015] [notice] SELinux policy enabled; httpd running as context unconfined_u:system_r:httpd_t:s0
[Tue Nov 10 16:31:31 2015] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Tue Nov 10 16:31:31 2015] [notice] Digest: generating secret for digest authentication ...
[Tue Nov 10 16:31:31 2015] [notice] Digest: done
[Tue Nov 10 16:31:31 2015] [notice] FastCGI: process manager initialized (pid 946)
[Tue Nov 10 16:31:31 2015] [notice] mod_python: Creating 4 session mutexes based on 256 max processes and 0 max threads.
[Tue Nov 10 16:31:31 2015] [notice] mod_python: using mutex_directory /tmp
[Tue Nov 10 16:31:31 2015] [notice] Apache/2.2.15 (Unix) DAV/2 mod_fastcgi/2.4.6 PHP/5.3.3 mod_python/3.3.1 Python/2.6.6 mod_ssl/2.2.15 OpenSSL/1.0.1e-fips mod_wsgi/3.4 Python/2.7.5 configured -- resuming normal operations
ldd /etc/httpd/modules/mod_wsgi.so
ldd /etc/httpd/modules/mod_python.so
atarkowska wrote:Hi Philippe,
Mod_python is using a different Python version and is likely the cause of all the problems as you cannot use both mod_python and mod_wsgi together when they are using different Python versions.
You can check it via
- Code: Select all
ldd /etc/httpd/modules/mod_wsgi.so
vs
- Code: Select all
ldd /etc/httpd/modules/mod_python.so
Ola
mv /etc/httpd/conf.d/python.conf /etc/httpd/conf.d/python.bak
/etc/init.d/httpd restart
omero web start
Post-processed 'omeroweb.viewer.min.css' as 'omeroweb.viewer.min.css'
Post-processed 'omeroweb.viewer.min.js' as 'omeroweb.viewer.min.js'
0 static files copied to '/opt/OMERO.server/lib/python/omeroweb/static', 700 unmodified, 2 post-processed.
Clearing expired sessions. This may take some time...
[OK]
You are deploying OMERO.web using apache and mod_wsgi. Generate apache config using 'omero web config apache' and reload web server.
You are deploying OMERO.web using apache and mod_wsgi. Generate apache config using 'omero web config apache' and reload web server.
atarkowska wrote:Keep in mind that you can have nginx installed along side Apache. If you have spare IP address bind it to nginx only.
Ola