fix postfix warning symlink leaves directory

Discussion in 'Server Operation' started by conny2540, Jul 3, 2019.

  1. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    If you followed this tutorial, the real certificate is indeed outside of /etc/postfix, and there is a symlink to the certificate
     
  2. Danrancan

    Danrancan New Member

    I followed a linode tutorial here (i'm too new to post full links):
    Code:
    www dot linode dot com/docs/email/postfix/email-with-postfix-dovecot-and-mysql/#
    Here's the output of ls -l /etc/postfix/

    Code:
    sudo ls -l /etc/postfix/
    [sudo] password for myserver:
    total 152
    -rw-r----- 1 root root   100 May 20 17:51 dynamicmaps.cf
    drwxr-x--- 2 root root  4096 Jan 15 08:05 dynamicmaps.cf.d
    -rw-r----- 1 root root  5475 May 26 03:35 main.cf
    -rw-r----- 1 root root  1511 May 24 16:35 main.cf.orig
    -rw-r----- 1 root root 27122 May  4 08:04 main.cf.proto
    lrwxrwxrwx 1 root root    31 May  4 08:04 makedefs.out -> /usr/share/postfix/makedefs.out
    -rw-r----- 1 root root  6784 May 26 03:26 master.cf
    -rw-r----- 1 root root  6208 May 24 16:59 master.cf.orig
    -rw-r----- 1 root root  6208 May  4 08:04 master.cf.proto
    -rw-r----- 1 root root   169 May 24 16:57 mysql-virtual-alias-maps.cf
    -rw-r----- 1 root root   160 May 24 16:57 mysql-virtual-email2email.cf
    -rw-r----- 1 root root   157 May 24 16:56 mysql-virtual-mailbox-domains.cf
    -rw-r----- 1 root root   156 May 24 16:56 mysql-virtual-mailbox-maps.cf
    -rw-r----- 1 root root 10268 Jan 15 08:05 postfix-files
    drwxr-x--- 2 root root  4096 May 20 17:51 postfix-files.d
    -rwxr-x--- 1 root root 11532 Jan 15 08:05 postfix-script
    -rwxr-x--- 1 root root 29872 Jan 15 08:05 post-install
    drwxr-x--- 2 root root  4096 Jan 15 08:05 sasl
    Lastly, sorry for the late response! I had to table this project for a while but now i'm back at it.
     
  3. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    the ones for smtpd.cert and smtpd.key are simple, they only exist if you've deleted the existing files and configured symlinks to point to your letsencrypt files. ( or the /usr/local/ispconfig/ssl/ cert files)
    you should know whether or not you've done this, so you should know if it's something you can ignore.
    you could if you really really want to remove that log warning and might forget about copying the cert files, you could remove the symlinks and use inotify or incrond to monitor the folder containing the certificate files, and run scripts to copy them to the postfix folder, (and using cat to combine multiple files where required), whenever one of the files changes.
    it's a lot of complication, and just another thing that could break, for something that you can just ignore.

    the symlink for makedefs.out is because of changes made on Debian systems.
    they've moved it out of the /etc/ path so it's no longer used as a conf file, they moved it to the /usr/share/postfix/ folder.
    they create a symlink for it because some users expect to see the file there.
    https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=926331
    if you don't like the warning, you could of course delete the symlink and move the file back into /etc/postfix. just expect to get asked about which version of the conf file you want to use/keep every single time there's a postfix upgrade though...
    https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=908545
     
  4. ahrasis

    ahrasis Well-Known Member HowtoForge Supporter

    He now mentioned he was following linode tutorial, so he should be asking linode the how about to do that.

    We have explained that our related tutorials does require such symlinks and the related warnings are ignorable, which should suffice.
     
  5. elmacus

    elmacus Active Member

    ahrasis likes this.
  6. The only question I have is if this has any effect if Postfix is running inside a chrooted environment...
     
  7. Steini86

    Steini86 Active Member

    As always: It depends. If postfix can access the file while being inside the chroot, everything is fine.
    But I suspect that if postfix would not be able o read the file, you would get an error.
     
    ahrasis likes this.
  8. ahrasis

    ahrasis Well-Known Member HowtoForge Supporter

    I don't think I found any of this in the PST, but we do suggest RC to use its own website in a multi server setup and that is not a problem at all.
     

Share This Page