Mailing List Archive

Duplicate Emails
I have a question regarding backup servers.

I have 2 servers that rsync the mail between them on a regular basis. The
problem is that
if I have to move to the backup server, when my users connect to their pop
accounts
they get all their mail that they have left on the server again... Is there
some way around
this ????

qmail+vpopmail --- > virtual domains --> courier-imap pop3

Dave
Re: Duplicate Emails [ In reply to ]
On Tue, 2002-12-31 at 13:36, Dave Lewis wrote:

> I have 2 servers that rsync the mail between them on a regular basis. The
> problem is that
> if I have to move to the backup server, when my users connect to their pop
> accounts
> they get all their mail that they have left on the server again... Is there
> some way around
> this ????

With pop3 probably not since the UID will be different and status isn't
stored on the server. I cant think of any easy way to make the UID the
same on two different servers.
With IMAP is should just work, since the status of the message is stored
on the server.

---
Lars Hansson
RE: duplicate emails [ In reply to ]
I've seen this issue with failing hardware. Either a disk controller or HD
going bad. Seemed to happen to use with large attachments that created
heavy Disk I/O. We replaced a HD and the problem went away.



_____

From: Steve Ingraham [mailto:singraham@okcca.net]
Sent: Tuesday, September 26, 2006 12:13 PM
To: qmailtoaster-list@qmailtoaster.com; qmail@list.cr.yp.to;
users@spamassassin.apache.org
Subject: duplicate emails



I need help with a problem. Our users are seeing some multiple duplicate
emails coming from the same sender. This is not occurring with every email
so there does not seem to be any pattern to which incoming emails will be
duplicated and which ones won't. They are also reporting that duplicate
emails are sent when they send to an outside email. Has anyone experienced
this problem before? What could be causing this to occur and what can I do
to stop this? I am running qmailtoaster and spamassassin as an external
email gateway. There has been nothing changed with qmail but I did update
some rules in SA using rules_du_jour yesterday. Would these rules updates
cause this problem? If so, what would have changed?



Thanks for any help that can be provided.

Steve Ingraham

Director of Information Services

Oklahoma Court of Criminal Appeals

singraham@okcca.net

405 522-5343
Re: duplicate emails [ In reply to ]
> I need help with a problem. Our users are seeing some multiple
> duplicate emails coming from the same sender. This is not occurring
> with every email so there does not seem to be any pattern to which
> incoming emails will be duplicated and which ones won't. They are also
> reporting that duplicate emails are sent when they send to an outside
> email. Has anyone experienced this problem before? What could be
> causing this to occur and what can I do to stop this? I am running
> qmailtoaster and spamassassin as an external email gateway. There has
> been nothing changed with qmail but I did update some rules in SA using
> rules_du_jour yesterday. Would these rules updates cause this problem?
> If so, what would have changed?
>
Well, either you sent this twice from your client, or your Exchange server
is duplicting emails. Here are the headers of the 2 messages that got
sent to the list:

First message:
Received: (qmail 3632 invoked by uid 515); 26 Sep 2006 15:50:23 -0500
Delivered-To: honorablemenschen.com-qmail@honorablemenschen.com
Received: (qmail 3623 invoked by uid 0); 26 Sep 2006 15:50:23 -0500
Received: from stoneport.math.uic.edu (131.193.178.160)
by wiley.coyotetechnical.com with SMTP; 26 Sep 2006 15:50:23 -0500
Received: (qmail 62073 invoked by uid 1004); 26 Sep 2006 20:50:11 -0000
Mailing-List: contact qmail-help@list.cr.yp.to; run by ezmlm
Precedence: bulk
Delivered-To: mailing list qmail@list.cr.yp.to
Received: (qmail 98196 invoked from network); 26 Sep 2006 17:28:30 -0000
Received: from mail.occa.state.ok.us (HELO dellapp02.occa.state.ok.us)
(204.87.111.225)
by stoneport.math.uic.edu with SMTP; 26 Sep 2006 17:28:30 -0000
Received: (qmail 3657 invoked by uid 507); 26 Sep 2006 17:26:20 -0000
Received: by simscan 1.1.0 ppid: 1730, pid: 1737, t: 285.5289s
scanners: clamav: 0.86.2/m:34/d:1084 spam: 3.0.4
Received: from unknown (HELO MXI.occa.state.ok.us) (204.87.111.232)
by dellapp02.occa.state.ok.us with SMTP; 26 Sep 2006 17:21:34 -0000
Received: from mxi2.occa.state.ok.us ([172.16.254.137]) by
MXI.occa.state.ok.us with Microsoft SMTPSVC(5.0.2195.6713);
Tue, 26 Sep 2006 12:15:34 -0500
MIME-Version: 1.0
Content-Type: multipart/alternative;
boundary="----_=_NextPart_001_01C6E18F.0985C8B2"
Subject: duplicate emails
Content-class: urn:content-classes:message
X-MimeOLE: Produced By Microsoft Exchange V6.5
Date: Tue, 26 Sep 2006 12:13:08 -0500
Message-ID: <088EFB279DB2A64688EE22B92FBEABA0298F@mxi2.occa.state.ok.us>
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
Thread-Topic: duplicate emails
Thread-Index: AcbhjwlJO63enV2QR4SUkJYxOIDuqQ==
From: "Steve Ingraham" <singraham@okcca.net>
To: <qmailtoaster-list@qmailtoaster.com>,
<qmail@list.cr.yp.to>,
<users@spamassassin.apache.org>
X-OriginalArrivalTime: 26 Sep 2006 17:15:34.0445 (UTC)
FILETIME=[60A225D0:01C6E18F]

