Bug 50147 - add support for merged-usr
Summary: add support for merged-usr
Status: NEW
Alias: None
Product: Docker
Classification: Virtualization
Component: Official image (show other bugs)
Version: sisyphus
Hardware: x86_64 Linux
: P5 normal
Assignee: geochip@altlinux.org
QA Contact: obirvalger@altlinux.org
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-04-24 17:58 MSK by Stanislav Levin
Modified: 2024-04-26 19:23 MSK (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stanislav Levin 2024-04-24 17:58:41 MSK
Dist upgrade fails:

```
docker run -ti alt:sisyphus bash -c 'apt-get update && apt-get dist-upgrade -y'

...

Committing changes...
filesystem-3.1-alt1: Migration is needed before the package can be installed.
error: lua script failed: [string "%pretrans(filesystem-3.1-alt1.x86_64)"]:29: Looks like usrmerge-hier-convert is not installed. Aborting.
Preparing...                            ####################################### [100%]
        file /bin from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /lib from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /lib64 from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /libx32 from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /sbin from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
E: Error while running transaction
```

Preinstallation of usrmerge-hier-convert doesn't help either:
```
docker run -ti alt:sisyphus bash -c 'apt-get update && apt-get install -y usrmerge-hier-convert && apt-get dist-upgrade -y'

...

Committing changes...
filesystem-3.1-alt1: Migration is needed before the package can be installed.
filesystem-3.1-alt1: Starting usrmerge-hier-convert...
usr-m: Conversion does not work on a union FS.
     : Your image will have to be rebuilt from a new FS tree, sorry.
     : Exiting.
error: lua script failed: [string "%pretrans(filesystem-3.1-alt1.x86_64)"]:32: exit
Preparing...                            ####################################### [100%]
        file /bin from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /lib from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /lib64 from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /libx32 from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
        file /sbin from install of filesystem-3.1-alt1.x86_64 conflicts with file from package filesystem-2.3.19-alt1.x86_64
E: Error while running transaction
```
```
Comment 1 Arseny Maslennikov 2024-04-26 18:51:17 MSK
The diagnostic is clear enough:

usr-m: Conversion does not work on a union FS.
     : Your image will have to be rebuilt from a new FS tree, sorry.
     : Exiting.

hier-convert is unable to fix all the non-top overlayfs layers from inside the container.

Image-based systems are easiest to maintain in a top-down fashion: instead of upgrading packages inside the image and having the layer stack consume additional space, the base image is (hopefully reproducibly) regenerated on top of a repository snapshot. It's easiest to regenerate the image with filesystem 3 from the start and tag it as alt:sisyphus in the registry.
Comment 2 Stanislav Levin 2024-04-26 19:23:07 MSK
This is what I expect to be done...