I'm having the 
"RuntimeError: instance.__dict__ not accessible in restricted mode"
problem mentioned in the FAQ and the TracSubversion wiki page.
However, this is on mod_wsgi instead of mod_python. The software
versions are:
 * Debian 4.0 Etch
 * Apache 2.2.3
 * Python 2.4.4
 * Subversion 1.4.2

I'm running
 * Trac instance "tracmain" with multiple Trac sites
 * Trac instance "tracsingle" with a single Trac site
   (which is one of the sites in instance "tracmain")

At first both Trac instances work fine, but after some time one of them
starts to fail with the runtime error.

Things I've tried:
 * removing authentication directives temporarily from the Apache
   settings
 * mpm-prefork and mpm-worker
 * same and different application group (also %{GLOBAL} for both)
 * same and different process group
 * same and different egg cache directory

After every change to the settings I always first stop then start
Apache. Nothing I've tried has made the problem go away yet.

I'm running out of ideas after reading through and trying all the
tricks mentioned in related Trac tickets, mod_wsgi documentation and
mailing list messages.

Here is my configuration:


-------------------------------- /etc/apache2/sites-available/tracmain

<VirtualHost *>
  ServerName trac.mydomain.com
  WSGIDaemonProcess trac user=www-data group=www-data threads=25
  WSGIScriptAlias / /var/lib/trac/apache/tracmain/trac.wsgi

  <Directory /var/lib/trac/apache/tracmain/trac.wsgi>
    WSGIProcessGroup trac
    WSGIApplicationGroup %{GLOBAL}
    Order deny,allow
    Allow from all
  </Directory>

  <Location /*/login>
    AuthType Basic
    AuthName "Main Trac site"
    AuthUserFile /var/lib/trac/users.htpasswd
    Require valid-user
  </Location>

  LogLevel warn
  CustomLog /var/log/apache2/tracmain.access.log combined
  ServerSignature On
</VirtualHost>


-------------------------------- /etc/apache2/sites-available/tracsingle

<VirtualHost *>
  ServerName tracsingle.mydomain.com
  WSGIDaemonProcess tracsingle user=www-data group=www-data threads=25
  WSGIScriptAlias / /var/lib/trac/apache/tracsingle/trac.wsgi

  <Directory /var/lib/trac/apache/tracsingle/trac.wsgi>
    WSGIProcessGroup trac
    WSGIApplicationGroup %{GLOBAL}
    Order deny,allow
    Allow from all
  </Directory>

  <Location /login>
    AuthType Basic
    AuthName "Trac Site"
    AuthUserFile /var/lib/trac/users.htpasswd
    Require valid-user
  </Location>

  LogLevel warn
  CustomLog /var/log/apache2/tracsingle.access.log combined
  ServerSignature On
</VirtualHost>


-------------------------------- /var/lib/trac/apache/tracmain/trac.wsgi

import sys
sys.stdout = sys.stderr
import os
os.environ['PYTHON_EGG_CACHE'] = '/var/lib/trac/.python-eggs/tracmain'
import trac.web.main

def application(environ, start_response):
    environ['trac.env_parent_dir'] = '/var/lib/trac'
    return trac.web.main.dispatch_request(environ, start_response)


-------------------------------- /var/lib/trac/apache/tracsingle/trac.wsgi


import sys
sys.stdout = sys.stderr
import os
os.environ['PYTHON_EGG_CACHE'] = '/var/lib/trac/.python-eggs/tracsingle'
import trac.web.main

def application(environ, start_response):
    environ['trac.env_path'] = '/var/lib/trac/tracsingle'
    return trac.web.main.dispatch_request(environ, start_response)


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to