Email Attachments Missing


(steve schofield) #1

I have my Nethserver setup using the getmail multidrop method, and in the most part it all seems to function OK, both sending and receiving emails.

However, it has been brought to my attention, that some users have received messages and the attachments are missing.
It is not a specific user, nor do I think its a specific attachment.
Most users receive a variety of attachments OK throughout the day.

On inspecting the issue, I can see the mail has an attachment on the webserver where the mail is delivered.
I can then see getmail in my logs retrieving the mail, which is pretty much the filesize as the master email on the webserver.
I then see the local delivery to its recipients, with a much lower bytesize, hence no attachment.
Now, whether coincidence or not, those messages received seem to be delivered locally in plain text format.

Note the getmail size (81289 bytes) , and internal mail delivery, size=9677

Example below ,
Feb 17 07:27:02 mailway getmail: msg 1/1 (81289 bytes) msgid UID2998-1547579100 from to delivered to MDA_external command sendmail (), deleted

Feb 17 07:27:02 mailway postfix/pickup[103218]: 67EB712F3376: uid=988 from=

Feb 17 07:27:02 mailway postfix/cleanup[107492]: 67EB712F3376:

Feb 17 07:27:02 mailway opendkim[20648]: 67EB712F3376: no signing table match for ‘’

Feb 17 07:27:02 mailway postfix/qmgr[16413]: 67EB712F3376:, size=9677, nrcpt=2 (queue active)

Feb 17 07:27:02 mailway postfix/lmtp[107496]: 67EB712F3376: to=abcde@zzzz.intra,,[/var/run/dovecot/lmtp], delay=0.07, delays=0.02/0.01/0.01/0.03, dsn=2.0.0, status=sent (250 2.0.0 andy@ga.intra OO2rGsYMaVzpowEAubwgBw Saved)

Feb 17 07:27:02 mailway postfix/qmgr[16413]: 67EB712F3376: removed

I have turned off any mail filtering, spam checking, virus checking, but still cant seem to cure it.
Any help would be appreciated.

(Federico Ballarini) #2

Are you using webmail?

(steve schofield) #3

Nope, all mail is delivered to local mailboxes for retrieval via Outlook.

(Federico Ballarini) #4

Have you applied mail quota? Could you check that there is enough space to accept attachments?

(steve schofield) #5

I dont believe I have set any quota’s,but will double check.

There is plenty of disk space available.

I dont get it why getmail is showing the correct size when downloading the mail via pop3, but the internal delivery is stripped of the attachement

(steve schofield) #6

No quota’s have been set

(Federico Ballarini) #7

Could you try to send from another email to the same account an email with attachment? We have to understand if it is a problem due to sender or recipient.

(steve schofield) #8

Its difficult as if Im testing it myself, my attachments always seem to get through.
I was trying to see if it was specific senders, however as the issue has only just been brought to attention I have not had enough time.

(steve schofield) #9

On the master server where mail gets delivered, I setup 2 mailboxes which are basically duplicates of all incoming mail.
One of these mailboxes gets fetched by Getmail from NS , and the other is just static, storing copies of the mail.
When an email attachment is stripped by NS, i opened up the stored copy on the master server which still had the attachment and then forwarded it to myself, but this time the attachments were all there.

(steve schofield) #10

I then moved the copy on the master mail server to the mailbox that getmail fetches, and the email was fetched by NS and delivered locally OK, all attachments were intact.

(Federico Ballarini) #11

Checked by sending an email from my mail address and all works fine.
I think that error is caused by sender.

  • Check that sender IP and domain are not in blacklist. Check their reputation.
  • Check that attachment is not a possible malware.

Re-enable all filters on your NS for your security.

You could check also maillog and messages.

(Federico Ballarini) #12

@stevesco founds error! It’s documented here and it’s related to -i parameter in this case.

Good job!

Please mark this topic as solved.

Thank you.