1 (edited by gaxy 2013-10-23 16:07:52)

Topic: internal server error

==== Required information ====
- iRedMail version:  1.7.0  Pro Mysql
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Linux/BSD distribution name and version: Debian Wheezy
- Related log if you're reporting an issue: internal server error
====

Hi there

I have a new installation of iredmail pro.
All looks good and we have migrated from a postfixadmin maia mailguard based system to iredadmin, cool stuff !!!

the only problem that i have, if i login to the admin panel iredamin-pro as postmaster@sadasdasd (its the account generated at the beginning of the installation) all looks nice, when i then click to Domains and Accounts i see all my domains, no problem, but

when i then click on the preferences butten (edit account profile) of a domain i see internal server error.

if i do the exact same over the internal ip address and not over the public name, it works.

if i set debuging to true i see the following:


<type 'exceptions.TypeError'> at /profile/domain/general/DOMAIN.XY
__init__() should return None, not 'tuple'
Python     /usr/share/apache2/iredadmin/controllers/mysql/domain.py in GET, line 126
Web     GET https://mail.DOMAIN.ZZ/iredadmin/profil … /DOMAIN.XY


Can some one tell me what i have to change?

Kind Regards

GaXy

2

Re: internal server error

gaxy wrote:

<type 'exceptions.TypeError'> at /profile/domain/general/DOMAIN.XY

Sorry about this trouble.
Could you please paste full log instead of just few lines? There're some more lines, i need the ones you didn't pasted.

3

Re: internal server error

ZhangHuangbin wrote:
gaxy wrote:

<type 'exceptions.TypeError'> at /profile/domain/general/DOMAIN.XY

Sorry about this trouble.
Could you please paste full log instead of just few lines? There're some more lines, i need the ones you didn't pasted.



shure:



<type 'exceptions.TypeError'> at /profile/domain/general/DOMAIN.XY
__init__() should return None, not 'tuple'
Python     /usr/share/apache2/iredadmin/controllers/mysql/domain.py in GET, line 126
Web     GET https://mail.DOMAIN.ZZ/iredadmin/profil … /DOMAIN.XY
Traceback (innermost first)

    /usr/share/apache2/iredadmin/controllers/mysql/domain.py in GET
        throttleLib = throttle.Throttle() ...
    ? Local vars
    /usr/share/apache2/iredadmin/controllers/decorators.py in proxyfunc
        return func(self, *args, **kw) ...
    ? Local vars
    /usr/lib/python2.7/dist-packages/web/application.py in handle_class
        return tocall(*args) ...
    ? Local vars
    /usr/lib/python2.7/dist-packages/web/application.py in _delegate
        return handle_class(cls) ...
    ? Local vars
    /usr/lib/python2.7/dist-packages/web/application.py in handle
        return self._delegate(fn, self.fvars, args) ...
    ? Local vars
    /usr/lib/python2.7/dist-packages/web/application.py in process
        return self.handle() ...
    ? Local vars

Request information
INPUT

No data.
COOKIES
Variable    Value
PHPSESSID   
'2as9chf2nchvghelts49i11v94'
composesplitterv   
'248'
iRedAdmin-Pro   
'ef5631414af4553ddbebae8f6490e25b2fa0b819'
identviewsplitter   
'266'
language   
'de'
mailviewsplitter   
'310'
mailviewsplitterv   
'226'
managesievesplitter1   
'156'
managesievesplitter2   
'186'
prefviewsplitter   
'266'
roundcube_sessauth   
'S6a3689381655eb20494593aa40550250f9332eea'
roundcube_sessid   
'8b4b6u740e6hjr95st6pmda794'
META
Variable    Value
app_stack   
[<web.application.application instance at 0x7f15c12e6170>]
fullpath   
u'/profile/domain/general/DOMAIN.XY'
headers   
[]
home   
u'https://mail.DOMAIN.ZZ/iredadmin'
homedomain   
u'https://mail.DOMAIN.ZZ'
homepath   
u'/iredadmin'
host   
u'mail.DOMAIN.ZZ'
ip   
u'46.140.133.2'
lang   
'en_US'
method   
u'GET'
output   
u''
path   
u'/profile/domain/general/DOMAIN.XY'
protocol   
u'https'
query   
u''
realhome   
u'https://mail.DOMAIN.ZZ/iredadmin'
status   
'200 OK'
ENVIRONMENT
Variable    Value
DOCUMENT_ROOT   
'/var/www'
GATEWAY_INTERFACE   
'CGI/1.1'
HTTPS   
'1'
HTTP_ACCEPT   
'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'
HTTP_ACCEPT_ENCODING   
'gzip, deflate'
HTTP_ACCEPT_LANGUAGE   
'de-de,de;q=0.8,en-us;q=0.5,en;q=0.3'
HTTP_CACHE_CONTROL   
'max-age=0'
HTTP_CONNECTION   
'keep-alive'
HTTP_COOKIE   
'iRedAdmin-Pro=ef5631414af4553ddbebae8f6490e25b2fa0b819; mailviewsplitterv=226; prefviewsplitter=266; identviewsplitter=266; language=de; composesplitterv=248; mailviewsplitter=310; managesievesplitter1=156; managesievesplitter2=186; PHPSESSID=2as9chf2nchvghelts49i11v94; roundcube_sessid=8b4b6u740e6hjr95st6pmda794; roundcube_sessauth=S6a3689381655eb20494593aa40550250f9332eea'
HTTP_DNT   
'1'
HTTP_HOST   
'mail.DOMAIN.ZZ'
HTTP_REFERER   
'https://mail.DOMAIN.ZZ/iredadmin/domains'
HTTP_USER_AGENT   
'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Firefox/24.0'
PATH_INFO   
'/profile/domain/general/DOMAIN.XY'
PATH_TRANSLATED   
'/var/www/profile/domain/general/DOMAIN.XY'
QUERY_STRING   
''
REMOTE_ADDR   
'46.140.133.2'
REMOTE_PORT   
'62995'
REQUEST_METHOD   
'GET'
REQUEST_URI   
'/iredadmin/profile/domain/general/DOMAIN.XY'
SCRIPT_FILENAME   
'/usr/share/apache2/iredadmin/iredadmin.py'
SCRIPT_NAME   
'/iredadmin'
SERVER_ADDR   
'192.168.164.31'
SERVER_ADMIN   
'iasdadsadasdasdasdad'
SERVER_NAME   
'mail.DOMAIN.ZZ'
SERVER_PORT   
'443'
SERVER_PROTOCOL   
'HTTP/1.1'
SERVER_SIGNATURE   
'<address>Apache Server at mail.DOMAIN.ZZ Port 443</address>\n'
SERVER_SOFTWARE   
'Apache'
SSL_TLS_SNI   
'mail.DOMAIN.ZZ'
mod_wsgi.application_group   
'*.DOMAIN.ZZ|/iredadmin'
mod_wsgi.callable_object   
'application'
mod_wsgi.handler_script   
''
mod_wsgi.input_chunked   
'0'
mod_wsgi.listener_host   
''
mod_wsgi.listener_port   
'443'
mod_wsgi.process_group   
'iredadmin'
mod_wsgi.request_handler   
'wsgi-script'
mod_wsgi.script_reloading   
'1'
mod_wsgi.version   
(3, 3)
wsgi.errors   
<mod_wsgi.Log object at 0x7f15a8a5f030>
wsgi.file_wrapper   
<built-in method file_wrapper of mod_wsgi.Adapter object at 0x7f15a7de6cd8>
wsgi.input   
<mod_wsgi.Input object at 0x7f15a8a5f0b0>
wsgi.multiprocess   
False
wsgi.multithread   
True
wsgi.run_once   
False
wsgi.url_scheme   
'https'
wsgi.version   
(1, 1)

