Error while creating a mailbox: Duplicate entry for key PRIMARY.

Created:

2016-11-16 12:54:47 UTC

Modified:

2017-08-16 15:43:55 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Error while creating a mailbox: Duplicate entry for key PRIMARY.

Applicable to:

  • Plesk 11.x for Linux

Symptoms

The following error is shown while creating a mailbox:

 MySQL query failed: Duplicate entry 'mailbox@example.com-imp-save_attachments' for key 'PRIMARY'.

Despite this error, mailbox is created.

Custom TRIGGER is added to psa.mail table:

mysql> show triggers;

Cause

Custom trigger is configured improperly.

Resolution

  1. Back up Plesk database according to article

  2. Configure the trigger properly or remove it from psa.mail table:

    mysql> DROP TRIGGER trigger_name;
    Query OK, 0 rows affected (0.00 sec)
Have more questions? Submit a request
Please sign in to leave a comment.