1

Topic: iRedAdmin: Internal Server Error

Hi,

I recently bought iRedAdmin-Pro 1.2.0, bus after installing it I always get Internal Server Error. Apache error log shows:

[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43] mod_wsgi (pid=13887): Target WSGI script '/var/www/iredadmin/iredadmin.py' cannot be loaded as Python module.
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43] mod_wsgi (pid=13887): Exception occurred processing WSGI script '/var/www/iredadmin/iredadmin.py'.
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43] Traceback (most recent call last):
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43]   File "/var/www/iredadmin/iredadmin.py", line 28, in ?
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43]     from libs import iredbase, iredutils
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43]   File "/var/www/iredadmin/libs/iredbase.py", line 120, in ?
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43]     import iredutils
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43]   File "/var/www/iredadmin/libs/iredutils.py", line 271, in ?
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43]     def getSizelimitFromAccountLists(accountList, sizelimit=session['accountSizelimit'], page=1,):
[Mon Aug 23 13:38:51 2010] [error] [client 193.219.14.43] KeyError: 'accountSizelimit'

--
dammit

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: iRedAdmin: Internal Server Error

Oops, it's my fault. So sorry about this issue, you can fix it with below steps:

* Open libs/iredutils.py, change line 271 to below line:

def getSizelimitFromAccountLists(accountList, sizelimit=50, page=1,):

* Restart apache.

3

Re: iRedAdmin: Internal Server Error

OK. Now I get login page, but after trying to login I get again "internal server error". Apache error log shows:

[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35] Traceback (most recent call last):
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib/python2.4/site-packages/web.py-0.34-py2.4.egg/web/application.py", line 242, in process
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     return self.handle()
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib/python2.4/site-packages/web.py-0.34-py2.4.egg/web/application.py", line 233, in handle
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     return self._delegate(fn, self.fvars, args)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib/python2.4/site-packages/web.py-0.34-py2.4.egg/web/application.py", line 415, in _delegate
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     return handle_class(cls)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib/python2.4/site-packages/web.py-0.34-py2.4.egg/web/application.py", line 390, in handle_class
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     return tocall(*args)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/var/www/iredadmin/controllers/ldap/basic.py", line 74, in POST
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     adminLib = admin.Admin()
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/var/www/iredadmin/libs/ldaplib/core.py", line 66, in __init__
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     self.conn.bind_s(cfg.ldap.get('bind_dn'), cfg.ldap.get('bind_pw'))
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib64/python2.4/site-packages/ldap/ldapobject.py", line 213, in bind_s
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     return self.result(msgid,all=1,timeout=self.timeout)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib64/python2.4/site-packages/ldap/ldapobject.py", line 428, in result
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     res_type,res_data,res_msgid = self.result2(msgid,all,timeout)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib64/python2.4/site-packages/ldap/ldapobject.py", line 432, in result2
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     res_type, res_data, res_msgid, srv_ctrls = self.result3(msgid,all,timeout)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib64/python2.4/site-packages/ldap/ldapobject.py", line 438, in result3
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     ldap_result = self._ldap_call(self._l.result3,msgid,all,timeout)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]   File "/usr/lib64/python2.4/site-packages/ldap/ldapobject.py", line 96, in _ldap_call
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35]     result = func(*args,**kwargs)
[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35] INVALID_CREDENTIALS: {'info': '', 'desc': 'Invalid credentials'}





ZhangHuangbin wrote:

Oops, it's my fault. So sorry about this issue, you can fix it with below steps:

* Open libs/iredutils.py, change line 271 to below line:

def getSizelimitFromAccountLists(accountList, sizelimit=50, page=1,):

* Restart apache.

4

Re: iRedAdmin: Internal Server Error

[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35] INVALID_CREDENTIALS: {'info': '', 'desc': 'Invalid credentials'}

Your ldap bind dn and password are incorrect. Please verifiy it first. You can found it in /path/to/iRedMail-x.y.z/iRedMail.tips. It should be "cn=vmailadmin,dc=xxx,dc=xxx".

5

Re: iRedAdmin: Internal Server Error

It works now. Thanx.

ZhangHuangbin wrote:

[Mon Aug 23 14:06:48 2010] [error] [client 193.219.14.35] INVALID_CREDENTIALS: {'info': '', 'desc': 'Invalid credentials'}

Your ldap bind dn and password are incorrect. Please verifiy it first. You can found it in /path/to/iRedMail-x.y.z/iRedMail.tips. It should be "cn=vmailadmin,dc=xxx,dc=xxx".