Build a PETSC_ARCH with -with-debugging=yes as a configure option and run 
it, preferably in a debugger (for example -start_in_debugger option) to find 
out where the bus error is taking place.


> On Sep 18, 2025, at 4:42 PM, Riousset, Jeremy via petsc-users 
> <[email protected]> wrote:
> 
> That helped. I now read my input file correctly. I am getting an error with 
> the line below:
> 
> DM da;
> ierr = 
> DMDACreate3d(PETSC_COMM_WORLD,DM_BOUNDARY_GHOSTED,DM_BOUNDARY_GHOSTED,DM_BOUNDARY_GHOSTED,DMDA_STENCIL_STAR,21,21,21,PETSC_DECIDE,PETSC_DECIDE,PETSC_DECIDE,19,1,PETSC_NULL,PETSC_NULL,PETSC_NULL,&da);CHKERRQ(ierr);
> 
> The error is: 
> 0]PETSC ERROR: 
> ------------------------------------------------------------------------
> [0]PETSC ERROR: Caught signal number 10 BUS: Bus Error, possibly illegal 
> memory access
> [0]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger
> [0]PETSC ERROR: or see 
> https://urldefense.us/v3/__https://petsc.org/release/faq/*valgrind__;Iw!!G_uCfscf7eWS!fh2X84CPIXKaFn6PkQPhrXJHX2qplg9tKOZ5R9PVc5RWTkcgK4phevcVoO3P_YgU5vu4GZREF8o52gfFFZ4W1b0$
>   
> <https://urldefense.us/v3/__https://petsc.org/release/faq/*valgrind__;Iw!!G_uCfscf7eWS!drLsYfgMTCNAyHHkj7gJrIUzQ9gnkjwyajLeWWqLLyV3mEdA2B7X0fX4pFYTyw9FVWpCJQ7BKm4Ba2f-wE5DJLwP$>
>  and 
> https://urldefense.us/v3/__https://petsc.org/release/faq/__;!!G_uCfscf7eWS!fh2X84CPIXKaFn6PkQPhrXJHX2qplg9tKOZ5R9PVc5RWTkcgK4phevcVoO3P_YgU5vu4GZREF8o52gfFoqV6M1A$
>   
> <https://urldefense.us/v3/__https://petsc.org/release/faq/__;!!G_uCfscf7eWS!drLsYfgMTCNAyHHkj7gJrIUzQ9gnkjwyajLeWWqLLyV3mEdA2B7X0fX4pFYTyw9FVWpCJQ7BKm4Ba2f-wJxIkrms$>
> [0]PETSC ERROR: configure using --with-debugging=yes, recompile, link, and 
> run 
> [0]PETSC ERROR: to get more information on the crash.
> [0]PETSC ERROR: Run with -malloc_debug to check if memory corruption is 
> causing the crash.
> --------------------------------------------------------------------------
> MPI_ABORT was invoked on rank 0 in communicator MPI_COMM_WORLD
>   Proc: [[44836,1],0]
>   Errorcode: 59
> 
> Since the code was running with an old version of PETSc, I am wondering what 
> I did to break it.
>     
> Jeremy A. Riousset, Ph.D. (he, him, his) 
> Associate Professor of Engineering Physics 
> Physical Science
> 
> 1 Aerospace Boulevard
> Daytona Beach, FL 32114
> +1 (386) 226-6407
> [email protected] <mailto:[email protected]>
> https://urldefense.us/v3/__https://orcid.org/0000-0003-1516-5337__;!!G_uCfscf7eWS!fh2X84CPIXKaFn6PkQPhrXJHX2qplg9tKOZ5R9PVc5RWTkcgK4phevcVoO3P_YgU5vu4GZREF8o52gfFDu9pfak$
>   
> <https://urldefense.us/v3/__https://orcid.org/0000-0003-1516-5337__;!!G_uCfscf7eWS!drLsYfgMTCNAyHHkj7gJrIUzQ9gnkjwyajLeWWqLLyV3mEdA2B7X0fX4pFYTyw9FVWpCJQ7BKm4Ba2f-wPlXko4P$>
> Embry-Riddle Aeronautical University 
> Florida | Arizona | Worldwide
> 
> 
>> On Sep 18, 2025, at 3:59 PM, Barry Smith <[email protected]> wrote:
>> 
>> External Sender: Use caution with links, attachments, or when sharing 
>> information.
>> 
>> 
>>   The PETSc options all begin with a single dash, so it is -options_file 
>> input/main.in
>> 
>>> On Sep 18, 2025, at 3:44 PM, Riousset, Jeremy via petsc-users 
>>> <[email protected]> wrote:
>>> 
>>> Hi,
>>> 
>>> I’m updating a code from PETSc 3.4 to run with the latest PETSc. Here is my 
>>> status:
>>> I read the parameters via: mpiexec -n 1 bin/./M4 --options_file 
>>> input/main.in
>>> I’m not opening main.in correctly
>>> None of the options are retrieved by e.g., PetscOptionsGetReal
>>> Do you have a suggestion to test what file the code is actually trying to 
>>> access?
>>> 
>>> Thanks
>>> 
>>> Jeremy A. Riousset, Ph.D. (he, him, his) 
>>> Associate Professor of Engineering Physics 
>>> Physical Science
>>> 
>>> 1 Aerospace Boulevard
>>> Daytona Beach, FL 32114
>>> +1 (386) 226-6407
>>> [email protected] <mailto:[email protected]>
>>> https://urldefense.us/v3/__https://orcid.org/0000-0003-1516-5337__;!!G_uCfscf7eWS!fh2X84CPIXKaFn6PkQPhrXJHX2qplg9tKOZ5R9PVc5RWTkcgK4phevcVoO3P_YgU5vu4GZREF8o52gfFDu9pfak$
>>>   
>>> <https://urldefense.us/v3/__https://orcid.org/0000-0003-1516-5337__;!!G_uCfscf7eWS!YiGxTKiNGs8EnS4pzFoO1YK18z4fx-sCtisUBloRO8dd6sUuh3kfUkimanAH5cJ-jgPhYw-Qk_8q8BBxAtPO0s_6$>
>>> Embry-Riddle Aeronautical University 
>>> Florida | Arizona | Worldwide
>>> 
>>> 
>> 
> 

Reply via email to