Bug 1777262 - Lmod upgrade to version 8.2
Summary: Lmod upgrade to version 8.2
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: Lmod
Version: epel7
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: ---
Assignee: Orion Poplawski
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-11-27 10:07 UTC by Ole Holm Nielsen
Modified: 2020-01-21 03:44 UTC (History)
2 users (show)

Fixed In Version: Lmod-8.2.7-1.el7 Lmod-8.2.7-1.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-12-16 00:26:23 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Ole Holm Nielsen 2019-11-27 10:07:00 UTC
Description of problem:
Lmod version 8.2 contains important functionality enhancements and bug fixes as described in https://github.com/TACC/Lmod, notably the handling of extensions in Python which is really useful, plus several other enhancements.

Version-Release number of selected component (if applicable):
7.8.16

How reproducible:
Always


Steps to Reproduce:
1.
2.
3.

Actual results:

$ rpm -q Lmod
Lmod-7.8.16-1.el7.x86_64

Expected results:
The latest Lmod version 8.2 is desired.


Additional info:

Comment 1 Fedora Update System 2019-11-30 19:00:03 UTC
FEDORA-EPEL-2019-a9d9438057 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2019-a9d9438057

Comment 2 Fedora Update System 2019-11-30 19:00:04 UTC
FEDORA-EPEL-2019-0e8265d69c has been submitted as an update to Fedora EPEL 8. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2019-0e8265d69c

Comment 3 Fedora Update System 2019-12-01 00:07:48 UTC
Lmod-8.2.7-1.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2019-a9d9438057

Comment 4 Fedora Update System 2019-12-01 01:38:50 UTC
Lmod-8.2.7-1.el8 has been pushed to the Fedora EPEL 8 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2019-0e8265d69c

Comment 5 Fedora Update System 2019-12-16 00:26:23 UTC
Lmod-8.2.7-1.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.

Comment 6 Fedora Update System 2019-12-16 01:22:03 UTC
Lmod-8.2.7-1.el8 has been pushed to the Fedora EPEL 8 stable repository. If problems still persist, please make note of it in this bug report.

Comment 7 Ole Holm Nielsen 2020-01-14 09:59:41 UTC
The CentOS 8 package Lmod-8.2.7-1.el8.x86_64 seems to require non-existent Lua packages:

$ dnf install Lmod
Last metadata expiration check: 0:08:35 ago on Tue 14 Jan 2020 10:47:14 AM CET.
Error: 
 Problem: conflicting requests
  - nothing provides lua-filesystem needed by Lmod-8.2.7-1.el8.x86_64
  - nothing provides lua-posix needed by Lmod-8.2.7-1.el8.x86_64

$ dnf install lua-filesystem lua-posix
Last metadata expiration check: 0:10:46 ago on Tue 14 Jan 2020 10:47:14 AM CET.
No match for argument: lua-filesystem
No match for argument: lua-posix
Error: Unable to find a match

So unfortunately we cannot install Lmod on CentOS at present.

Comment 8 Orion Poplawski 2020-01-14 15:55:15 UTC
Those are in the PowerTools repo as mentioned here: https://fedoraproject.org/wiki/EPEL#Quickstart

Comment 9 Ole Holm Nielsen 2020-01-15 11:46:01 UTC
Thanks a lot, this command enables PowerTools repo so we can install Lmod and its dependencies:

   # dnf config-manager --set-enabled PowerTools
   # dnf install Lmod

I have a problem enabling the PowerTools repo within an Ansible role, though.  At present there is no Ansible module for running "dnf config-manager" commands, see https://github.com/ansible/ansible/issues/46963.
It seems that we need a dnf_repository module similar to the yum_repository Ansible module, but this doesn't exist yet :-(

As a workaround my Ansible role uses these tasks:

- name: Enable the EPEL PowerTools repository
  shell: "dnf config-manager --set-enabled PowerTools"
- name: Install Lmod
  dnf:
    name:
    - Lmod

Does anyone know a better way with Ansible?

Comment 10 Ole Holm Nielsen 2020-01-15 12:05:10 UTC
After installing Lmod successfully, there are unfortunately two problems with the files installed in /etc/profile.d/.
The Lmod package clobbers the previously installed /etc/profile.d/modules.*sh files:

# rpm -ql environment-modules | grep /etc/profile.d
/etc/profile.d/modules.csh
/etc/profile.d/modules.sh

