Connection Timeouts and Sending Msg. Failed Errors

Discussion of general topics about Mozilla Thunderbird
SirHangDangly
Posts: 7
Joined: November 2nd, 2005, 9:21 am

Post by SirHangDangly »

I'm here. :)

As someone suggested in some thread, if you open Thunderbird, then open Task Manager and set the processor affinity to one processor or the other, it works. I have no timeouts at all whatsoever when I do that. It is a pain, but it works.
suryoyo
Posts: 60
Joined: June 9th, 2005, 2:55 pm

Post by suryoyo »

You mean when you have a dual core processor? Don't you have to have the AMD driver installed to do that?

Edit: I found the set affinity setting on task manager. You are absolutely right. Setting the program to CPU 1 (1 core of 2) I don't get a single time out error. That is unbelievable. Is there a way to permanently set this setting though because every time I start up the program it resets to using 2 cores.
mmoy
Posts: 5030
Joined: February 17th, 2004, 9:05 pm
Location: New Hampshire
Contact:

Post by mmoy »

This sounds like a bug in Mozilla threading. The symptoms sound like a deadlock problem (I used to work on these in the 1980s).
Dell E521 X2 5600+ MacBookPro 17'' 2.5 Ghz Penryn Dell M1330 2.0 Ghz Merom 4 GB Vista x64 Compaq r3000z AMD 64 3200+ (Win 32/64) PowerMac G5 1.8 Ghz MMOY-1.5 (OSX 10) Inspiron 8500, 4100, 4000, Dimension 2300 MacBook Pro 2.2 Ghz HP E6600 HP X2 4400+
suryoyo
Posts: 60
Joined: June 9th, 2005, 2:55 pm

Post by suryoyo »

Hey sirhangdangly somebody responded on Mmoy's thread about a program called affinity.exe



http://www.ex-parrot.com/~chris/software.html#affinity

"that should be what you're after, or suryoyo can use the exe (affinity --random --run thunderbird.exe) to run thunderbird each time Wink

Enf..."

running affinity --cpu 1 or 0 --run thunderbird.exe tells thunderbird to use the core you want and fixes all the timeout errors I was having.

This I think will also get rid of the errors I was having sending emails. It used to say sending of message failed because of some smtp connection error or some such thing.
Greenwich-kid
Posts: 31
Joined: December 12th, 2005, 7:28 am
Location: London
Contact:

Post by Greenwich-kid »

Guys just a few things here, and I know that some of you found your problems but just because you get a time out in TBird it doesn't necessarily have to mean you have a TBird problem. Timeouts are generally network issues and until you have ruled out a network problem there is no point blaming TBird. It may well be TBird but before assuming this you should do a couple of things, assuming you connect externally and your mail server isn't on your own subnet that is.

First do two pings one being using IP and the other Name Service

The first example being ip you should put in the ip of your mail server, if you don't know it go to www.samspade.org put in your mail server name (as in mail.microsoft.com or smtp.micorsoft.com, if you don't know your mail server name it will be in your settings if you use pop it will be in the pop server field and likdewise if it is smtp it will be in the smtp field, unless you have an IP address instead) into the blackhole field when the results are returned you will see something like this:
[mail.microsoft.com resolves to 217.112.85.133 217.112.85.135] This gives any of the ip addresses your mail goes to.

Then open up a command prompt CMD in [START] [RUN]

Then type ping -t -l and a value I suggest 5, 5 being the number of bytes you want to send and your IP. The -T switch means you will keep pinging instead of the normal 4 ping requests and -L is the byte size 5 - 50 is sensible, example below

C:\>ping -t -l 5 192.168.0.171

Pinging 192.168.0.171 with 5 bytes of data:

Reply from 192.168.0.171: bytes=5 time<10ms TTL=128
Reply from 192.168.0.171: bytes=5 time<10ms TTL=128
Reply from 192.168.0.171: bytes=5 time<10ms TTL=128
Reply from 192.168.0.171: bytes=5 time<10ms TTL=128
Reply from 192.168.0.171: bytes=5 time<10ms TTL=128
Reply from 192.168.0.171: bytes=5 time=16ms TTL=128

To Stop the ping request do [CTRL] [C]

Once you have done this

Do another ping using the mail server name Example below

Pinging mail.2kcafe.co.uk [217.112.85.133] with 5 bytes of data:

Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time<10ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58
Reply from 217.112.85.133: bytes=5 time=16ms TTL=58

Ping statistics for 217.112.85.133:
Packets: Sent = 10, Received = 10, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 16ms, Average = 14ms

Now the reason you do this is simply to confirm that there are no network problems and you have no Name Service problems.

If in your ping you get a time = that bounces around alot as in from 100 - 300 ms then the time out could be this. If you don't then get on and blame Windows any other OS then Thunderbird, although in general I have to say 90% of all time out errors I have seen are due to network or other such errors and not TBird, so hey rule out all ohter possibiliteis first :-)

