doitbetter
New Pleskian
Hello,
when sending email from websites, the message does not get sent and I get this error in /var/log/maillog:
Sep 4 21:56:19 weba py_limit_out[7953]: ERROR Rejecting forged message: PPP_SENDER_VHOST_ID environment variable value is invalid
Sep 4 21:56:19 weba journal: plesk sendmail[7952]: handlers_stderr: DATA REPLY:554:5.7.0 Your message could not be sent. The sender's domain is not configured
properly.
REJECT
Sep 4 21:56:19 weba journal: plesk sendmail[7952]: REJECT during call 'limit-out' handler
I am using plesk 12.0 latest version. postfix+dovecot+limit outgoing email. I have also tried 12.5.30 as an early adopter. I must say that I have tried some solution switching back and forth from courier/dovecot/no mail system at all.
Further investigation pointed me to /usr/local/psa/lib/modules/python/pylib-mail-handlers/plesk_mail_handlers.py:
where I was able to log that:
PPP_SENDER_VHOST_ID=58efed62-be7c-4cd4-8b90-c00b7114d1d6
and in msqyl db calles "psa" show that the domain is there:
MariaDB [psa]> select * from dom_param where val='58efed62-be7c-4cd4-8b90-c00b7114d1d6'
-> ;
+--------+----------+--------------------------------------+
| dom_id | param | val |
+--------+----------+--------------------------------------+
| 3 | vhost_id | 58efed62-be7c-4cd4-8b90-c00b7114d1d6 |
+--------+----------+--------------------------------------+
I then investigated in /usr/local/psa/lib/modules/python/pylib-outgoing-mail/plesk_outgoing_mail_db.py.
The problem is that limits['domain ']is None: from the log: limits = {'mail': None, 'whitelist': None, 'domain': None, 'subscription': None}
and here it is the query: ERRORlesk_outgoing_mail_db:fetch_domain: limits = SELECT d.name FROM domains d JOIN vhost_ids v ON d.id = v.domain_id WHERE v.guid = 58efed62-be7c-4cd4-8b90-c00b7114d1d6
I I run the query on the database I get:
SELECT d.name FROM domains d JOIN vhost_ids v ON d.id = v.domain_id WHERE v.guid = 58efed62-be7c-4cd4-8b90-c00b7114d1d6;
ERROR 1146 (42S02): Table 'psa.vhost_ids' doesn't exist
Ok, then let's create vhost_ids as it would do in /usr/local/psa/lib/modules/python/pylib-outgoing-mail/plesk_outgoing_mail_db.py:
MariaDB [psa]> CREATE TABLE vhost_ids (
-> guid VARCHAR(36) NOT NULL PRIMARY KEY,
-> domain_id INTEGER NOT NULL,
->
-> FOREIGN KEY(domain_id) REFERENCES domains(id)
-> ON UPDATE CASCADE
-> ON DELETE CASCADE
-> );
ERROR 1005 (HY000): Can't create table 'psa.vhost_ids' (errno: 150)
MariaDB [psa]>
MariaDB [psa]> SHOW VARIABLES LIKE 'have_innodb';
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| have_innodb | YES |
+---------------+-------+
1 row in set (0.00 sec)
That error come from a wrong defined foreign key.
I changed it with "domain_id INTEGER NOT NULL"
It does not work either!
when sending email from websites, the message does not get sent and I get this error in /var/log/maillog:
Sep 4 21:56:19 weba py_limit_out[7953]: ERROR Rejecting forged message: PPP_SENDER_VHOST_ID environment variable value is invalid
Sep 4 21:56:19 weba journal: plesk sendmail[7952]: handlers_stderr: DATA REPLY:554:5.7.0 Your message could not be sent. The sender's domain is not configured
properly.
REJECT
Sep 4 21:56:19 weba journal: plesk sendmail[7952]: REJECT during call 'limit-out' handler
I am using plesk 12.0 latest version. postfix+dovecot+limit outgoing email. I have also tried 12.5.30 as an early adopter. I must say that I have tried some solution switching back and forth from courier/dovecot/no mail system at all.
Further investigation pointed me to /usr/local/psa/lib/modules/python/pylib-mail-handlers/plesk_mail_handlers.py:
where I was able to log that:
PPP_SENDER_VHOST_ID=58efed62-be7c-4cd4-8b90-c00b7114d1d6
and in msqyl db calles "psa" show that the domain is there:
MariaDB [psa]> select * from dom_param where val='58efed62-be7c-4cd4-8b90-c00b7114d1d6'
-> ;
+--------+----------+--------------------------------------+
| dom_id | param | val |
+--------+----------+--------------------------------------+
| 3 | vhost_id | 58efed62-be7c-4cd4-8b90-c00b7114d1d6 |
+--------+----------+--------------------------------------+
I then investigated in /usr/local/psa/lib/modules/python/pylib-outgoing-mail/plesk_outgoing_mail_db.py.
The problem is that limits['domain ']is None: from the log: limits = {'mail': None, 'whitelist': None, 'domain': None, 'subscription': None}
and here it is the query: ERRORlesk_outgoing_mail_db:fetch_domain: limits = SELECT d.name FROM domains d JOIN vhost_ids v ON d.id = v.domain_id WHERE v.guid = 58efed62-be7c-4cd4-8b90-c00b7114d1d6
I I run the query on the database I get:
SELECT d.name FROM domains d JOIN vhost_ids v ON d.id = v.domain_id WHERE v.guid = 58efed62-be7c-4cd4-8b90-c00b7114d1d6;
ERROR 1146 (42S02): Table 'psa.vhost_ids' doesn't exist
Ok, then let's create vhost_ids as it would do in /usr/local/psa/lib/modules/python/pylib-outgoing-mail/plesk_outgoing_mail_db.py:
MariaDB [psa]> CREATE TABLE vhost_ids (
-> guid VARCHAR(36) NOT NULL PRIMARY KEY,
-> domain_id INTEGER NOT NULL,
->
-> FOREIGN KEY(domain_id) REFERENCES domains(id)
-> ON UPDATE CASCADE
-> ON DELETE CASCADE
-> );
ERROR 1005 (HY000): Can't create table 'psa.vhost_ids' (errno: 150)
MariaDB [psa]>
MariaDB [psa]> SHOW VARIABLES LIKE 'have_innodb';
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| have_innodb | YES |
+---------------+-------+
1 row in set (0.00 sec)
That error come from a wrong defined foreign key.
I changed it with "domain_id INTEGER NOT NULL"
It does not work either!