Page 1 of 1

mlnscript for Rocky Linux/OpenBLAS

Posted: Mon Jan 31, 2022 4:58 pm
by aclarke2022
Does anyone have any tips on how to get mlnscript running on Rocky Linux?

I don't have admin access to the computer I'm running it on, so I'm installing the downloaded .rpm via cpio. I've tried using the CentOS and Fedora installs but when running mlnscript, it are looking for libblas.so.3 and liblapack.so.3 which do not exist. (OpenBLAS is installed, however.)

Any ideas? Or is there any chance of a Rocky Linux package being built?

Re: mlnscript for Rocky Linux/OpenBLAS

Posted: Tue Feb 01, 2022 1:06 pm
by ChrisCharlton
I have added a package version for Rocky Linux 8, which can be requested from https://www.cmm.bristol.ac.uk/clients/softwaredownload/. Note however that this will still need the libblas.so.3 and liblapack.so.3 files to be present in order to run:

Code: Select all

ldd /usr/bin/mlnscript 
	linux-vdso.so.1 (0x00007ffdc91b7000)
	libmln.so => /lib64/libmln.so (0x00007ff9aef7a000)
	libblas.so.3 => /lib64/libblas.so.3 (0x00007ff9aed26000)
	liblapack.so.3 => /lib64/liblapack.so.3 (0x00007ff9ae487000)
	libz.so.1 => /lib64/libz.so.1 (0x00007ff9ae270000)
	libdl.so.2 => /lib64/libdl.so.2 (0x00007ff9ae06c000)
	libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007ff9adcd7000)
	libm.so.6 => /lib64/libm.so.6 (0x00007ff9ad955000)
	libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007ff9ad73d000)
	libc.so.6 => /lib64/libc.so.6 (0x00007ff9ad378000)
	libgfortran.so.5 => /lib64/libgfortran.so.5 (0x00007ff9acef9000)
	/lib64/ld-linux-x86-64.so.2 (0x00007ff9af4b8000)
	libquadmath.so.0 => /lib64/libquadmath.so.0 (0x00007ff9accb8000)

Re: mlnscript for Rocky Linux/OpenBLAS

Posted: Tue Feb 01, 2022 4:32 pm
by ChrisCharlton
You could try using LD_PRELOAD to switch to OpenBLAS as described in Is it possible to switch between BLAS libraries without recompiling program?, i.e.

Code: Select all

LD_PRELOAD=/usr/lib64/libopenblas.so.0 mlnscript --run script.mac
I have not tested how well this works however.

Re: mlnscript for Rocky Linux/OpenBLAS

Posted: Mon Feb 07, 2022 1:00 pm
by aclarke2022
Thanks so much for getting back to me and creating the new package so quickly! Afraid I've only just seen your replies today so apologies not to reply sooner.

The new package seems to solve my issues! LD_PRELOAD didn't do the trick for me but I did as other answers on that SO post suggested and created symlinks for libblas.so.3 and liblapack.so.3 pointing to the OpenBLAS binaries, and that seemed to do the trick. (I'd tried something similar with the other packages but hadn't got anywhere.)

Thanks once again.

Re: mlnscript for Rocky Linux/OpenBLAS

Posted: Wed Feb 09, 2022 3:48 pm
by ChrisCharlton
Thank you for the update, it's useful to know that this method works in this situation.

Re: mlnscript for Rocky Linux/OpenBLAS

Posted: Tue Jun 27, 2023 1:39 am
by Miranda34
ChrisCharlton wrote: Tue Feb 01, 2022 4:32 pm You could try using LD_PRELOAD to switch to OpenBLAS as described in Is it possible to switch between BLAS libraries without recompiling program? uno online, i.e.

Code: Select all

LD_PRELOAD=/usr/lib64/libopenblas.so.0 mlnscript --run script.mac
I have not tested how well this works however.
I tried this, and it works pretty well