# rpm -ql Lmod | grep /etc/profile.d
/etc/profile.d/00-modulepath.csh
/etc/profile.d/00-modulepath.sh
/etc/profile.d/modules.csh
/etc/profile.d/modules.sh

The Lmod RPM installs these soft-links to non-existent files in /etc/alternatives:

# ls -l /etc/profile.d/modules.*
lrwxrwxrwx. 1 root root 29 Jan 15 13:00 /etc/profile.d/modules.csh -> /etc/alternatives/modules.csh
lrwxrwxrwx. 1 root root 28 Jan 15 13:00 /etc/profile.d/modules.sh -> /etc/alternatives/modules.sh

How do we solve this conflict?  Probably Lmod should not install the links /etc/profile.d/modules.* ?

A second problem is that the /etc/profile.d/z00_lmod.*sh files are missing from the CentOS8 RPM install compared to CentOS7:

centos7# rpm -ql Lmod | grep /etc/profile.d
/etc/profile.d/00-modulepath.csh
/etc/profile.d/00-modulepath.sh
/etc/profile.d/z00_lmod.csh
/etc/profile.d/z00_lmod.sh

Lmod won't work unless the /etc/profile.d/z00_lmod.*sh files are installed :-(

Thanks for any help,
Ole

Comment 11 Orion Poplawski 2020-01-20 03:54:52 UTC
Ole - I cannot reproduce your problem.  With EL8, environment-modules and Lmod both make use of alternatives to allow you to switch between the two different implementations. /etc/alternatives/modules.{csh,sh} should indeed exist:

# ls -l /etc/alternatives/module*
lrwxrwxrwx. 1 root root 33 Jan 19 22:47 /etc/alternatives/module.1.gz -> /usr/share/man/man1/module-c.1.gz
lrwxrwxrwx. 1 root root 40 Jan 19 22:47 /etc/alternatives/modulecmd -> /usr/share/Modules/libexec/modulecmd.tcl
lrwxrwxrwx. 1 root root 37 Jan 19 22:47 /etc/alternatives/modulefile.4.gz -> /usr/share/man/man4/modulefile-c.4.gz
lrwxrwxrwx. 1 root root 35 Jan 19 22:47 /etc/alternatives/modules.csh -> /usr/share/Modules/init/profile.csh
lrwxrwxrwx. 1 root root 34 Jan 19 22:47 /etc/alternatives/modules.sh -> /usr/share/Modules/init/profile.sh

And both environment-modules and Lmod will create those links if needed.  By default the environment-modules implementation has preference.  To make Lmod the active implementation either uninstall environment-modules or do:

alternatives --config modules.sh

and select lmod.

This is with:

environment-modules-4.1.4-4.el8.x86_64
Lmod-8.2.7-1.el8.x86_64

Comment 12 Ole Holm Nielsen 2020-01-20 08:06:40 UTC
Hi Orion, thanks for the info.  

I removed both RPMs environment-modules Lmod and reinstalled them and now I agree with your results for /etc/profile.d/modules.*
The new approach with "alternatives" got me confused.

My choice will be to remove environment-modules and keep my favorite Lmod RPM.  However, I do get some problems when uninstalling:

# dnf remove environment-modules 
Modular dependency problems:

 Problem 1: conflicting requests
  - nothing provides module(perl:5.26) needed by module perl-DBD-MySQL:4.046:8010020191114030811:073fa5fe-0.x86_64
 Problem 2: conflicting requests
  - nothing provides module(perl:5.26) needed by module perl-DBD-SQLite:1.58:8010020191114033549:073fa5fe-0.x86_64
 Problem 3: conflicting requests
  - nothing provides module(perl:5.26) needed by module perl-DBI:1.641:8010020191113222731:16b3ab4d-0.x86_64
 Problem 4: conflicting requests
  - nothing provides module(perl:5.26) needed by module perl-YAML:1.24:8010020191114031501:a5949e2e-0.x86_64
Dependencies resolved.

I do not understand if these problems are fatal or just informational - can you determine this?

FYI: My system runs CentOS 8.1 (fully updated).

Comment 13 Orion Poplawski 2020-01-21 03:44:54 UTC
That's a really weird error as it doesn't seem to have anything to do with environment-modules.  Try adding --noautoremove to the dnf remove command.  If that doesn't work you'll need to seek help from the centos community.


Note You need to log in before you can comment on or make changes to this bug.