Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't install apptainer having installed ohpc-base-compute #1889

Closed
sjpb opened this issue Oct 25, 2023 · 5 comments
Closed

Can't install apptainer having installed ohpc-base-compute #1889

sjpb opened this issue Oct 25, 2023 · 5 comments

Comments

@sjpb
Copy link

sjpb commented Oct 25, 2023

I'm just trying out RL9/OHPCv3. ohpc-base-compute appears to install singularity-ce (at least when using ansible/dnf install -y) , which clashes with apptainer:

 Problem: problem with installed package singularity-ce-3.11.5-1.el9.x86_64
  - package singularity-ce-3.11.5-1.el9.x86_64 conflicts with sif-runtime provided by apptainer-1.2.4-1.el9.x86_64
  - package apptainer-1.2.4-1.el9.x86_64 conflicts with sif-runtime provided by singularity-ce-3.11.5-1.el9.x86_64

I guess the Recommends: line here is the cause though I can't find any docs for this "Recommends:" feature (and oddly it means repoquery --whatrequires singularity-ce --alldeps can't find the dependency.

Is the recommendation necessary/useful?

Clearly the singularity/apptainer clash isn't within OpenHPC's control but it'd be nice to be able to install one of them without having to uninstall the auto-installed one first.

Installing apptainer before ohpc-base-compute does work as a workaround.

@adrianreber
Copy link
Member

Thanks for the report. This is actually something we discussed a lot in the TSC.

The reason for what we have is historical. OpenHPC used to package singularity but no longer includes it. To give the users the same packages as before we use Recommends and boolean dependencies.

Our idea was that if you have one of (singularity-ce or singularity or apptainer) installed nothing should happen and if you do not have any of these packages one of the packages should be installed.

But trying to install ohpc-base-compute just now on Almalinux works for me.

dnf install ohpc-base-compute works and installs singularity-ce

dnf install ohpc-base-compute apptainer works and install apptainer.

So, not sure how you get to the error you see.

Is the recommendation necessary/useful?

I don't know. @jcsiadal was arguing against it. The main reason we have it is to provide users with the same set of packages as we did before dropping singularity and using the package from an existing repository (EPEL in this case).

@sjpb
Copy link
Author

sjpb commented Oct 25, 2023

I got the error because I do:

  1. dnf install -y ohpc-base-compute which as you say gets singularity-ce
  2. dnf install -y apptainer which fails cause of the clash. You have to uninstall singularity-ce first.

i.e. two sequential commands. So its maybe a quirk of the way our ansible is structured (for which there are reasons, but they're irrelevant here, IMO). I think your reasoning makes sense in terms of providing the least changes for most users.

@adrianreber
Copy link
Member

Ah, okay, now I get it. Okay. You could also disable recommends during installation that would avoid that.

In the end this is error in the packages in EPEL. The apptainer and singularity-ce maintainer would need to figure out a way to co-exist somehow.

@sjpb
Copy link
Author

sjpb commented Oct 25, 2023

Yes sorry I should have been clear which bit threw the error.

Turns out you can add install_weak_deps: false in ansible to avoid getting the recommendations.

@sjpb sjpb closed this as completed Oct 25, 2023
sjpb added a commit to stackhpc/ansible-role-openhpc that referenced this issue Oct 25, 2023
sjpb added a commit to stackhpc/ansible-slurm-appliance that referenced this issue Oct 25, 2023
sjpb added a commit to stackhpc/ansible-slurm-appliance that referenced this issue Oct 25, 2023
@sjpb
Copy link
Author

sjpb commented Oct 27, 2023

Turns out this also occurs when installing OpenHPC v2.6.2 now, same error re. singularity-ce-3.11.5-1.el9.x86_64. I guess singularity or apptainer upgrades have changed their sif-runtime version so now they clash. Just adding this here in case it is helpful to point anyone else to it.

sjpb added a commit to stackhpc/ansible-role-openhpc that referenced this issue Feb 2, 2024
sjpb added a commit to stackhpc/ansible-role-openhpc that referenced this issue Feb 20, 2024
* add RL9/OHPCv3 repos

* FIXME: use crb instead of powertools

* fix apptainer/singularity clash: openhpc/ohpc#1889 (comment)

* FIXME: add cgroup.conf

* FIXME: don't use outdated pgid for proctracktype

* bump CI to include RL9

* fix linter errors

* fix molecule instance creation for RL9

* bump RL8 CI image

* fix powertools/crb repos

* fix container startup

* bump GH actions version to avoid node version warning in CI

* minimise PR differences

* include cgroup.conf template from upstream

* pin molecule-podman to avoid ansible-community/molecule-plugins#242
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants