1

Topic: Primary address change on a mailbox

==== Required information ====
- iRedMail version (check /etc/iredmail-release):  0.9.5-1
- Linux/BSD distribution name and version:  CentOS 7
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):  MySQL
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? No
- Related log if you're reporting an issue: /var/log/maillog
====

Hi,

When I created a mailbox I created the email address as firstname@domain.com. I now want to change it so that the primary address on that mailbox becomes firstname.lastname@domain.com, so all outgoing emails will carry the new "FROM" address.I also want to continue to keep the old address, firstname@domain.com as an alias on that mailbox so I don't loose any emails destined to that address.

How can I go about making the above change?

Thanks.

----

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

2

Re: Primary address change on a mailbox

With iRedAdmin-Pro, this is easy: Go to user profile page, click "Change email address", then type new address and click "Save". if you want to use old address as an alias address, just go to "Aliases" tab in user profile page, type old address. Screenshot of user profile page attached, you can find "Change email address" in center-right corner.

Without iRedAdmin-Pro, you have to do it with sql command line (or other sql management tool), change the value in `vmail.mailbox` (column 'username'), also change `vmail.alias` (column 'goto' - as member of mail alias accounts). Also, if you used old address as default bcc address, please also update `vmail.domain` (column 'settings').


http://www.iredmail.org/images/iredadmin/user_profile_general.png

3

Re: Primary address change on a mailbox

ZhangHuangbin wrote:

With iRedAdmin-Pro, this is easy: Go to user profile page, click "Change email address", then type new address and click "Save". if you want to use old address as an alias address, just go to "Aliases" tab in user profile page, type old address. Screenshot of user profile page attached, you can find "Change email address" in center-right corner.

Without iRedAdmin-Pro, you have to do it with sql command line (or other sql management tool), change the value in `vmail.mailbox` (column 'username'), also change `vmail.alias` (column 'goto' - as member of mail alias accounts). Also, if you used old address as default bcc address, please also update `vmail.domain` (column 'settings').

With iRedMail-0.9.7 this should be changed:
still
`vmail.mailbox` (column 'username')
Also, if you used old address as default bcc address, please also update `vmail.domain` (column 'settings').

now new
`vmail.alias` (column 'address')? if existing
`vmail.forwordings`(column 'address','forwarding')?

Is this right and didn't I forget anything?

4

Re: Primary address change on a mailbox

"vmail.alias_moderators" also.

5

Re: Primary address change on a mailbox

ZhangHuangbin wrote:

"vmail.alias_moderators" also.

Thanks.
What about `vmail.mailbox` (column 'local_part')?

6

Re: Primary address change on a mailbox

ThASattler wrote:

What about `vmail.mailbox` (column 'local_part')?

"local_part" should be updated too. But CURRENTLY, this column is not used by Postfix/Dovecot/iRedAdmin at all. It's a historical reason that it still remains in iRedMail SQL table.

It will be removed in next iRedMail release (0.9.8).

7

Re: Primary address change on a mailbox

UPDATE:

`mailbox.local_part` has been removed in latest development edition:
https://bitbucket.org/zhb/iredmail/comm … 136cf95661