FairRootGroup / FairSoft

Repository for installation routines of the external software required by FairRoot
GNU Lesser General Public License v3.0
16 stars 61 forks source link

Permission Denied when installing Geant4 data with spack #426

Open janmayer opened 3 years ago

janmayer commented 3 years ago

When installing the latest dev version with spack, i get a permission denied error when installing the Geant4 data packages. I could trace it back to shutil.copy2 in filesystem.py. Replacing copy2 with copyfile resolves the issue.

System is RHEL 8 with Python 3.6.8.

ChristianTackeGSI commented 3 years ago

Hi!

Thanks for your report!

Are you able to trace down why copy2 did not work for you, but copyfile does? From my quick looks, it seems, that copy2 tries to copy over metadata in addition. Are you installing to a strange filesystem, that does not support chmod or something?

janmayer commented 3 years ago

Its is a GPFS filesystem.

I didn't fully track it down. One of my hypotheses was that the files (and folders?) it tries to copy are readonly. I.e., it copies the folder, sets it to readonly, and then fails to copy the files into it. Probably not though.

As a sidenote: I know spack is not your code, but I think this part is quite overengineered. Python has a copy_tree function - I see no good reason to re-implement it.