You're seeing this error because you have web.config.debug set to True. Set that to False if you don't want to see this.

4

Re: internal server error

Pasted log is not full log. Could you please paste me error log in Apache log file?

5

Re: internal server error

it sounds realy strange but now it works on the same machine...i have don nothing.
is there some where a cache of the application that have to be cleaned?

6

Re: internal server error

No cache at all.

7

Re: internal server error

ZhangHuangbin wrote:

No cache at all.

have it again, try to find something in the apache error log.

8

Re: internal server error

in the apache error.log i have this when i reload the page who show's me the error:

[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444] Traceback (most recent call last):
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 239, in process
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]     return self.handle()
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 230, in handle
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]     return self._delegate(fn, self.fvars, args)
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 420, in _delegate
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]     return handle_class(cls)
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 396, in handle_class
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]     return tocall(*args)
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]   File "/usr/share/apache2/iredadmin/controllers/decorators.py", line 11, in proxyfunc
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]     return func(self, *args, **kw)
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]   File "/usr/share/apache2/iredadmin/controllers/mysql/domain.py", line 127, in GET
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]     throttleLib = throttle.Throttle()
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444] TypeError: __init__() should return None, not 'tuple'
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]


and on the ssl_access.log i have this
111.222.333.444 - - [24/Oct/2013:20:35:59 +0200] "GET /iredadmin/profile/domain/general/DOMAIN.XY HTTP/1.1" 500 604 "https://mail.DOMAIN.zz/iredadmin/domains" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Firefox/24.0"


i dont see the reason... also i do not see why it is once working and once not ???

Kind Regards
GaXy

9

Re: internal server error

Sorry about this trouble.

gaxy wrote:

[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444]     throttleLib = throttle.Throttle()
[Thu Oct 24 20:36:34 2013] [error] [client 111.222.333.444] TypeError: __init__() should return None, not 'tuple'

Please disable Policyd integration in iRedAdmin config file /usr/share/apache2/iredadmin/settings.ini (set 'enabled = False'), then restart Apache service and try again.

[policyd]
enabled = False

Debian ships Cluebringer (a.k.a. Policyd-2) instead of Policyd-1.8, but iRedAdmin-Pro doesn't support Cluebringer yet, so you have to disable it temporary.

Upcoming release of iRedAdmin-Pro supports Cluebringer, and it will be available in about 2-3 weeks. Please be patient.

10

Re: internal server error

done, set it to false but still the same internal server error and this on apache error log:


[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444] Traceback (most recent call last):
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 239, in process
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]     return self.handle()
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 230, in handle
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]     return self._delegate(fn, self.fvars, args)
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 420, in _delegate
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]     return handle_class(cls)
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]   File "/usr/lib/python2.7/dist-packages/web/application.py", line 396, in handle_class
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]     return tocall(*args)
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]   File "/usr/share/apache2/iredadmin/controllers/decorators.py", line 11, in proxyfunc
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]     return func(self, *args, **kw)
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]   File "/usr/share/apache2/iredadmin/controllers/mysql/domain.py", line 127, in GET
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]     throttleLib = throttle.Throttle()
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444] TypeError: __init__() should return None, not 'tuple'
[Fri Oct 25 11:18:37 2013] [error] [client 111.222.333.444]

11

Re: internal server error

after complete log out of iredadmin-pro and re login, it looks good now.