July 20, 2023 at 9:07 amjanot.lubritzSubscriber
I am trying to include USERMAT files in my Ansys code via the dynamic library linking option. I did everything as described in the manual (ANS_USER_PATH is set, USERMAT.F and ANSUSERSHARED.bat are in the folder and did compile, the output window shows that ANSYS is linked by licensee) but everytime I run my APDL code (which works without the USERMAT) the run terminates abnormally and the window closes without any message. When I restart APDL it says:
*** ERROR ***
Another ANSYS job with the same job name (dll_UPF_Check_20072023) is already running in this
directory or the dll_UPF_Check_20072023.lock file has not been deleted from an abnormally
terminated ANSYS run. To disable this check, set the ANSYS_LOCK environment
variable to OFF.
Do you wish to override this lock and continue (y or n)?
I checked the .lock file but it's empty and I have no idea what could be the problem. I know that the USERMAT works since I linked it via the new .exe linking option but I want to switch to the .dll linking option.
Does anybody have an idea on what could be the problem? I run Mechanical APDL 2022R1 on Windows 10.
Thanks a lot in advance!
July 22, 2023 at 12:53 ammjmiddleAnsys Employee
I’m just adding my two cents since I don’t work with the UPF, but I can tell you that the .lock file is always an empty file. It’s presence is just used to indicate whether the previous Ansys session ended abnormally, in which case it would produce the error you pasted. You can just type “y” to override the previous lock and continue launching Ansys. Or just delete the .lock file before launching Ansys, and it will launch normally, without any recognition of the previous abrupt exit.
Is there anything relevant to the crash left in the .err file?
July 25, 2023 at 7:37 amjanot.lubritzSubscriber
Thanks for the response. There are some warnings in the .err file but they’re all related to the model and not the “solver” itself. I cannot find anything that would lead to a total crash and not just an error prompt during the solving provess.
I know that I can override or delete the lock file but when I try to run it again APDL crashes again...
The same model does run with the USERMAT linked via the .exe file so I know that it does run through. I just have no clue why the linking with the dll library does not work. When I compile files beforehand with ansusershared.bat it does create dll and other files but the linking to APDL with the system variable ANS_USER_PATH somehow does not work (even though it says in the command prompt: This version is linked by licensee).
July 25, 2023 at 1:26 pmjanot.lubritzSubscriber
Update: I figured that it does not crash when I use the original Ansys folder for the compilation (C:\Program Files\ANSYS Inc\v221\ansys\custom\user\winx64) and switch my ANS_USER_PATH variabel to the same folder. It says everywhere that any folder can be used for the compilation as long as the ansusershared.bat and the usermat.f are existant. Looks like that is not the case but everything is working now.
- You must be logged in to reply to this topic.
Boost Ansys Fluent Simulations with AWS
Computational Fluid Dynamics (CFD) helps engineers design products in which the flow of fluid components is a significant challenge. These different use cases often require large complex models to solve on a traditional workstation. Click here to join this event to learn how to leverage Ansys Fluids on the cloud, thanks to Ansys Gateway powered by AWS.
Earth Rescue – An Ansys Online Series
The climate crisis is here. But so is the human ingenuity to fight it. Earth Rescue reveals what visionary companies are doing today to engineer radical new ideas in the fight against climate change. Click here to watch the first episode.
Subscribe to the Ansys Blog to get great new content about the power of simulation delivered right to your email on a weekly basis. With content from Ansys experts, partners and customers you will learn about product development advances, thought leadership and trends and tips to better use Ansys tools. Sign up here.
- Solver Pivot Warning in Beam Element Model
- Saving & sharing of Working project files in .wbpz format
- Understanding Force Convergence Solution Output
- User manual
- An Unknown error occurred during solution. Check the Solver Output…..
- What is the difference between bonded contact region and fixed joint
- The solver engine was unable to converge on a solution for the nonlinear problem as constrained.
- whether have the difference between using contact and target bodies
- Defining rigid body and contact
- Colors and Mesh Display
© 2023 Copyright ANSYS, Inc. All rights reserved.