1

Topic: queue file write error! when sending emails

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.7.2
- Deployed with iRedMail Easy or the downloadable installer? DOWNLOADABLE
- Linux/BSD distribution name and version: Debian 12.10
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL (MariaDB)
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.

“DATA command failed: Error: queue file write error”.

====

OK,

So I was going along happy as can be, everything was working great.  Then I decided it was time to do the 1/24/2025 update.  I followed along with the steps here:

https://docs.iredmail.org/upgrade.iredm … 1.7.2.html

Now I don't get emails nor can I send.  I do not get any messages stating that received emails are failing; However, I do get "Data command failed: Error: queue file write error"

I have made several changes to multiple queues that I could see and find; however, to no avail.  Still not working.  I have spent several hours working on this.  This is my own personal server that I am looking to move my family on to in the next few months.  I have enjoyed it so far with little issues here and there.  Nothing to concerning, however this one is killing me. I do use this server to receive logs and backup notifications.  Please help.  Request what you may need from me.  I will be monitoring every hour or so except after 12 PST.

FYI:  I do not wish to rebuild, I want to learn how to fix issues like this so if it happens again with my family on it, I know how to fix it.

Thank you for your help

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: queue file write error! when sending emails

Is disk space full?

3

Re: queue file write error! when sending emails

ZhangHuangbin wrote:

Is disk space full?

No, at least 1TB available

4

Re: queue file write error! when sending emails

A bit more info:

I use Evolution as my client, but, I did try both roundcube and SOGo and it still tells me queue write error.

5

Re: queue file write error! when sending emails

Maybe I need to be a little more clear.  The error is stating when I press the send button on any of my apps (evolution, roundcube, SOGo) I get an error stating that a file cannot be written to the queue in order to send the email.

I am by no means an expert with postfix or iredmail or even sendmail.  But my assumption is that when the update to 1.7.2 was done that the rwx properties of the mail queue was changed and possibly the owner:group.

So I have been working and trying to figure out the correct settings for the /var/spool/postfix directory and its contents.  I am assuming that this is the correct queue area for postfix.  Most of the directories in postfix folder and postfix folder itself are r-x "maildrop" being the one I think may be the issue.  However I don't know, I'm just guessing here.  All of the folders seem to be a queue for specific functions.

Here are the particulars of /var/spool/postfix (drwxr-xr-x) postfix:postdrop

maildrop within /var/spool/postfix is as follows: (drwxr-xr-x) postfix:postdrop
I specifically made these changes to maildrop it was (drwx-wx-T) root:root

So, I am not sure which directory is causing all of the kaos, or if I am completely off base here.

6

Re: queue file write error! when sending emails

Ok, well things seem to be working. I'm not sure what I did; however, I will show what I did just recently and I did find an error that I did in one of the steps from the upgrade instructions.

1) went back and changed the permissions as follows for ./maildrop directory (drwxrw-rw-)
2) after reading some of the files in the ./maildrop direrctory using postcat, i saw several errors, so I deleted those files
3) then I went back and reviewed the steps in the upgrade instructions and found in the /etc/postfix/mysql/sender_bcc_maps_domain.cf I misspelled active at the end of the line.  I was getting several error messages in the ./maildrop directory pertaining to this file so I relooked at it and found the error. 
4) I restarted postfix and wallah everything is pleasant again. 

So I still would like to see what the actual /var/spool/postfix permissions and owner:group is and also the contents from a actual fresh or unmodified installation of iRedMail.  Just so I have everything correct.

Thanks
I really hope my issue helps someone out there.

7

Re: queue file write error! when sending emails

Setup a new VM with same linux distribution release, then install iRedMail, you will get almost same environment as your production server. Check the permissions in VM.