"An error occurred while sending the mail" when changing password

wattie

Verified User
Joined
May 31, 2008
Messages
1,234
Location
Bulgaria
I get "Error while sending email" followed by "An error occurred while sending the mail" when trying to generate new random password and send it to the selected e-mail address. It happens on all accounts.

Based on my search in previous threads on this matter, it is supposed to be permissions issue. As far as I see, it's OK on my end:

Code:
root@srv2:/usr/sbin # ll | egrep "mailwrapper|exim"
-rwsr-xr-x  1 root  wheel    1382872 Jan  9 12:18 exim*
-rwxr-xr-x  1 root  wheel       4821 Jan  9 12:18 exim_checkaccess*
-rwxr-xr-x  1 root  wheel       4819 Jan  9 12:18 exim_checkaccess.O*
-rwxr-xr-x  1 root  wheel      16440 Jan  9 12:18 exim_dbmbuild*
-rwxr-xr-x  1 root  wheel      16152 Jan  9 12:18 exim_dbmbuild.O*
-rwxr-xr-x  1 root  wheel      19576 Jan  9 12:18 exim_dumpdb*
-rwxr-xr-x  1 root  wheel      16272 Jan  9 12:18 exim_dumpdb.O*
-rwxr-xr-x  1 root  wheel      29400 Jan  9 12:18 exim_fixdb*
-rwxr-xr-x  1 root  wheel      28040 Jan  9 12:18 exim_fixdb.O*
-rwxr-xr-x  1 root  wheel      15520 Jan  9 12:18 exim_lock*
-rwxr-xr-x  1 root  wheel      15520 Jan  9 12:18 exim_lock.O*
-rwxr-xr-x  1 root  wheel      24200 Jan  9 12:18 exim_tidydb*
-rwxr-xr-x  1 root  wheel      22040 Jan  9 12:18 exim_tidydb.O*
-rwxr-xr-x  1 root  wheel     151543 Jan  9 12:18 eximstats*
-rwxr-xr-x  1 root  wheel     151541 Jan  9 12:18 eximstats.O*
lrwxr-xr-x  1 root  wheel         11 Jul 29  2017 hoststat@ -> mailwrapper
-rwsr-xr-x  1 root  wheel       9024 Aug 17  2019 mailwrapper*
lrwxr-xr-x  1 root  wheel         11 Jul 29  2017 purgestat@ -> mailwrapper
lrwxr-xr-x  1 root  wheel         11 Jun  3 23:44 sendmail@ -> mailwrapper

The recent modification from Jun 3rd on the sendmail symlink is because I was trying to fix it by changing permissions on it. Then I returned from backup.

The directadmin error.log is not very helpful as it only states:

Code:
An error occurred while sending the mail

There is nothing in the mainlog.

OS: FreeBSD 11.3
Using latest Exim and latest DA to date.
 

 
thanks to smtalk the following was the resolution:

everything in /var/spool/exim/ needs to be owned by mail:mail and have chmod 750

This might be linux. I don't have a BSD box.:(
 
It looks like it is fine...

Code:
root@srv2:/var/spool/exim # ll
total 88
-rw-------     1 mail  mail     64 Apr 15 13:54 blocked_authenticated_users
-rw-------     1 mail  mail    248 May  1  2019 blocked_script_paths
drwxr-x---     2 mail  mail    512 Feb  8  2017 db/
-rw-r--r--     1 mail  mail    539 Feb 15  2017 exim-process.info
drwxr-x---    64 mail  mail   1024 Feb  9  2017 input/
drwxr-x---    64 mail  mail   1024 Feb  9  2017 msglog/
drwxr-x---  2230 mail  mail  63488 Jun  4 02:17 scan/

I searched through the subdirectories and they are mail:mail too...
 
Last edited:
OK I FOUNT IT - thanks for sending me to look into this folder.

/usr/local/directadmin was in the "blocked_script_paths" list. It looks like the Blockcracking script (or something like that) added it there a long time ago and I didn't even notice (obviously).
 
Back
Top