"send copy to" does not work anymore

Discussion in 'General' started by jeensg, Feb 25, 2021.

Tags:
  1. jeensg

    jeensg New Member HowtoForge Supporter

    Hey, since some time newly created "copy send to" mails are not delivered anymore. My setup:
    • [INFO] OS version is Debian GNU/Linux 9.13 (stretch)
    • ISPConfig version is 3.2.2
    • [INFO] php (cli) version is 7.4.15
    • for Mail I use Dovecot and Postfix
    I already checked a couple of things and don't get further:
    • I checked database, the entry is there after I put new mailaddress in the send copy to field for user x (DB dbispconfig, table mail_user, column cc)
    • Entries from before (I don't know when it started, a user advised me today), that I find in table "cc" from before, do work as expected
    • newly created entries do not show up in mail-log, the original mail does
    • mails for older mailaddresses do work
    Can anybody help me on finding the problem? I guess there is something worng with postfix, so that newly created entries are not transported!? I have no clue on how to go on debugging. Thanks in advance!
     
  2. Jesse Norell

    Jesse Norell ISPConfig Developer Staff Member ISPConfig Developer

    Do you have a custom postfix template that didn't get updated when you upgraded ispconfig to 3.2.2?
     
  3. jeensg

    jeensg New Member HowtoForge Supporter

    Actually I don't know what you mean with postfix template. Well, after a quick check I found this answer!?
    I did additions to config-file (main.cf) without templates. Is it that new configurations from ISPConfig then isn't added to that file with Update?
     
    Last edited: Feb 25, 2021
  4. Jesse Norell

    Jesse Norell ISPConfig Developer Staff Member ISPConfig Developer

    Do you have any files in /usr/local/ispconfig/server/conf-custom/install/ ?
    It depends what you changed, some settings would persist, some would be overwritten.
     
  5. jeensg

    jeensg New Member HowtoForge Supporter

    In that folder I have no files (except the empty.dir-one).
    Could it be the changes in main.cf, that prevent sendings these cc/copy-mails? Which entries would be the corresponding ones? Well, actually it works for entries from before, but no new added ones.
     
  6. Jesse Norell

    Jesse Norell ISPConfig Developer Staff Member ISPConfig Developer

    It could be, among other things.
    Numerous settings, as well as the mysql lookup tables they point to. What all did you change?
    Those probably forward in sieve; now you can forward in sieve or in postfix, and there are numerous files that come in to play.

    Probably just copy your main.cf as a backup, then run the installer and reconfigure services again and see if everything works after that for new changes made to the "send copy to" field. If so, resync all mail accounts.

    Alternately you could post mail logs for when you attempt a forward, along with your main.cf, dovecot.conf, mysql-virtual_email2email.conf, and all the sieve files (3 of them) for the mailbox in question as well as the mailbox settings used, and we can try to figure out what you have going on.
     
  7. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    When updating, did you let the installer reconfigure services? This is necessary.
    If not, run a forced update:
    Code:
    ispconfig_update.sh --force
     
  8. jeensg

    jeensg New Member HowtoForge Supporter

    Hey, I just forced the Update again and then reconfigured services. This led to working "send copy to" but unfortunately a lot of other things did not afterwards:
    • mails couldn't be delivered
    • mailman didn't work anymore
    • ISPConfig showed 500 (this is a problem we had before, because /var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter ist set to php7.0-cgi, which is not even installed anymore)
    Well, some I should open other tickets or leave it, at least I got back to working server...
    My main question would be: what's the best way to preserver own configurations on updating? In this case especially main.cf of postfix. Do I have to adjust config every time by hand? Thanks for your help anyway.
    And thanks for keeping up with this software!
     
  9. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Why could mails not be delivered?
    What was/is wrong with Mailman?
    PHP 7.0 has to be installed as this is the PHP version that shipped with the OS.

    I wrote a new function for this that will be used after installing 3.2.3 (so, when updating from 3.2.2 to 3.2.3, you will have to do some adjusting, or don't reconfigure services and then run a forced update to reconfigure).
    Custom settings (lines) for Postfix should go in /usr/local/ispconfig/server/conf-custom/install/postfix_custom.conf.master

    More information on this can be found here
     
  10. jeensg

    jeensg New Member HowtoForge Supporter

    Thanks for your help. Different stuff, I wrote too fast before investigating, sorry:
    1. Mails: there was probably a misconfiguration in smtpd_recipient_restrictions, that I added before. Actually I could not find out which ones, never got that problem back. I tried different orders of the entries, still no luck. I think it might have to do more with the mailman part, see below. I hope that the additions are correct, delivering is succesful.
    2. Mailman: That was my bad. I have a multi domain mailman setup not used by ISPConfig. Therefore I need additional entries in alias_maps, virtual_alias_maps and relay_domains. First I only added the relay_domains and forgot about the other two, that's why it wasn't possible to find the correct addresses.
    3. PHP 7.0 on stretch. That's ok, but for security-reasons I do not have it installed anymore. After each Update I have to change /var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter back to
    exec /usr/bin/php-cgi7.4 \ ... or ... exec /usr/bin/php-cgi \
    -> Why isn't it possible to use php-cgi in that file anyway? The binary is then using the correct alternative!?
    4. Postfix custom settings lines: that sounds just great. Thank you for your effort. When I have additions in one line like on the smtpd_recipient_restrictions -> how could I add it if it's only one line!? I think I cannot state another line with it, no?
     
  11. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    ISPConfig supports only the PHP version that is default on the OS it runs on. On Debian 9 Stretch this PHP is version 7.0. So ISPConfig should not work if you make it run on PHP version other than 7.0.
    Additional PHP versions can be installed for website use, and set by website which PHP it uses. https://www.howtoforge.com/tutorial...fig-3-from-debian-packages-on-debian-8-and-9/
    The ISPConfig Autoinstaller by default installs additional PHP versions, at least on Debian 10 it does. Maybe Ubuntu also?
     
  12. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Yup, it does.
     
  13. jeensg

    jeensg New Member HowtoForge Supporter

    Thanks for clearing things up. But anyway :)
    My old server, still on stretch, is now running only with PHP 7.3 and 7.4 (added PHP-versions one by one, sources from ondrej, when they were EOL I purged them and changed /var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter correspondingly). And everythings works fine. So maybe I miss something?
    On our new server I only installed php7.4 right away, with the same sources. Also everythings works fine. Here it was even better, since /var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter was pointing now to php-cgi and NOT php7.x-cgi anymore. Is there something more to look out for?
    On the new server I got some problems with roundcube and phpmyadmin, since meta-packages were auto-updating to 8.0, but re-installed them by hand afterwards and now it works. Even additional php8.0 is now in its place, but not for ISPConfig/Roundcube, as advised in the forum.
    Thanks for all your energy and making this possible.
     
  14. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    As long as you use PHP 7.X, the functions will work. But some thing may break, like you experience with the fcgi-starter. ISPConfig depends on the default version and expects it to be there. It should never be removed.

    This can be resolved by using php-fpm instead of mod-php for those two.
     

Share This Page