Closed Bug 458827 Opened 16 years ago Closed 14 years ago

Hang if my IP changes after sleep (Disable of IDLE command use is a workaround)

Categories

(Core :: Networking, defect)

1.9.0 Branch
x86
Windows Vista
defect
Not set
critical

Tracking

()

RESOLVED INCOMPLETE

People

(Reporter: rahsredback, Unassigned)

References

Details

(Keywords: hang, Whiteboard: [closeme 2010-02-01])

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.0.3) Gecko/2008092417 Firefox/3.0.3 (.NET CLR 3.5.30729)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.0.3) Gecko/2008092417 Firefox/3.0.3 (.NET CLR 3.5.30729)

When Vista wakes up from sleep it sometimes gets a different IP address than it had before.
If Firefox was alive before the sleep (smart sleep) and the IP changes then when I try to go to the web firefox just waits forever.   I suppose it is not precisely a hang because I can stop and go to other URLs but they all jus tsit there trying to loads forever.
One more problem with this is that after this has happened I quit firefox but the process does not die.  It sits there using up a whole CPU until I force kill the process.

THis has happened since Firefox 2 but it has taken me this long to figure out exactly what causes the problem.  I have neve rseen this problem on XP, but then XP always gets the SAME IP address after it wakes up.  (I think there is something wrong with the way Vista requests a dchp refresh, but that is another issue.)  THe problem here is that firefox is not robust in the face of an IP address change.


Reproducible: Always

Steps to Reproduce:
1. Run firefox.  Visit a web page, prefereably one that has some live update (like Yahoo finance live update stock quotes), but I'm not sure this is required.
2. Get Vista to go to sleep
3. Make sure VIsta gave up its IP address to another system on the router.
4. Wake up VIsta -- now it has to get a different IP address.  THis is probably dependent on the router you are using.
5. Try to get firefox to go to a different url 
6.  It should just sit there downloading.
7.  Try to quit firefox from the file menu.
8.  You will probably see a firefox process still running.

Actual Results:  
As described above

Expected Results:  
FIrefox should just go to the new url and not mind that the ip address has changed.
And certainly when firefox quits it should termiate its process instead of leaving it spinning.
Possibly the same issue as bug 178296.
Component: General → Networking
Depends on: 178296
Product: Firefox → Core
QA Contact: general → networking
I can confirm the same behavior, but in latest Thunderbird trunk builds.
My IP changes frequently because I change from using university provided wireless, and privately provided wireless, and vice versa.
It happens much more frequently in Thunderbird than Firefox, because Thunderbird  checks email on regular intervals. After sleeping for some period of time, the client attempts to check for new emails on resume, but the IP changes almost simultaneously (since I have changed locations), leaving Thunderbird to chew up the CPU, even after closing the main display client. 
Thunderbird should fail to connect to the email server because the network route has changed, or, better solution, delay the automatic email check, either by not using system time and being relative to client active time, or just delaying after OS calls resume (does Vista even do that?)
(a) Bug 444071 is a report on issue relates to IP address change by DHCP. See also bugs pointed in it. In this case, following is effective recover action.
> File->Work Offline => File->Work Offline(remove tick)
(b) Bug 444056 is a report of another kind of issue around suspend/resume. See also bugs pointed in it. In this case, restart seems to be required. However, termination doesn' seem to complete. So kill of Fx/Tb process seems to be required.

Is "work-offline => work-online again" an effective recovery procedure?

(In reply to comment #0)
> 7.  Try to quit firefox from the file menu.
> 8.  You will probably see a firefox process still running.

Above type (b) issue sounds to be involved in your case. Please check status with "netstat -b -o" upon resume.
It doesn't seem to happen anymore in latest nightlies.
For the record, I was running x64 vista.
Came up again in the next nightly.

I also discovered that this will also cause the thinkpad power manager gauge to stop updating.
Another note, it seems to happen whenever there's an IP change now, rather than after sleep.

Not related to 444071, because tb hangs.

FWIW, it doesn't happen with firefox. At least, not while it's idling, unlike thunderbird. But maybe it's because tb keeps the connection open. I've yet to remember to do netstat when it hangs.
(In reply to comment #4)
> For the record, I was running x64 vista.
(In reply to comment #6)
> Not related to 444071, because tb hangs.

I saw some bug reports for network related problems on 64 bit MS Win. Search for such bugs via "Advanced Search", please.

(In reply to comment #6)
> it doesn't happen with firefox. At least, not while it's idling, unlike thunderbird.
> But maybe it's because tb keeps the connection open.

"keeping connection open" is applicable to IMAP with IDLE support=enabled only. (may be applicable NNTP too).
How about POP3 access/SMTP access/News access by Tb after IP address change?
When problem occurs, can "disable IDLE support of IMAP" be a workaround?
If not, please try "use Tb with disabling IDLE support" if possible. Will problem be reproduced by PC's IP address change?
Looks good. Disabling idle in about:config stopped tb from hanging on IP change. No problems with the power manager gauge, either.
Should use_idle be enabled by default then, I wonder?
L.S. still seeing this?
Severity: normal → critical
Keywords: hang
Whiteboard: [closeme 2010-02-01]
Summary: Hang if my IP changes after sleep → Hang if my IP changes after sleep (Disable of IDLE command use is a workaround)
(In reply to comment #8)
> Should use_idle be enabled by default then, I wonder?

Check next with use_idle enabled, please.
  PC's IP address change while IDLE is active => hang
  => check TCP connenetion status by "netstat"  
  => Work offline. Does "Work offline" work?
  => If worked, Work online again. Problem is resolved?
Closing per whiteboard closeme date. 

Please reopen/comment with further info, if you still see this issue with Firefox 3.6.13 or later in safe mode:
http://support.mozilla.com/kb/Safe+Mode

If you wish, you can also try to reproduce in Firefox 4 Beta 8 or later, since significant improvements have been made since 3.6.x:
http://www.mozilla.com/en-US/firefox/all-beta.html
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → INCOMPLETE
Version: unspecified → 1.9.0 Branch
You need to log in before you can comment on or make changes to this bug.