1

Topic: No Sent records when sending by SMTP

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release):  1.6.5 stable
- Deployed with iRedMail Easy or the downloadable installer?   downloadable installer
- Linux/BSD distribution name and version: debian 12
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- 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.
====

Dear support team,

I am a newbie to iRedMail and I found a problem with my iRedMail server:

If:

1) sending mails directly by Roundcube Webmail, I will see the mail records in the Sent box on Webmail

2) sending mails by using SMTP via PHP program, there was NO related mail records in the Sent box on Webmail although these mails has been successfully send to the users.

I wonder why this happened? I really need to record emails whether they are sent directly or by SMTP. Could someone help me?

Thank you so much.

----

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

2

Re: No Sent records when sending by SMTP

Sending a mail doesn't automatically save them, you need to take care for this on your own.
Since this is not related to iredmail, you need to check which external tools you use and lookup their respective support forums, since iredmail is not related to it in any kind

3

Re: No Sent records when sending by SMTP

Cthulhu wrote:

Sending a mail doesn't automatically save them, you need to take care for this on your own.
Since this is not related to iredmail, you need to check which external tools you use and lookup their respective support forums, since iredmail is not related to it in any kind

I think what you said is incorrect. I use SMTP to send emails through Gmail, and I can see the records in the sent mailbox. However, when using SMTP to call iRedMail, I cannot see the records.

4

Re: No Sent records when sending by SMTP

Then GMAIL automatically saves sent messages, but as i said, the external tool needs to handle this for you

5

Re: No Sent records when sending by SMTP

Cthulhu wrote:

Then GMAIL automatically saves sent messages, but as i said, the external tool needs to handle this for you


Your logic is flawed. When I send an email using SMTP with Gmail, the external program does not handle what you call "handle" for me and I did see the mails kept in the sent box. It is iredmail problem not the smtp program.

6

Re: No Sent records when sending by SMTP

Sending an email trough STMP just and only sends an email, if you want to store an email in the send folder, it is called imap stream copy, which is part of the imap protocol, and oesnt send an emal, but stores the stream as a file in a disignated mailbox, it is the same that happens when you start to write an email, but don't actually send it and instead save it as draft

as i told you: it has NOTHING to do with iredmail, you need to handle this on your own with the external tool

7

Re: No Sent records when sending by SMTP

Because you still won't believe me:

https://www.php.net/manual/en/function.imap-append.php

https://www.rfc-editor.org/rfc/rfc3501.html#page-46

What you are looking for is the APPEND command, which is even specified in RFC

You need to archive this on you own if you use external tools, it has neither to do with iredmail, not the mailserver software it uses

8

Re: No Sent records when sending by SMTP

Cthulhu wrote:

You need to archive this on you own if you use external tools, it has neither to do with iredmail, not the mailserver software it uses


I think you could add a feature to iRedMail just as this post discribing:

ht[detele this words]tps://support.cpanel.net/hc/en-us/articles/4405303695639-E-mails-are-not-being-saved-to-the-Sent-folder

9

Re: No Sent records when sending by SMTP

Thats an external tool and has nothing to do with iredmail, it is not the responsibility of a mail server to store sent mails by default, only to handle client requests

as i said, you need to implement this on you own, and the support of the external tool you use is the place to get proper support