1

Topic: Internal Server Error 500 after install iRedAdminPro

==== Required information ====
- iRedMail version (check /etc/iredmail-release): 0.93
- Linux/BSD distribution name and version: Ubuntu 15.10
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySql
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? Yes
- Related log if you're reporting an issue:
====

After install/upgrade to iRedAdminPro am getting internal server errors - Error

When clicking Preferences button in menu bar
When clicking a domain name under domains and accounts
When clicking an admin name under Admins

No error in nginx error log but access.log has lines similar to below in each case

192.168.0.31 - - [11/Jan/2016:13:09:13 +0000] "GET /iredadmin/static/default/images/login.jpg HTTP/1.1" 200 41805 "https://192.168.0.148/iredadmin" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:13 +0000] "GET /iredadmin/static/default/images/gear.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:13 +0000] "GET /iredadmin/static/default/images/login_header.png HTTP/1.1" 200 7995 "https://192.168.0.148/iredadmin" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:13 +0000] "GET /iredadmin/static/default/images/bck_black_70.png HTTP/1.1" 200 353 "https://192.168.0.148/iredadmin" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:16 +0000] "POST /iredadmin/login HTTP/1.1" 303 5 "https://192.168.0.148/iredadmin" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/dashboard/checknew HTTP/1.1" 200 18327 "https://192.168.0.148/iredadmin" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/css/fancybox.css HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/images/ico_add_12.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/images/ball_green_16.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/images/ball_blue_16.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/images/ball_red_16.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/images/ball_black_16.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/js/jquery-1.4.2.min.js HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/js/jquery.tooltip.js HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/js/jquery.idtabs.js HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/js/jquery.fancybox.js HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/js/jquery.tablesorter.js HTTP/1.1" 200 16520 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/images/action_search.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:20 +0000] "GET /iredadmin/static/default/images/bck_white_95.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:26 +0000] "GET /iredadmin/domains HTTP/1.1" 200 29467 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:26 +0000] "GET /iredadmin/static/default/images/bck_header.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/domains" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:26 +0000] "GET /iredadmin/static/default/images/rule.gif HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/domains" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:27 +0000] "GET /iredadmin/static/default/images/graph_16.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/domains" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:28 +0000] "GET /iredadmin/profile/domain/general/kalamunda.co.uk HTTP/1.1" 500 32 "https://192.168.0.148/iredadmin/domains" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:33 +0000] "GET /iredadmin/domains HTTP/1.1" 200 29467 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:35 +0000] "GET /iredadmin/profile/user/general/postmaster@kalamunda.co.uk HTTP/1.1" 500 32 "https://192.168.0.148/iredadmin/domains" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:09:38 +0000] "GET /iredadmin/domains HTTP/1.1" 499 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:22:39 +0000] "GET /iredadmin/profile/user/general/postmaster@kalamunda.co.uk HTTP/1.1" 500 32 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:22:44 +0000] "GET /iredadmin/dashboard/checknew HTTP/1.1" 200 18331 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:24:20 +0000] "GET /iredadmin/domains HTTP/1.1" 200 29467 "https://192.168.0.148/iredadmin/dashboard/checknew" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:24:21 +0000] "GET /iredadmin/profile/domain/general/kalamunda.co.uk HTTP/1.1" 500 32 "https://192.168.0.148/iredadmin/domains" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:24:25 +0000] "GET /iredadmin/domains HTTP/1.1" 200 29467 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:25:25 +0000] "GET /iredadmin/admins HTTP/1.1" 200 13470 "https://192.168.0.148/iredadmin/domains" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:25:28 +0000] "GET /iredadmin/profile/user/general/postmaster@kalamunda.co.uk HTTP/1.1" 500 32 "https://192.168.0.148/iredadmin/admins" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:25:32 +0000] "GET /iredadmin/admins HTTP/1.1" 200 13470 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:28:12 +0000] "GET /iredadmin/create/wblist HTTP/1.1" 200 14487 "https://192.168.0.148/iredadmin/admins" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:28:12 +0000] "GET /iredadmin/static/default/images/ico_attention.png HTTP/1.1" 304 0 "https://192.168.0.148/iredadmin/create/wblist" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:28:12 +0000] "GET /iredadmin/static/default/images/rule2.gif HTTP/1.1" 200 54 "https://192.168.0.148/iredadmin/create/wblist" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:28:34 +0000] "GET /iredadmin/system/wblist HTTP/1.1" 200 14525 "https://192.168.0.148/iredadmin/create/wblist" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"
192.168.0.31 - - [11/Jan/2016:13:29:15 +0000] "GET /iredadmin/system/greylisting HTTP/1.1" 500 32 "https://192.168.0.148/iredadmin/system/wblist" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2486.0 Safari/537.36 Edge/13.10586"

My settings.py is
############################################################
# DO NOT TOUCH BELOW LINE.
#
from libs.default_settings import *

############################################################
# General settings.
#
# Site webmaster's mail address.
webmaster = "postmaster@"

# Default language.
default_language = 'en_US'

# Database backend: mysql.
backend = 'mysql'

