-
Notifications
You must be signed in to change notification settings - Fork 194
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
Segmentation Fault when trying to run a script #3655
Comments
What is your
I would recommend using |
I checked and it is showing that I am running version 1.9.2. I just installed juliaup and made sure Oceanostics was updated. I got the following error
|
So I reduced my code to be just
and the code gave the following error
|
Update: I have been able to reduce the error to be a procompiling error in oceananigans.jl:
I have been trying to make sure that everything is up to date, and I am running on Julia version 1.9.2. My code is just
as I have been trying to get the library to load properly. Does anyone have any experience with this error or does it make things any clearer? |
Can you tell us a bit more about your system?
What is `versioninfo(verbose=true)` and `] status -m`?
Was there anything more printed above the message that precompilation
failed?
One thing you might want to try is using Julia 1.10, instead of 1.9, but
right now I don't have information to pinpoint what is causing the
segmentation fault.
…On Wed, Jul 17, 2024, 12:23 Logan Knudsen ***@***.***> wrote:
Update: I have been able to reduce the error to be a procompiling error in
oceananigans.jl:
ERROR: LoadError: Failed to precompile Oceananigans [9e8cae18-63c1-5223-a75c-80ca9d6e9a09] to "/glade/u/home/knudsenl/.julia/compiled/v1.9/Oceananigans/jl_AMNEzH".
Stacktrace:
[1] error(s::String)
@ Base ./error.jl:35
[2] compilecache(pkg::Base.PkgId, path::String, internal_stderr::IO, internal_stdout::IO, keep_loaded_modules::Bool)
@ Base ./loading.jl:2300
[3] compilecache
@ ./loading.jl:2167 [inlined]
[4] _require(pkg::Base.PkgId, env::String)
@ Base ./loading.jl:1805
[5] _require_prelocked(uuidkey::Base.PkgId, env::String)
@ Base ./loading.jl:1660
[6] macro expansion
@ ./loading.jl:1648 [inlined]
[7] macro expansion
@ ./lock.jl:267 [inlined]
[8] require(into::Module, mod::Symbol)
@ Base ./loading.jl:1611
in expression starting at /glade/derecho/scratch/knudsenl/BottomBoundaryLayer/testcode.jl:1
I have been trying to make sure that everything is up to date, and I am
running on Julia version 1.9.2. My code is just
using Oceananingans
as I have been trying to get the library to loas properly. Does anyone
have any experience with this error or does it make things any clearer?
—
Reply to this email directly, view it on GitHub
<#3655 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABDO2XAIMUIHCDCBIJA4NLZM2K75AVCNFSM6AAAAABK643UJWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMZTG4YTAMZXGI>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Sorry I didn't realize I didn't get the full error message:
The versioninfo gave me the following as output:
and the status check message gave me:
|
I don't know if this helps to make the issue clearer, but I just re-ran the code for just
and it executed without error. I ran it again to see if it was just a fluke and I got the following error:
Could it be an issue with the computer loading Oceananigans.jl with a bunch of extra functions? |
More information, I tried changing Oceananigans.jl builds by running in Julia
and I ran my code and it loaded fine the first time, but again it had a segmentation fault on the rerun. Similarly, when I executed
it ran the first time then got a segmentation fault on the second run again. Could this not be an issue with Oceananigans.jl but with how I am running my code on the GPU? |
Just to clarify things a bit for you @loganpknudsen --- your error says
this means that the segmentation fault occurs during precompilation of Another clue is the text
That says the error comes from line 129 in the file Oceananigans.jl/src/Oceananigans.jl Line 129 in d6e63e5
so there's something wrong with your CUDA / how it's loaded. The best course of action is probably to update to julia 1.10 first of all rather than using julia 1.9.2. Next, see if you can simply write |
Thank you for your help! I have installed the updated version of Julia and when running it appears to be Segfaulting when trying to add CUDA. I will open an issue with them if I cannot figure out how to solve it. Thank you again |
@logan can you link the CUDA issue here please? Also, if you haven't tried, erase everything on your For context |
Okay, here's the CUDA issue: JuliaGPU/CUDA.jl#2453 |
So I removed
|
Something else I tried was deleting the
I got:
|
Thank you to everyone who took the time to respond to this issue! I am still unclear on what exactly was driving the error I was getting, but I was able to fix it by creating a new environment in a clean directory and running the following modules on Casper for the UCAR HPC resources:
and then running my script. Thanks again for all the help! |
Thanks for posting the solution. What does the |
I am not certain what the |
What was the failing workflow / how was it different than this? |
The module loading sequence I was running was before that didn't work were
if needed I can see if I can find the versions of the modules that ended up working. There are no other major difference in how I load in the packages or Julia. Let me know if you have any questions |
Okay interesting! I'm not sure why you would need Also, did you try installing julia yourself? There could be some benefit in using the system Julia via You could also let julia handle netcdf --- again, I'm not sure if this would have performance implications or not, but it might provide faster way to get up and running if you are simply trying to run scripts. Julia's package manager should be able to automatically detect and install netcdf appropriate for the system, I think. |
I have been running on the system Julia for these, I attempted to do my own install but I do not think I ended up doing much with it. I believe
the last line returns
which does not happen if I include |
Ok, good to know! |
I am trying to run a script and when opening packages as below:
I get the following error:
How do I fix this? Thank you for any help
Edit: I have been working with @tomchor on trying to debug this issue
The text was updated successfully, but these errors were encountered: