Quantcast
Channel: Latest Discussions - COMSOL Forums
Viewing all articles
Browse latest Browse all 5773

Error "No such file or directory" when trying to solve a model via "comsol batch" command on linux

$
0
0

Hi Comsol Community,

this is my first post on this forum, any feedback on how to better explain my request is very welcome :).

I am running Comsol Multiphysics 5.4 on a remote machine via an SSH client; my workstation runs on Windows while the remote machine runs on Ubuntu 14.04.5. So far I used the GUI to create and solve my models, but now I want to run several models on the remote machine over weekends/nights via a shell script.

While attempting this I am running into the following problem:

I created a file "h-conv-std.txt" with the following content:

comsol batch -inputfile constud_maxelref_1.mph

comsol batch -inputfile constud_maxelref_2.mph

The two files constud_maxelref_1.mph and -2.mph were already created and are located in the same folder as the .txt script file on the remote machine. Now I try to run the script via the command line of the SSH client, calling

bash h-conv-std.txt

Comsol Multiphysics starts, but can't find the files, this is the output I see in the console:

userXXX@SVXXXX:~/190502_Comsol_Models/190719_convergence_studies/190719_h-convergence$ bash "/home/userXXX/190502_Comsol_Models/190719_convergence_studies/190719_h-convergence/h-conv-std.txt"


COMSOL 5.4.0.295 progress output file


Fri Jul 19 17:12:58 CEST 2019 COMSOL Multiphysics 5.4 (Build: 295) starting in batch mode Opening file: /home/userXXX/190502_Comsol_Models/190719_convergence_studies/190719_h-convergence/constud_maxelref_1.mph /******************/ /*****Error********/ /******************/ (No such file or directory)dels/190719_convergence_studies/190719_h-convergence/constud_maxelref_1.mph Total time: 1 s.

The funny thing is: when I start the comsol batch directly (instead of using the script), it works - see following output:

userXXX@SVXXXX:~/190502_Comsol_Models/190719_convergence_studies/190719_h-convergence$ comsol batch -inputfile "/home/userXXX/190502_Comsol_Models/190719_convergence_studies/190719_h-convergence/constud_maxelref_1.mph"


COMSOL 5.4.0.295 progress output file


Fri Jul 19 17:53:22 CEST 2019 COMSOL Multiphysics 5.4 (Build: 295) starting in batch mode Opening file: /home/userXXX/190502_Comsol_Models/190719_convergence_studies/190719_h-convergence/constud_maxelref_1.mph Open time: 7 s. The input file name /home/userXXX/190502_Comsol_Models/190719_convergence_studies/190719_h-convergence/constud_maxelref_1.mph will be used as output file name. Running: Study 8 {std8} <---- Compile Equations: Time Dependent {st1} in Study 8 {std8}/Solution 12 {sol12} ------------------------------------------------------------------ Started at Jul 19, 2019 5:53:30 PM.

Any suggestions what could cause this behaviour? Maybe someone at least knows some tricks to narrow down if the issue is with Comsol Multiphysics or maybe with my rudimentary knowledge of how Ubuntu/Linux works?

Thanks in advance for your feedback!

Kind regards, Sebastian


Viewing all articles
Browse latest Browse all 5773

Trending Articles