Second Message:
Received: (qmail 8489 invoked by uid 515); 26 Sep 2006 16:13:03 -0500
Delivered-To: honorablemenschen.com-qmail@honorablemenschen.com
Received: (qmail 8481 invoked by uid 0); 26 Sep 2006 16:13:02 -0500
Received: from stoneport.math.uic.edu (131.193.178.160)
by wiley.coyotetechnical.com with SMTP; 26 Sep 2006 16:13:02 -0500
Received: (qmail 96869 invoked by uid 1004); 26 Sep 2006 21:13:06 -0000
Mailing-List: contact qmail-help@list.cr.yp.to; run by ezmlm
Precedence: bulk
Delivered-To: mailing list qmail@list.cr.yp.to
Received: (qmail 75419 invoked from network); 26 Sep 2006 18:26:25 -0000
Received: from mail.occa.state.ok.us (HELO dellapp02.occa.state.ok.us)
(204.87.111.225)
by stoneport.math.uic.edu with SMTP; 26 Sep 2006 18:26:25 -0000
Received: (qmail 30058 invoked by uid 507); 26 Sep 2006 18:24:23 -0000
Received: by simscan 1.1.0 ppid: 28504, pid: 28521, t: 223.7263s
scanners: clamav: 0.86.2/m:34/d:1084 spam: 3.0.4
Received: from unknown (HELO MXI.occa.state.ok.us) (204.87.111.232)
by dellapp02.occa.state.ok.us with SMTP; 26 Sep 2006 18:20:39 -0000
Received: from mxi2.occa.state.ok.us ([172.16.254.137]) by
MXI.occa.state.ok.us with Microsoft SMTPSVC(5.0.2195.6713);
Tue, 26 Sep 2006 10:53:32 -0500
MIME-Version: 1.0
Content-Type: multipart/alternative;
boundary="----_=_NextPart_001_01C6E183.EB0C6D2E"
Subject: duplicate emails
Content-class: urn:content-classes:message
X-MimeOLE: Produced By Microsoft Exchange V6.5
Date: Tue, 26 Sep 2006 10:53:32 -0500
Message-ID: <088EFB279DB2A64688EE22B92FBEABA0298D@mxi2.occa.state.ok.us>
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
Thread-Topic: duplicate emails
Thread-Index: Acbhg+rbU74bClOIRmmEHaapA2ukfQ==
From: "Steve Ingraham" <singraham@okcca.net>
To: <qmailtoaster-list@qmailtoaster.com>,
<qmail@list.cr.yp.to>,
<users@spamassassin.apache.org>
X-OriginalArrivalTime: 26 Sep 2006 15:53:32.0616 (UTC)
FILETIME=[EAFEA480:01C6E183]

Notice that the message IDs are only 2 apart - I think this is being
duplicated at the point of origin...

Josh
--
Joshua Megerman
SJGames MIB #5273 - OGRE AI Testing Division
You can't win; You can't break even; You can't even quit the game.
- Layman's translation of the Laws of Thermodynamics
qmail@honorablemenschen.com
Re: duplicate emails [ In reply to ]
Steve Ingraham <singraham@okcca.net> wrote:
> I need help with a problem. Our users are seeing some multiple
> duplicate emails coming from the same sender. This is not occurring
> with every email so there does not seem to be any pattern to which
> incoming emails will be duplicated and which ones won't. They are also
> reporting that duplicate emails are sent when they send to an outside
> email.