FYI I Use XP 64 bit and TBird 1.5RC1 32 bit no timeout at all but as the 2nd example is my mail server you'd be very surprised to get timeout errors on 16ms response times.. For the guy using the Multi Core CPU I'm sure there is a downloadable from AMD that addresses such issues in the OS...
SirHangDangly
Posts: 7
Joined: November 2nd, 2005, 9:21 am

Post by SirHangDangly »

I'm sure that will help some people. Thanks!

My mail server is on my local subnet and before I upgraded my machine and OS, everything was peachy. I'll try that affinity program because having to set it every time is a pain like suryoyo said.

I would think someone working on dev of Tbird would have run into this by now or at least looked into it. Has anyone had this issue running on Linux with the same hardware? I have not re-installed mine yet.
Greenwich-kid
Posts: 31
Joined: December 12th, 2005, 7:28 am
Location: London
Contact:

Post by Greenwich-kid »

Sorry SirHangDangly, I realised that some of you had already worked out that it wasn't network issues, but thought a gentle reminder and a couple of simple tests would at least enable a competent reply. Without people doing the usual round of, are you sure it's not your mail server :-)
suryoyo
Posts: 60
Joined: June 9th, 2005, 2:55 pm

Post by suryoyo »

Positive it's not mail server. I have a Net Solutions email account (that I pay for) and I've set up my mail settings exactly as per their instructions.
The problem did not happen before I upgrade to my AMD x2. I thought it might have been the new windows install causing the problem and I've played with every setting imaginable to try to fix it.

The biggest proof is setting affinity, which after doing so, I get no timeout or connection errors whatsoever.

I think a lot of people are getting these errors (just search for it on the TB help forum) but haven't figured out it's TB's thread handling that's causing the problem.
Greenwich-kid
Posts: 31
Joined: December 12th, 2005, 7:28 am
Location: London
Contact:

Post by Greenwich-kid »

Now that is interesting, do you have another account you can test with? I suspect you already know this so apolagies if I'm teaching my grabdmother to suck eggs.
But in any support issue, it's really about ruleing out what the problem isn't that way you get what it is. If you can connect to your account using another client with exactly the same settings then it is safe to say it's probably TBird and your CPU slash OS that is the issue.
suryoyo
Posts: 60
Joined: June 9th, 2005, 2:55 pm

Post by suryoyo »

Greenwich-kid, I have not tried different e-mail programs, I have tried the TB Branch, Trunk, mmoy's x64 builds, all with different dates and builds. I don't feel like trying out a bunch of different programs and add them to my computer. All gave me the same errors.

I had two different accounts besides the one I mentioned to you. I had an email account with 2 different dsl ISPs (dsl extreme and SBC) and I got the same error on both of these email accounts.
Maybe you can come up with another reason for the problem.

Mmoy says that it's a TB thread handling problem maybe you know better.

What difference does it make if it's a problem with TB or the CPU when mozilla can fix it? You must be the biggest TB fanboy on the internet.
Greenwich-kid
Posts: 31
Joined: December 12th, 2005, 7:28 am
Location: London
Contact:

Post by Greenwich-kid »

Well I wasn't really wasn't expecting a flame, I was just simply trying to see if I could help, simple as that.. The deal is work out exactly what the problem is then go from there... But FYI I use many different mail clients, not just Thunderbird, as to mozilla fixing something, how can they fix something when they're not sure what the problem is, as all the information wasn't supplied in the first instance??
suryoyo
Posts: 60
Joined: June 9th, 2005, 2:55 pm

Post by suryoyo »

Not flaming you bro.

"how can they fix something when they're not sure what the problem is,"
The problem is this: TB doesn't handle threads properly on a dual core CPU.

The solution at this point is this: Set affinity for each thread instance either on taskmanager or using affinity.exe or use a program like imagecfg to modify the exe file permanently to use one core. Using imagecfg though will then not allow you to use the update feature because the original exe has been modified and future updates won't apply.

I think that's specific enough.
peskypescado
Posts: 8
Joined: December 23rd, 2003, 9:59 am

Post by peskypescado »

Finally I found this post. This should be stickied in the Thunderbird Bugs forum. I have an X2 and have to use affinity to get it to work right. Does anyone know if this happens on the Pentium D's too?
nimsje
Posts: 14
Joined: January 13th, 2006, 3:53 pm

Post by nimsje »

Same problem here. I recently bought an X2, and also got a connection timeout directly after cliking on get messages. I have multiple accounts in my tb, so maybe there could be a cause of the problem? It realy looks like a tbird problem, not handling multi-threads.
nimsje
Posts: 14
Joined: January 13th, 2006, 3:53 pm

Post by nimsje »

*Quick workaround*

I found out that if you are using windows XP and have an X2 processor the following option will make the error doesn't happen again.

Right click thunderbird.exe and choose Properties.
Choose the "Compatability"-tab and run thunderbird in compatability modus for windows 98 / me. When you have set this, you won't get any connection problems anymore :D.

NOTE: This is not a fix!!!
Post Reply