1

Topic: New reinstall on FreeBSD - logins fail

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release):

1.7.4 MARIADB edition

- Deployed with iRedMail Easy or the downloadable installer?

Downloadable (package) installer

- Linux/BSD distribution name and version:

FreeBSD 14.3-RELEASE-p2 GENERIC amd64

- Store mail accounts in which backend (LDAP/MySQL/PGSQL):

MySQL (MariaDB)

- Web server (Apache or Nginx):

Nginx

- Manage mail accounts with iRedAdmin-Pro?

No

- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

I did a reinstall of iRedMail, and now neither as a mail user nor as admin, even if using the credentials from iRedMail.tips - all I get is "Error: Username or password is incorrect."

Only log files with any entries are daemon.log and nginx/access.log, but neither are very helpful.

daemon.log:
Sep  2 15:24:12 postman uwsgi[75734]: [xx.xx.xx.xx] POST /iredadmin/login 303 242 "https://postman.xxx.com/iredadmin/login … REDENTIALS"
Sep  2 15:24:12 postman syslogd: last message repeated 1 times
Sep  2 15:24:13 postman uwsgi[75734]: [xx.xx.xx.xx] GET /iredadmin/login?msg=INVALID_CREDENTIALS 200 5804 "https://postman.xxx.com/iredadmin/login … REDENTIALS"

nginx/access.log:
xx.xx.xx.xx - - [02/Sep/2025:15:24:13 +0200] "GET /iredadmin/login?msg=INVALID_CREDENTIALS HTTP/2.0" 200 1373 "https://postman.xxx.com/iredadmin/login … REDENTIALS" "Mozilla/5.0 (X11; Linux x86_64; rv:141.0) Gecko/20100101 Firefox/141.0"
xx.xx.xx.xx - - [02/Sep/2025:15:24:13 +0200] "GET /iredadmin/static/favicon.ico HTTP/2.0" 200 1150 "https://postman.xxx.com/iredadmin/login … REDENTIALS" "Mozilla/5.0 (X11; Linux x86_64; rv:141.0) Gecko/20100101 Firefox/141.0"

Any ideas/suggestions?

  Julf

----

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

2

Re: New reinstall on FreeBSD - logins fail

- What do you mean by "reinstall"?
- Do you have correct SQL usernames and passwords in Postfix/Dovecot/iRedAdmin config files?

3

Re: New reinstall on FreeBSD - logins fail

ZhangHuangbin wrote:

- What do you mean by "reinstall"?

Removed runtime/install.status and re-ran iRedMail.sh

ZhangHuangbin wrote:

- Do you have correct SQL usernames and passwords in Postfix/Dovecot/iRedAdmin config files?

I did not change them, I assume they are taken from the "config" file.

4

Re: New reinstall on FreeBSD - logins fail

julf wrote:

I did not change them, I assume they are taken from the "config" file.

Please double check and verify whether they're correct ones.

5

Re: New reinstall on FreeBSD - logins fail

julf wrote:

Removed runtime/install.status and re-ran iRedMail.sh

This is not supported by iRedMail installer.

6

Re: New reinstall on FreeBSD - logins fail

ZhangHuangbin wrote:
julf wrote:

Removed runtime/install.status and re-ran iRedMail.sh

This is not supported by iRedMail installer.

Ah. Thanks! What is the process for reinstalling? Individually removing all the packages first?

7

Re: New reinstall on FreeBSD - logins fail

ZhangHuangbin wrote:
julf wrote:

I did not change them, I assume they are taken from the "config" file.

Please double check and verify whether they're correct ones.

All the passwords in /usr/local/etc/postfix/mysql/* and /usr/local/etc/dovecot/dovecot-mysql.conf are the same as the "Bind account (read-only)" one, and iredadmin_db_password in /usr/local/www/iRedAdmin-2.6/settings.py matches the iRedAdmin SQL database password in iRedMail.tips

8

Re: New reinstall on FreeBSD - logins fail

Did you ever verify the sql usernames and password with "mysql" command? Try to connect to mysql server with these usernames and passwords.

9

Re: New reinstall on FreeBSD - logins fail

ZhangHuangbin wrote:

Did you ever verify the sql usernames and password with "mysql" command? Try to connect to mysql server with these usernames and passwords.

What are the database names?

10

Re: New reinstall on FreeBSD - logins fail

The sql username is same as database name, except user "vmailadmin" (it accesses "vmail" database with read+write privileges).

11 (edited by julf 2025-09-04 20:13:36)

Re: New reinstall on FreeBSD - logins fail

ZhangHuangbin wrote:

The sql username is same as database name, except user "vmailadmin" (it accesses "vmail" database with read+write privileges).

Hmm - both vmail and vmailadmin users work with the vmailadmin database, but the domain admin user (postmaster@domain) doesn't work with the iredadmin database.

12

Re: New reinstall on FreeBSD - logins fail

Reset postmaster@' password: https://docs.iredmail.org/reset.user.password.html

13

Re: New reinstall on FreeBSD - logins fail

ZhangHuangbin wrote:

Reset postmaster@' password: https://docs.iredmail.org/reset.user.password.html

Thanks - that made it possible to log in as a mail user, but still not into iRedAdmin, so I guess I also need to update the password in the iredadmin database? Is that also the "mailbox" field (as the instructions you linked to only seem to update the "mailbox" field in the "vmail" database)?

14

Re: New reinstall on FreeBSD - logins fail

try to promote this user as a global admin:
https://docs.iredmail.org/promote.user. … admin.html

There's no password in "iredadmin" database, iRedAdmin queries accounts from `vmail` database.

15

Re: New reinstall on FreeBSD - logins fail

ZhangHuangbin wrote:

try to promote this user as a global admin:
https://docs.iredmail.org/promote.user. … admin.html

I get ERROR 1062 (23000): Duplicate entry 'postmaster@xxxxx.com-ALL' for key 'domain_admins.PRIMARY'

so seems postmaster was already promoted, but still can't log in.