Closed Bug 1835022 Opened 2 years ago Closed 2 years ago

Create a new ESR migration MAR based on current Firefox

Categories

(Release Engineering :: General, enhancement)

enhancement

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mkaply, Assigned: gbrown)

References

(Blocks 1 open bug)

Details

Attachments

(5 files, 5 obsolete files)

We have MAR files for migrating users to ESR

https://archive.mozilla.org/pub/firefox/releases/custom-updates/

These are used when we deprecated operating systems and other things.

Unfortunately they use an old MAR signature so they no longer work

With 115 ESR coming up and the possible need for migration, it's probably useful to revisit these MARs and create new ones with the new signature.

We've had some enterprises in particular that would love an easy way to migrate from release to ESR.

Marking bug as confidential until the official communication is published.

Group: mozilla-employee-confidential
Blocks: win7-eol
Group: mozilla-employee-confidential
Attached file switch-to-esr115.mar (obsolete) —

A first pass at creating a new channel switching mar. I ran create-channel-switch-mar.py --version 115.0 --channel esr --accepted-channel-id firefox-mozilla-esr --mar-channel-id firefox-mozilla-release --output switch-to-esr115.mar, using create-channel-switch-mar.py unmodified from bug 1778996.

+ mar -T ../switch-to-esr115.mar
Signature block found with 0 signatures
1 additional block found:
  - Product Information Block:
    - MAR channel name: firefox-mozilla-release
    - Product version: 115.0

SIZE	MODE	NAME
272	0664	defaults/pref/channel-prefs.js
176	0664	update-settings.ini
272	0664	Contents/Resources/defaults/pref/channel-prefs.js
176	0664	updatev3.manifest
176	0664	Contents/Resources/update-settings.ini
+ mar -x ../switch-to-esr115.mar
+ xz -c -d updatev3.manifest
type "partial"
add-if "defaults/pref/channel-prefs.js" "defaults/pref/channel-prefs.js"
add-if "Contents/Resources/defaults/pref/channel-prefs.js" "Contents/Resources/defaults/pref/channel-prefs.js"
add-if "update-settings.ini" "update-settings.ini"
add-if "Contents/Resources/update-settings.ini" "Contents/Resources/update-settings.ini"
+ xz -c -d update-settings.ini
; If you modify this file updates may fail.
; Do not modify this file.

[Settings]
ACCEPTED_MAR_CHANNEL_IDS=firefox-mozilla-esr
+ xz -c -d defaults/pref/channel-prefs.js
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

pref("app.update.channel", "esr");

Still requires signing, of course.

:jcristau - Am I on the right path?

Flags: needinfo?(jcristau)
Assignee: nobody → gbrown

Looks good to me!

Flags: needinfo?(jcristau)
Attachment #9336902 - Attachment description: WIP switch-to-esr115.mar → switch-to-esr115.mar

I thought we did a distribution.ini for a release to do tracking, but we never did it in a MAR.

Does anyone know how we did that?

Blocks: 1836375

Do we have opinions/requirements for the distribution ID? switch-to-esr78.0-eol-mac.mar used distribution ID mozilla-mac-eol-esr1. How about mozilla-eol-esr115 this time?

Attachment #9336902 - Attachment is obsolete: true
Attachment #9337777 - Attachment is obsolete: true
Attached file switch-to-esr115.mar (obsolete) —

A new channel switching mar, now with distribution-id. I ran create-channel-switch-mar.py --version 115.0 --channel esr --accepted-channel-id firefox-mozilla-esr --mar-channel-id firefox-mozilla-release --distribution-id mozilla-eol-esr115 --output switch-to-esr115.mar.

$ mar -T switch-to-esr115.mar
Signature block found with 0 signatures
1 additional block found:
  - Product Information Block:
    - MAR channel name: firefox-mozilla-release
    - Product version: 115.0

SIZE	MODE	NAME
184	0664	Contents/Resources/distribution/distribution.ini
184	0664	distribution/distribution.ini
272	0664	defaults/pref/channel-prefs.js
176	0664	update-settings.ini
272	0664	Contents/Resources/defaults/pref/channel-prefs.js
204	0664	updatev3.manifest
176	0664	Contents/Resources/update-settings.ini
$ xz -c -d distribution/distribution.ini
# Partner Distribution Configuration File
# Author: Mozilla
# Date: 2023-06-06

[Global]
id=mozilla-eol-esr115
version=1.0

So before we made the distro IDs platform specific just because it made the telemetry easier.

How much of a pain would it be to create multiple mars and serve different ones to windows/mac? (Side note, it would be nice to have one without distirbution.ini as well because we have enterprise folks that want to move some release folks to ESR)

I can do that.

To verify, we want 3 mar files:

  1. no distribution ID
  2. distribution ID mozilla-mac-eol-esr115
  3. distribution ID mozilla-win-eol-esr115

How does that sound?

Flags: needinfo?(mozilla)

That sounds perfect. Thanks.

Flags: needinfo?(mozilla)
Attachment #9337778 - Attachment is obsolete: true
Attached file switch-to-esr115.0.mar

