Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to debug the error "Creating the mailbox admin@graphitecore.pro failed!" #780

Closed
RoyBellingan opened this issue Nov 10, 2023 · 1 comment

Comments

@RoyBellingan
Copy link

RoyBellingan commented Nov 10, 2023

I tried to look at log, but there is not much just the create_alias command...

(in the past I already created a few domain and email account on other domain)

@DavidGoodwin
Copy link
Member

hm, I think that'll be from a problem inserting into, or updating, the database. The obvious thing would be e.g. a duplicate primary key ....

Depending on your version of PostfixAdmin, you could probably find out which by editing model/PFAHandler.php and look for the 'save()' function - perhaps around line 548 .... towards the bottom of this function, there's :

        try {
            if ($this->new) {
                $result = db_insert($this->db_table, $db_values,  array('created', 'modified'),true);
            } else {
                $result = db_update($this->db_table, $this->id_field, $this->id, $db_values, array('modified'), true);
            }
        } catch (PDOException $e) {
            error_log(__FILE__ . ' - failed to save mailbox; message: ' . $e->getMessage()); // ADD THIS LINE
            $this->errormsg[] = Config::lang_f($this->msg['store_error'], $this->label);
            return false;
        }

Hopefully that will then log something useful to your web server's error log file (e.g. /var/log/apache2/error.log)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants