Installs of service should not attempt to clear prefetch as indicated in maintenanceservice-install.log

VERIFIED FIXED in mozilla15

Status

()

Core
Widget: Win32
VERIFIED FIXED
5 years ago
5 years ago

People

(Reporter: jsmith, Assigned: bbondy)

Tracking

15 Branch
mozilla15
x86_64
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [qa!])

Attachments

(1 attachment)

(Reporter)

Description

5 years ago
Steps:

1. Install the 5/23 Elm Build without the maintenance service previously installed, with a nightly build already installed, with pref set
2. Complete the installation but do not launch the browser
3. Check the maintenance log

Expected:

I'd expect to see no errors in relation to the prefetch service.

Actual:

The prefetch clear service happened on install (thought originally it was supposed to be on launch?). The PF files it targeted were not read only and greater than 0 KB. Log messages in maintenanceservice-install:

Clearing prefetch files...
Error replacing prefetch path FIREFOX.EXE-0196A814.pf (5)
Error replacing prefetch path FIREFOX.EXE-28641590.pf (5)
Done searching prefetch paths. (18)
(Reporter)

Updated

5 years ago
Blocks: 692255
(Reporter)

Comment 1

5 years ago
Also happens with the 5/18 elm build.
(Reporter)

Updated

5 years ago
Summary: Installing Elm Build 5/23 Starts prefetch service, but fails to clear the prefetch files (even though they already exist) → Installing Elm Build Starts prefetch service, but fails to clear the prefetch files (even though they already exist)
(Reporter)

Comment 2

5 years ago
Also occurs with the most recent elm build during an update from 5/18 --> 5/24.
(Assignee)

Comment 3

5 years ago
This has no harmful effects but ya I'll provide a patch for only doing this on updates of the service.  The prefetch files would normally not be generated at the point you see in the log.  

Nice find :)

Maybe the access denied errors are because the install doesn't run as the system account in that case.
(Reporter)

Comment 4

5 years ago
Additional Notes:

I cleared the pref and launched firefox. The prefetch service isn't even running (been waiting for it to run for 6 minutes right now).
(Reporter)

Comment 5

5 years ago
(In reply to Jason Smith [:jsmith] from comment #4)
> Additional Notes:
> 
> I cleared the pref and launched firefox. The prefetch service isn't even
> running (been waiting for it to run for 6 minutes right now).

Oh wait, it finally ran. But that took a while...
(Assignee)

Comment 6

5 years ago
The log message pasted in Comment 0 is from maintenanceservice-install.log right? (and not maintenanceservice.log)
(Assignee)

Comment 7

5 years ago
oh ya sorry, I'm telling you one minute but this changed to 3 minutes recently.
(Assignee)

Comment 8

5 years ago
> Oh wait, it finally ran. But that took a while...

.pf files are 0 bytes and read only right?
(Reporter)

Comment 9

5 years ago
(In reply to Brian R. Bondy [:bbondy] from comment #8)
> > Oh wait, it finally ran. But that took a while...
> 
> .pf files are 0 bytes and read only right?

Yes

(In reply to Brian R. Bondy [:bbondy] from comment #6)
> The log message pasted in Comment 0 is from maintenanceservice-install.log
> right? (and not maintenanceservice.log)

Yes
(Reporter)

Comment 10

5 years ago
(In reply to Brian R. Bondy [:bbondy] from comment #3)
> Maybe the access denied errors are because the install doesn't run as the
> system account in that case.

That's probably it. The machine I'm on (Windows XP) does not allow deletion of the PF files from the prefetch folder - likely a permissions issue with the account.
(Assignee)

Comment 11

5 years ago
OK glad to know the system account running this helps some situations. Could you confirm that upgrades do clear the pf files on that same machine?

I think installs would run as the admin account you're logged in with and upgrades I think would run as the system account so should clear them.
(Assignee)

Comment 12

5 years ago
I just confirmed my XP machine also can't delete the prefetch files when I try manually in explorer. I haven't tested with the service though, but per your previous comments I think this works.
(Reporter)

Comment 13

5 years ago
(In reply to Brian R. Bondy [:bbondy] from comment #11)
> OK glad to know the system account running this helps some situations. Could
> you confirm that upgrades do clear the pf files on that same machine?

That doesn't work for me. If I update from 5/23 to 5/24 on Win XP, I get the same error produced in this bug with the pref set. Note that I did uninstall the service before installing the 5/23 build.

Does updating from 5/23 --> 5/24 with an elm build having the pref set work for you? My maintenance-install log always is throwing the same error on each update.
(Assignee)

Comment 14

5 years ago
I know why, because Windows XP doesn't use the service for installs by default so the operation wouldn't run as system account in that case.   The one time clear would use the system account though.
(Reporter)

Comment 15

5 years ago
(In reply to Brian R. Bondy [:bbondy] from comment #14)
> I know why, because Windows XP doesn't use the service for installs by
> default so the operation wouldn't run as system account in that case.   The
> one time clear would use the system account though.

A little confused. So this explains why updating isn't working on Win XP? Or am I missing something to understanding this?
(Assignee)

Comment 16

5 years ago
So on Windows XP you can't clear prefetch using the admin account at all. Something I just realized from your findings.

The service command that runs after 3 minutes runs as the system account. Because it issues a command directly to the service.

The code to clear the prefetch that runs on update though on XP doesn't use the service, and so it doesn't use the system account.
(Assignee)

Comment 17

5 years ago
I'll post to fix upgrades on XP in a new bug, but it doesn't need to be fixed until after v15.  In particular it would have to be fixed before v16->v17 since that's the first time this code would be hit.
(Reporter)

Comment 18

5 years ago
(In reply to Brian R. Bondy [:bbondy] from comment #17)
> I'll post to fix upgrades on XP in a new bug, but it doesn't need to be
> fixed until after v15.  In particular it would have to be fixed before
> v16->v17 since that's the first time this code would be hit.

Could you clarify why? Did a pre-req feature for this get moved to a different firefox release?
(Assignee)

Comment 19

5 years ago
The code for the one time run after 3 minutes runs right away, but the code for the update should only run on the next update after this is installed.  For m-c that would be 16-17 and for Aurora that would be 15-16.  So as long as this lands on m-c in 16 then it's fine.
(Assignee)

Updated

5 years ago
Summary: Installing Elm Build Starts prefetch service, but fails to clear the prefetch files (even though they already exist) → Installs of service should not attempt to clear prefetch as indicated in maintenanceservice-install.log
(Assignee)

Comment 20

5 years ago
Re comment 19 and some comments before that, bug 758463 was posted for that.

This bug is being used for the problem confirmed in Comment 3, that an initial install should not attempt to clear prefetch, only updates and the one time only clear after 3 minutes.
(Assignee)

Updated

5 years ago
Assignee: nobody → netzen
(Assignee)

Comment 21

5 years ago
Created attachment 627058 [details] [diff] [review]
Patch v1.

A quick one, we should not try to clear prefetch from installs since we do it already from the one time pref.
Attachment #627058 - Flags: review?(robert.bugzilla)
Attachment #627058 - Flags: review?(robert.bugzilla) → review+
(Assignee)

Comment 22

5 years ago
http://hg.mozilla.org/mozilla-central/rev/fb61360eab85
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla15
(Reporter)

Updated

5 years ago
Whiteboard: [qa+]
(Reporter)

Updated

5 years ago
Status: RESOLVED → VERIFIED
Whiteboard: [qa+] → [qa!]
You need to log in before you can comment on or make changes to this bug.