No distribution id: create-channel-switch-mar.py --version 115.0 --channel esr --accepted-channel-id firefox-mozilla-esr --mar-channel-id firefox-mozilla-release --output switch-to-esr115.0.mar

Attached file switch-to-esr115.0-eol-mac.mar (obsolete) —

Distribution id mozilla-mac-eol-esr115: create-channel-switch-mar.py --version 115.0 --channel esr --accepted-channel-id firefox-mozilla-esr --mar-channel-id firefox-mozilla-release --distribution-id mozilla-mac-eol-esr115 --output switch-to-esr115.0-eol-mac.mar

Attached file switch-to-esr115.0-eol-win.mar (obsolete) —

Distribution id mozilla-win-eol-esr115: create-channel-switch-mar.py --version 115.0 --channel esr --accepted-channel-id firefox-mozilla-esr --mar-channel-id firefox-mozilla-release --distribution-id mozilla-win-eol-esr115 --output switch-to-esr115.0-eol-win.mar

The ESR upgrade part is working (verified that the channel is ESR in channel-prefs.js).

The distribution.ini part isn't working for me. Should it work if there is already a distribution directory?

I don't see the distribution.ini part in the update:

2023-06-13 11:13:40-0400: PATCH DIRECTORY C:\ProgramData\Mozilla-1de4eec8-1241-4177-a864-e594e8d1fb38\updates\6A9C760FBB55CADF\updates\0
2023-06-13 11:13:40-0400: INSTALLATION DIRECTORY C:\Users\mike\Projects\firefox\core
2023-06-13 11:13:40-0400: WORKING DIRECTORY C:\Users\mike\Projects\firefox\core
2023-06-13 11:13:40-0400: UPDATE TYPE partial
2023-06-13 11:13:40-0400: PREPARE ADD defaults/pref/channel-prefs.js
2023-06-13 11:13:40-0400: PREPARE ADD update-settings.ini
2023-06-13 11:13:40-0400: EXECUTE ADD defaults/pref/channel-prefs.js
2023-06-13 11:13:40-0400: EXECUTE ADD update-settings.ini
2023-06-13 11:13:40-0400: FINISH ADD defaults/pref/channel-prefs.js
2023-06-13 11:13:40-0400: FINISH ADD update-settings.ini
2023-06-13 11:13:40-0400: succeeded
2023-06-13 11:13:40-0400: calling QuitProgressUI

I was definitely using the Windows EOL mar.

Is there an easy way to unpack the MAR locally?

mar -x <mar-file>
xz -d -c <extracted-file>

I pulled mar from https://archive.mozilla.org/pub/firefox/candidates/114.0b9-candidates/build1/mar-tools

I think jcristau has found the problem....we'll need new mar files.

The distribution.ini files are in the mar file, but (I think) they are not being installed because of the manifest. Most files, like channel-prefs.js, are installed on the condition that they already exist. We can't do that for distribution.ini, but we also don't want to be unconditional, since the mar contains both distribution/distribution.ini and Contents/Resources/distribution/distribution.ini.

switch-to-esr78.0-eol-mac.mar used this technique:

add-if "platform.ini" "distribution/distribution.ini"  
add-if "Contents/Resources/platform.ini" "Contents/Resources/distribution/distribution.ini"

Let's try that...

Attachment #9337892 - Attachment is obsolete: true
Attachment #9337893 - Attachment is obsolete: true

Distribution id mozilla-mac-eol-esr115: create-channel-switch-mar.py --version 115.0 --channel esr --accepted-channel-id firefox-mozilla-esr --mar-channel-id firefox-mozilla-release --distribution-id mozilla-mac-eol-esr115 --output switch-to-esr115.0-eol-mac.mar .... with new manifest: https://hg.mozilla.org/build/braindump/annotate/ad1816024223f218b7ab86785b634744c16a197c/update-related/create-channel-switch-mar.py

Distribution id mozilla-win-eol-esr115: create-channel-switch-mar.py --version 115.0 --channel esr --accepted-channel-id firefox-mozilla-esr --mar-channel-id firefox-mozilla-release --distribution-id mozilla-win-eol-esr115 --output switch-to-esr115.0-eol-win.mar ... now with new manifest

I verified that on Windows, the distribution.ini got laid down and the channel prefs was changed.

We won't really be able to do full verification until we have an ESR build, since the way it will work is the user will get two updates, one to switch to the ESR and one that has the esr update.

Are we going to put these MAR files here?

https://archive.mozilla.org/pub/firefox/releases/custom-updates/

(In reply to Mike Kaply [:mkaply] from comment #27)

Thanks for checking these over.

Are we going to put these MAR files here?

https://archive.mozilla.org/pub/firefox/releases/custom-updates/

Yes, that's what I intend. I thought we'd copy them over around the time of the 115 release, unless there's a use for them before that?

The non distribution one might be a good one to have up early. I'm going to put together some instructions for enterprises that want to migrate to the ESR from 114 release.

Depends on: 1839195
Depends on: 1839900
Depends on: 1880713
No longer depends on: 1880713
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: