Celery runs as baruwa on 2.0.0. I added the baruwa user to the www-data
group and have the following permissions
drwxr-xr-x 10 Debian-exim clamav 4096 Feb 2 16:27 incoming
drwxrwx--- 9 Debian-exim www-data 4096 Feb 2 00:24 quarantine
When I attempt to preview or release a message baruwa kicks out a WebApp
Error, as well as the log entries I have already posted:
I see now, it is baruwa.wsgi that creates the /messages url
One error I see is that the report indicates the Document Root is
/etc/apache2/htdocs, which is non-existent. Not sure where it is pulling
that info from, or what to change it to.
I also see in baruwa.wsgi it uses /var/tmp for processing the preview or
release. Maybe the permissions are wrong there??
drwxrwxrwt 2 root root 4096 Feb 1 14:54 tmp
WebApp Error:
URL: http://domain.x.org/messages/preview/204203
Module weberror.errormiddleware:162 in __call__
<< __traceback_supplement__ = Supplement, self, environ
sr_checker = ResponseStartChecker(start_response)
app_iter = self.application(environ, sr_checker)
return self.make_catching_iter(app_iter, environ,
sr_checker)
except:
>> app_iter = self.application(environ, sr_checker)
Module repoze.who.middleware:107 in __call__
<< wrapper = StartResponseWrapper(start_response)
app_iter = app(environ, wrapper.wrap_start_response)
# The challenge decider almost(?) always needs
information from the
>> app_iter = app(environ, wrapper.wrap_start_response)
Module beaker.middleware:155 in __call__
<< headers.append(('Set-cookie', cookie))
return start_response(status, headers, exc_info)
return self.wrap_app(environ, session_start_response)
def _get_session(self):
>> return self.wrap_app(environ, session_start_response)
Module routes.middleware:131 in __call__
<< r'\1', oldpath)
response = self.app(environ, start_response)
# Wrapped in try as in rare cases the attribute will be
gone already
>> response = self.app(environ, start_response)
Module pylons.wsgiapp:103 in __call__
<< controller = self.resolve(environ, start_response)
response = self.dispatch(controller, environ,
start_response)
response_obj = callable(response)
>> response = self.dispatch(controller, environ, start_response)
Module pylons.wsgiapp:313 in dispatch
<< if log_debug:
log.debug("Calling controller class with WSGI
interface")
return controller(environ, start_response)
def load_test_env(self, environ):
>> return controller(environ, start_response)
Module baruwa.lib.base:93 in __call__
<< c.tzinfo = tzinfo
try:
return WSGIController.__call__(self, environ,
start_response)
finally:
Session.remove()
>> return WSGIController.__call__(self, environ, start_response)
Module pylons.controllers.core:214 in __call__
<< return response(environ, self.start_response)
response = self._dispatch_call()
if not start_response_called:
self.start_response = start_response
>> response = self._dispatch_call()
Module pylons.controllers.core:164 in _dispatch_call
<< req.environ['pylons.action_method'] = func
response = self._inspect_call(func)
else:
if log_debug:
>> response = self._inspect_call(func)
Module pylons.controllers.core:107 in _inspect_call
<< func.__name__, args)
try:
result = self._perform_call(func, args)
except HTTPException, httpe:
if log_debug:
>> result = self._perform_call(func, args)
Module pylons.controllers.core:57 in _perform_call
<< """Hide the traceback for everything above this method"""
__traceback_hide__ = 'before_and_this'
return func(**args)
def _inspect_call(self, func):
>> return func(**args)
Module baruwa.controllers.messages:2 in preview
Module repoze.what.plugins.pylonshq.protectors:118 in wrap_action
<< return self.denial_handler(reason)
abort(code, comment=reason)
return action_(*args, **kwargs)
>> return action_(*args, **kwargs)
Module baruwa.controllers.messages:544 in preview
<< task = preview_msg.apply_async(args=args,
queue=message.hostname.strip())
task.wait(30)
if task.result:
if img:
>> task.wait(30)
Module celery.result:120 in get
<< return self.backend.wait_for(self.id, timeout=timeout,
propagate=propagate,
interval=interval)
wait = get # deprecated alias to :meth:`get`.
>> interval=interval)
Module celery.backends.amqp:150 in wait_for
<< elif state in states.PROPAGATE_STATES:
if propagate:
raise self.exception_to_python(meta['result'])
return meta['result']
else:
>> raise self.exception_to_python(meta['result'])
OSError: [Errno 2] No such file or directory
CGI Variables
AUTH_TYPE 'cookie'
DOCUMENT_ROOT '/etc/apache2/htdocs'
GATEWAY_INTERFACE 'CGI/1.1'
HTTP_ACCEPT
'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'
HTTP_ACCEPT_CHARSET 'ISO-8859-1,utf-8;q=0.7,*;q=0.3'
HTTP_ACCEPT_ENCODING 'gzip,deflate,sdch'
HTTP_ACCEPT_LANGUAGE 'en-US,en;q=0.8'
HTTP_CONNECTION 'keep-alive'
HTTP_COOKIE
'baruwa=f65dbb199280cdfed995a044dfd7da0549c8ca59572dad5add844e788cfc23a6355da6d7; baruwaauth="f6e30658668d1c60c56d9fc4ca7a68aa510d8ea8root!<repoze.who.plugins.sa.SQLAlchemyAuthenticatorPlugin object at 0x7f36331f6650>,!userid_type:unicode"; baruwaauth="f6e30658668d1c60c56d9fc4ca7a68aa510d8ea8root!<repoze.who.plugins.sa.SQLAlchemyAuthenticatorPlugin object at 0x7f36331f6650>,!userid_type:unicode"'
HTTP_HOST 'domain.x.org'
HTTP_REFERER 'http://domain.x.org/messages/detail/204203'
HTTP_USER_AGENT 'Mozilla/5.0 (X11; Linux i686) AppleWebKit/535.11
(KHTML, like Gecko) Chrome/17.0.963.56 Safari/535.11'
PATH_INFO '/messages/preview/204203'
PATH_TRANSLATED
'/home/baruwa/px/lib/python2.7/site-packages/baruwa/baruwa.wsgi/messages/preview/204203'
REMOTE_ADDR 'public IP'
REMOTE_PORT '58408'
REMOTE_USER u'root'
REMOTE_USER_DATA 'userid_type:unicode'
REMOTE_USER_TOKENS
['<repoze.who.plugins.sa.SQLAlchemyAuthenticatorPlugin object at
0x7f36331f6650>', '']
REQUEST_METHOD 'GET'
REQUEST_URI '/messages/preview/204203'
SCRIPT_FILENAME
'/home/baruwa/px/lib/python2.7/site-packages/baruwa/baruwa.wsgi'
SERVER_ADDR '10.10.1.41'
SERVER_ADMIN '[no address given]'
SERVER_NAME 'domain.x.org'
SERVER_PORT '80'
SERVER_PROTOCOL 'HTTP/1.1'
SERVER_SIGNATURE '<address>Apache/2.2.22 (Ubuntu) Server at
domain.x.org Port 80</address>\n'
SERVER_SOFTWARE 'Apache/2.2.22 (Ubuntu)'
WSGI Variables
application <baruwa.lib.auth.middleware.BaruwaPAM object at 0x7f3630c60ad0>
beaker.get_session <bound method SessionMiddleware._get_session of
<beaker.middleware.SessionMiddleware object at 0x7f36331e9610>>
beaker.session {'taskids': [], '_accessed_time': 1359843160.065031,
u'csrf': '7e3394f95766e87455bc2f9e49a005b07bb2e116', '_creation_time':
1359812693.497773}
mod_wsgi.application_group 'domain.x.org|'
mod_wsgi.callable_object 'application'
mod_wsgi.handler_script ''
mod_wsgi.input_chunked '0'
mod_wsgi.listener_host ''
mod_wsgi.listener_port '80'
mod_wsgi.process_group ''
mod_wsgi.request_handler 'wsgi-script'
mod_wsgi.script_reloading '1'
mod_wsgi.version (3, 3)
paste.cookies (<SimpleCookie:
baruwa='f65dbb199280cdfed995a044dfd7da0549c8ca59572dad5add844e788cfc23a6355da6d7'
baruwaauth='f6e30658668d1c60c56d9fc4ca7a68aa510d8ea8root!<repoze.who.plugins.sa.SQLAlchemyAuthenticatorPlugin
object at 0x7f36331f6650>,!userid_type:unicode'>,
'baruwa=f65dbb199280cdfed995a044dfd7da0549c8ca59572dad5add844e788cfc23a6355da6d7;
baruwaauth="f6e30658668d1c60c56d9fc4ca7a68aa510d8ea8root!<repoze.who.plugins.sa.SQLAlchemyAuthenticatorPlugin
object at 0x7f36331f6650>,!userid_type:unicode";
baruwaauth="f6e30658668d1c60c56d9fc4ca7a68aa510d8ea8root!<repoze.who.plugins.sa.SQLAlchemyAuthenticatorPlugin
object at 0x7f36331f6650>,!userid_type:unicode"')
paste.registry <paste.registry.Registry object at 0x7f3634dc8290>
paste.throw_errors True
pylons.action_method <bound method MessagesController.preview of
<baruwa.controllers.messages.MessagesController object at 0x7f3634dc8a90>>
pylons.controller <baruwa.controllers.messages.MessagesController object
at 0x7f3634dc8a90>
pylons.environ_config {'session': 'beaker.session', 'cache':
'beaker.cache'}
pylons.log_debug False
pylons.pylons <pylons.util.PylonsContext object at 0x7f3634dc8f90>
pylons.routes_dict {'action': u'preview', 'controller': u'messages',
'id': u'204203', 'format': None}
repoze.what.adapters {'groups': {}, 'permissions': {}}
repoze.what.credentials {'repoze.what.userid': u'root', 'groups':
(), 'permissions': ()}
repoze.who.identity <repoze.who identity (hidden, dict-like) at
139870753267952>
repoze.who.logger None
repoze.who.plugins {'authorization_md':
<repoze.what.middleware.AuthorizationMetadata object at 0x7f3633346fd0>,
'form': <FriendlyFormPlugin 139870762656912>, 'baruwa_pop3_auth':
<baruwa.lib.auth.pop3auth.BaruwaPOPAuthPlugin object at 0x7f3633294a10>,
'baruwa_smtp_auth': <baruwa.lib.auth.smtpauth.BaruwaSMTPAuthPlugin
object at 0x7f3633294910>, 'baruwa_radius_auth':
<baruwa.lib.auth.radiusauth.BaruwaRadiusAuthPlugin object at
0x7f36331ff710>, 'sa_auth':
<repoze.who.plugins.sa.SQLAlchemyAuthenticatorPlugin object at
0x7f36331f6650>, 'auth_tkt': <AuthTktCookiePlugin 139870763982288>,
'baruwa_imap_auth': <baruwa.lib.auth.imapauth.BaruwaIMAPAuthPlugin
object at 0x7f36332b13d0>, 'sa_md':
<repoze.who.plugins.sa.SQLAlchemyUserMDPlugin object at 0x7f363332a290>,
'baruwa_ldap_auth': <BaruwaLDAPAuthPlugin 139870762658448>}
routes.route <routes.route.Route object at 0x7f363305cb90>
routes.url <routes.util.URLGenerator object at 0x7f3634dc8b10>
webob._parsed_query_vars (GET([]), '')
wsgi process 'Multiprocess'
wsgi.file_wrapper <built-in method file_wrapper of mod_wsgi.Adapter
object at 0x7f3634a55a08>
wsgi.version (1, 1)
wsgiorg.routing_args (<routes.util.URLGenerator object at
0x7f3634dc8b10>, {'action': u'preview', 'controller': u'messages', 'id':
u'204203', 'format': None})
_______________________________________________
Keep Baruwa FREE - http://pledgie.com/campaigns/12056