That might tend to indicate that qmail is starting a delivery of a message but
is being interrupted before the delivery is complete. It can also be a sign
that your queue directory structure has been corrupted.

The qmail-send logs are the usual way to track down a problem like this. Take
a message you know to have suffered this multiple deliveries problem, and then
find out (from the qmail-send logs) at what point the duplication occurred:

-before it got to your server -- i.e., the duplication occurred on another
machine, and both copies were delivered to your server properly.

-while on your server -- qmail made multiple mostly-successful deliveries of
the message, but was unable to declare the message successfully delivered,
so it had to try again.

Charles
--
--------------------------------------------------------------------------
Charles Cazabon <qmail@discworld.dyndns.org>
Read http://pyropus.ca/personal/writings/12-steps-to-qmail-list-bliss.html
My services include qmail consulting. See http://pyropus.ca/ for details.
--------------------------------------------------------------------------
RE: duplicate emails [ In reply to ]
Mark Adams wrote:
What is your exchange server hosting? pop3? I have noted problems before
with clients recieving duplicate emails when connections timeout and the
server does not know how far the client application has gone through
the download of the mailbox - causing it to start downloading again. Are
any of the clients remote from the server? (this is where i noted the
problem most, notably on mobile internet devices especially on high
speed trains etc..)


All clients are networked desktop machines. There are no remote
connections.

Steve Ingraham
RE: duplicate emails [ In reply to ]
Loren Wilton wrote:
>I did notice one possible problem in that debug output. There was an
>'inappropriate ioctl for device' message in the whitelist stuff near
the
>end.

>This is something that has been a problem for other and has been
discussed
>before, but I don't recall what the usual fix is to solve this problem.
I
>don't think it is causing your duplicate emails, but there is a minor
nit
>there that is probably making AWL not work right.

Thanks for the information Loren, it appears that email is delivering
normally again. I definitely would not know enough of what I was doing
to start changing anything with this issue. I feel shell shocked for
now and want to leave well enough alone now that things are functioning
again. I really do think I need an expert to look over my
configuration. Who knows what I may have screwed up? I will say that I
don't know for sure.

As a note, I "think" I may know what could have caused my problems with
duplicate emails. I do believe that when I ran the RDJ script and
attempted to update the rules this bogged down the email server. As
Jake mentioned the other day, this caused delivery problems with qmail.
Once I stopped the update; removed all of the rules out of
/etc/mail/spamassassin and rebooted the server (I still cannot start
spamassassin by using /etc/init.d/spamassassin restart), email started
delivering normally. It appears that the server resources were being
maxed out.

On another note, I believe I had a compounding problem with our internal
email server running Exchange 2000 that coincided with the above
problem. The C: drive on that server filled up and thus stopped the
Microsoft Exchange MTA Stack service that evidently delivers mail from
non-Exchange systems.

Here is Microsoft's description of the function of the Exchange MTA
Stack service:

The Microsoft Exchange MTA Stacks service (MTA) routes messages through
X.400 and gateway connectors to non-Exchange messaging systems. In a
mixed environment with servers running Exchange Server 5.5 in the local
routing group, the MTA is also used to transfer messages between
Exchange Server 2003 and Exchange Server 5.5. This occurs because
Exchange Server 5.5 MTAs communicate with each other in the local site
directly through RPCs. Exchange Server 2003 must rely on this
communication method for backward compatibility.

The executable file of the Microsoft Exchange MTA Stacks service is
EMSMTA.exe, which is located in the \Program Files\Exchsrvr\bin
directory. This service depends on System Attendant and maintains its
own specific message queues outside the Exchange store in the \Program
Files\Exchsrvr\Mtadata directory. The registry key is
HKEY_Local_Machine\System\CurrentControlSet\Services\MSExchangeMTA.

Note

You should leave the Microsoft Exchange MTA Stacks service running, so
that server monitors in their default configuration do not report a
server running Exchange Server as unavailable.

These two things I think were Cause 1 and Cause 2 of my failure, at
least I think they were. I will say that stopping the RDJ update and
removing all unnecessary rule sets out of /etc/mail/spamassassin helped
get the system delivering again, furthermore, once I freed up space on
the Exchange 2000 machine and restarted the MTA Stack service things
started going back to normal.

Of course this brings me right back to my original reason for starting
this process this week. Our users are getting a lot of spam in their
mailboxes that I was trying to block from getting through by updating
rules in spamassassin. George, I have included some of the things you
mentioned that I could put in the blacklist file. I have also removed
all rules except 70_sare_adult.cf, 70_sare_bayespoison_nmx.cf,
random.cf, 70_sare_evilnum0.cf from /etc/mail/spamassassin. I would
appreciate any information on whether these rules are beneficial for me
to keep. I would also like to know if there are others that I have
removed or do not have that I need to put into this folder.

