Failed to send a message via Horde webmail: sendmail: unknown error

Created:

2016-11-16 12:57:13 UTC

Modified:

2017-08-16 17:37:40 UTC

0

Was this article helpful?


Have more questions?

リクエストを送信

Failed to send a message via Horde webmail: sendmail: unknown error

Applicable to:

  • Plesk 12.0 for Linux
  • Plesk 11.0 for Linux
  • Plesk 11.5 for Linux

Symptoms

  1. When sending a message via Horde, one of the following errors occurs:

    sendmail: unknown error (127)
    
    sendmail: unknown error (126)
    

    Horde log ( /var/log/psa-horde/psa-horde.log ) contains the error like:

    2013-12-17T00:00:52+00:00 ERR: HORDE [imp] sendmail: unknown error (127) [pid 22310 on line 1064 of "/usr/share/psa-horde/imp/lib/Compose.php"]
    
  2. PHP mail() not sending messages or mail forwarding getting failed.

    The following error can be found in /usr/local/psa/var/log/maillog :

    Command output: fork_execv: execv("/usr/sbin/sendmail") failed: Permission denied 4.2.1 Message can not be delivered at this time )
    

Cause

Symbolic link to sendmail utility is broken, or permissions for the same utility are incorrect.

Resolution

  1. Check the following set of symbolic links and make sure that none of them lead to a non-existing location:

    [root@server ~]# ll /usr/sbin/sendmail
    lrwxrwxrwx. 1 root root 21 Dec 16 13:29 /usr/sbin/sendmail -> /etc/alternatives/mta
    
    [root@server ~]# ll /etc/alternatives/mta
    lrwxrwxrwx. 1 root root 33 Dec 16 13:29 /etc/alternatives/mta -> /usr/lib64/plesk-9.0/psa-sendmail
    
    [root@server ~]# ll /usr/lib64/plesk-9.0/psa-sendmail
    ls: cannot access /usr/lib64/plesk-9.0/psa-sendmail: No such file or directory
    
  2. Remove the broken link and create a new one to the appropriate sendmail (depending on the currently used MTA) binary file:

    2.1. Unlink

    # unlink /etc/alternatives/mta
    

    2.2. Define what MTA is used:

    # /usr/local/psa/admin/bin/mailmng --features|grep SMTP_Server
    

    2.3. Make a link to an appropriate binary:

    For Qmail:

    [root@server ~]# ln -s /var/qmail/bin/sendmail /etc/alternatives/mta
    

    For Postfix:

    [root@server ~]# ln -s /usr/sbin/sendmail.postfix /etc/alternatives/mta
    
  3. Make sure that the binary has correct permissions:

    # chmod 755 /usr/sbin/sendmail.postfix
    

    or

    # chmod 555 /var/qmail/bin/sendmail
    
他にご質問がございましたら、リクエストを送信してください
ログインしてコメントを残してください。