# Base directory used to store all mail data.
# iRedMail uses '/var/vmail/vmail1' as default storage directory.
# Tip: You can set a per-domain storage directory in domain profile page.
storage_base_directory = "/var/vmail/vmail1"

# Default mta transport.
# iRedMail uses 'dovecot' as defualt transport.
# Tip: You can set a per-domain or per-user transport in domain or user
#      profile page.
default_mta_transport = 'dovecot'

# Min/Max admin password length.
#   - min_passwd_length: 0 means unlimited, but at least 1 character
#                        is required.
#   - max_passwd_length: 0 means unlimited.
# User password length is controlled in domain profile.
min_passwd_length = 8
max_passwd_length = 0

#####################################################################
# Database used to store iRedAdmin data. e.g. sessions, log.
#
iredadmin_db_host = "127.0.0.1"
iredadmin_db_port = "3306"
iredadmin_db_name = "iredadmin"
iredadmin_db_user = "iredadmin"
iredadmin_db_password =xxxxxxxxxxxxx

############################################
# Database used to store mail accounts.
#
vmail_db_host = "127.0.0.1"
vmail_db_port = "3306"
vmail_db_name = "vmail"
vmail_db_user = "vmailadmin"
vmail_db_password = xxxxxxxxxxxxxxxx

#################################################################
# Settings used for Policyd (1.8.x) integration. Provides global
# white-/blacklist, sender/recipient throttling, etc.
#
# Enable policyd integration: True, False.
policyd_enabled = False

# SQL Database used to store policyd data, eg. whitelist, blacklist.
# You can find related information in policyd config files:
#   - On RHEL/CentOS:   /etc/policyd.conf
#   - On Debian/Ubuntu: /etc/postfix-policyd.conf
#   - On FreeBSD:       /usr/local/etc/policyd.conf
# Related parameters:
#   host    -> MYSQLHOST
#   port    -> 3306 (Default)
#   db      -> MYSQLDBASE
#   user    -> MYSQLUSER
#   passwd  -> MYSQLPASS
# policyd_db_host = "127.0.0.1"
# policyd_db_port = "3306"
# policyd_db_name = "cluebringer"
# policyd_db_user = "cluebringer"
# policyd_db_password = xxxxxxxxxxxxxxxxxxxxxx

##############################################################################
# Settings used for Amavisd-new integration. Provides spam/virus quaranting,
# releasing, etc.
#
# Log basic info of in/out emails into SQL (@storage_sql_dsn): True, False.
# It's @storage_sql_dsn setting in amavisd. You can find this setting
# in amavisd-new config files:
#   - On RHEL/CentOS:   /etc/amavisd.conf or /etc/amavisd/amavisd.conf
#   - On Debian/Ubuntu: /etc/amavis/conf.d/50-user.conf
#   - On FreeBSD:       /usr/local/etc/amavisd.conf
# Reference:
# http://www.iredmail.org/wiki/index.php? … in.Amavisd
amavisd_enable_logging = True


amavisd_db_host = "127.0.0.1"
amavisd_db_port = "3306"
amavisd_db_name = "amavisd"
amavisd_db_user = "amavisd"
amavisd_db_password = xxxxxxxxxxxxxxxxxxxxxxxxxxx


# #### Quarantining ####
# Release quarantined SPAM/Virus mails: True, False.
# iRedAdmin-Pro will connect to @quarantine_server to release quarantined mails.
# How to enable quarantining in Amavisd-new:
# http://www.iredmail.org/wiki/index.php? … ining.SPAM
amavisd_enable_quarantine = True

# Port of Amavisd protocol 'AM.PDP-INET'. Default is 9998.
amavisd_quarantine_port = "9998"

# Enable per-recipient spam policy, white/blacklist.
amavisd_enable_policy_lookup = True

##############################################################################
# Settings used for iRedAPD integration: throttling and more.
#
# Enable iRedAPD integration.
iredapd_enabled = True
iredapd_db_server = '127.0.0.1'
iredapd_db_port = '3306'
iredapd_db_name = 'iredapd'
iredapd_db_user = 'iredapd'
iredapd_db_password = xxxxxxxxxxxxxxxxxxxxxxxxxxxxx


##############################################################################
# Place your custom settings below, you can override all settings in this file
# and libs/default_settings.py here.
#
DEFAULT_PASSWORD_SCHEME = 'SSHA512'


Adrian

----

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

2

Re: Internal Server Error 500 after install iRedAdminPro

Dear Adrian,

Sorry about this trouble. I sent you an email with patched version of iRedAdmin-Pro, please upgrade it by following our tutorials below, it should fix all issues you experienced:
http://www.iredmail.org/docs/migrate.or … admin.html

3

Re: Internal Server Error 500 after install iRedAdminPro

ZhangHuangbin wrote:

Dear Adrian,

Sorry about this trouble. I sent you an email with patched version of iRedAdmin-Pro, please upgrade it by following our tutorials below, it should fix all issues you experienced:
http://www.iredmail.org/docs/migrate.or … admin.html


Hi, Thanks - problems all resolved

Adrian