AlmaLinux 9 - modifying your analysis scripts
This is a brief guide to modifying your analysis scripts when you switch to AlmaLinux 9. For more details, see the
conda topic.
Conda is already there.
Conda has been installed on all the systems of the Nevis
Linux cluster. You don't need to install your own copy of anaconda or miniconda.
Get rid of module load root
The command
module load root
won't work under AlmaLinux 9. (You won't get an error message, but the command won't do anything.) Remove it from your scripts.
Instead of
module load root
:
- Try just removing it and see if your scripts still work. ROOT has been installed on all the systems of the Nevis Linux cluster.
- If the
python
or pip
commands don't work (they refer to Python 2 in CentOS 7), try python3
or pip3
instead.
- If there's some aspect of ROOT or Python that still doesn't work, try replacing
module load root
with:
conda activate /usr/nevis/conda/root
There's more on this in the
conda topic. There's also a
why conda topic if you'd like to know why
WilliamSeligman is proposing this change.
For Geant4, switch to conda
If you were using something like
module load geant4
, change it to:
conda activate /usr/nevis/conda/geant4
This includes ROOT. Do
not try:
conda activate /usr/nevis/conda/root
conda activate /usr/nevis/conda/geant4
Conda does not "stack" in this way.
Don't use /usr/nevis/el7
in any scripts.
If any line in your script refers to
/usr/nevis/el7
, remove it. Also remove any other lines that indirectly refer to it.
For example, remove something like this:
export ROOTSYS=/usr/nevis/el7/root-6.24.00
export PATH=$PATH:$ROOTSYS/bin
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ROOTSYS/bin
export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:$ROOTSYS/bin
Using /usr/nevis/el7
directly was always a mistake under any circumstances. Get it rid of it now. It will cause your job to crash in AlmaLinux 9.
Conda will work in both CentOS 7 and AlmaLinux 9
A conda environment that worked in CentOS 7 will still work in AlmaLinux 9. For that reason and others, I strongly recommend becoming familiar with
conda.
This will give you control over which packages and with which versions are available to you.
Do not save your conda environments in your home directory.
With the switch to AlmaLinux 9, more users will create conda environments. This takes up a lot of room. If everyone leaves them in their home directories (the default), the login servers will run out of disk space.
The
hidden packages topic shows how to move conda (and pip, and keras) packages and files to a file server that has more disk space.
(While you're thinking about
disk space, also consider moving your work and output files to your file servers. Storing bulky files in your home directory is not a good idea.)
Conda is slow on AlmaLinux 9
The
conda create
and
conda install
commands are glacially slow in AlmaLinux 9; they can take
days to execute! To speed this up, switch the solver for your Nevis Linux account with:
conda config --set solver libmamba
This command will only work in AlmaLinux 9. Once configured, you'll get an error message if you try to create/install environments via a CentOS 7 machine.
(A
conda create
command that I tried took two days to resolve before I set my solver to libmamba. After I set my
solver
to libmamba, it took about 30 minutes.)
--
William Seligman - 2023-11-28