I need an education on these systems. I would welcome anyone interested
in contacting me in regards to helping with my education. I also still
feel the need to have an expert pair of eyes look over my system as I am
not totally convinced that everything is configured properly.

Thanks to everyone for their help,
Steve Ingraham
Re: duplicate emails [ In reply to ]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

In article <CALLMMt-j_jfR9WWDL18t+LJsLF13Fmg7F=aZfF4BwkTGCeS1XQ@mail.gmail.com> you write:
>Would it be possible in qmail that all outgoing email will be sent
>also to a certain user? E.g. if I send an email to yahoo.com, a same
>email will be sent also to my mailbox?

There are several ways to do this, all discussed over the years on
this list.

Probably the easiest is a shim around qmail-queue that adds a
recipient address of your mailbox if it's not already present.

R's,
John
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.21 (FreeBSD)

iEYEARECAAYFAlI97IQACgkQkEiFRdeC/kWrwACgowuxIcK0Utkrtnm2ctjdtZ6S
PvoAnAqEvqpigtUF6/4z24Ju3YBmxCl9
=XDml
-----END PGP SIGNATURE-----
Re: duplicate emails [ In reply to ]
On Sat, Sep 21, 2013 at 02:13:35PM +0800, Nelson wrote:
> Would it be possible in qmail that all outgoing email will be sent
> also to a certain user? E.g. if I send an email to yahoo.com, a same
> email will be sent also to my mailbox?

I think what you're after is qmail-tap.

http://www.inter7.com/?page=qmailtap

--
Best regards,
Ed http://www.s5h.net/
Re: duplicate emails [ In reply to ]
On Sun, Sep 22, 2013 at 3:01 AM, ed <ed-qmail@s5h.net> wrote:
> I think what you're after is qmail-tap.
>
> http://www.inter7.com/?page=qmailtap

Thanks! Is it possible to only copied incoming/outgoing emails WITH
attachment only?
Re: duplicate emails [ In reply to ]
Thus said Nelson on Sat, 21 Sep 2013 14:13:35 +0800:

> Would it be possible in qmail that all outgoing email will be sent
> also to a certain user? E.g. if I send an email to yahoo.com, a same
> email will be sent also to my mailbox?

Perhaps this will meet your needs:

http://cr.yp.to/qmail/faq/admin.html#copies

Andy

--
TAI64 timestamp: 40000000523e38c3
Re: duplicate emails [ In reply to ]
>> I think what you're after is qmail-tap.
>>
>> http://www.inter7.com/?page=qmailtap
>
>Thanks! Is it possible to only copied incoming/outgoing emails WITH
>attachment only?

Copy all of them, and at the delivery step use something like procmail
to throw away the ones without attachments.
Re: duplicate emails [ In reply to ]
On Sun, Sep 22, 2013 at 9:31 AM, John Levine <johnl@iecc.com> wrote:
> Copy all of them, and at the delivery step use something like procmail
> to throw away the ones without attachments.

Isn't procmail for incoming only?
Re: duplicate emails [ In reply to ]
> On Sun, Sep 22, 2013 at 9:31 AM, John Levine <johnl@iecc.com> wrote:
>> Copy all of them, and at the delivery step use something like procmail
>> to throw away the ones without attachments.
>
> Isn't procmail for incoming only?

Of course. I mean the delivery step for wherever you put the duplicates.

Regards,
John Levine, johnl@iecc.com, Primary Perpetrator of "The Internet for Dummies",
Please consider the environment before reading this e-mail. http://jl.ly
Re: duplicate emails [ In reply to ]
On Sun, Sep 22, 2013 at 10:46:18AM +0800, Ker Nelson wrote:
> On Sun, Sep 22, 2013 at 9:31 AM, John Levine <johnl@iecc.com> wrote:
> > Copy all of them, and at the delivery step use something like procmail
> > to throw away the ones without attachments.
>
> Isn't procmail for incoming only?

Yes, and that is is why it's called a delivery step. At some point the copies you want have to be delivered to a mailbox, which is where you invoke procmail.

--
... _._. ._ ._. . _._. ._. ___ .__ ._. . .__. ._ .. ._.
Felix Finch: scarecrow repairman & rocket surgeon / felix@crowfix.com
GPG = E987 4493 C860 246C 3B1E 6477 7838 76E9 182E 8151 ITAR license #4933
I've found a solution to Fermat's Last Theorem but I see I've run out of room o