- In Windows Task Manager, select the Services tab, and then locate Jenkins.

- Right-click on the Jenkins service and select Open Services. This will open a new window with all the services.

- In the Services window, right-click the Jenkins service and select Properties.
- In the Jenkins Properties window, select the Log On tab. Then select This account, and enter your username and password with valid MATLAB license.

- Restart Jenkins so that it can use the provided username and password when invoking MATLAB. Then, rerun your build.
Why do Jenkins builds with MATLAB fail on a Windows machine?
7 views (last 30 days)
Show older comments
MathWorks Support Team
on 8 Mar 2021
Edited: MathWorks Support Team
on 12 May 2023
When I try to run code on a Windows machine using the Jenkins plugin for MATLAB, the build fails with this error message:
ERROR: MATLAB error Exit Status: 0x00000001
Why is this message displayed? Is there a way to fix the problem?
Accepted Answer
MathWorks Support Team
on 12 May 2023
Edited: MathWorks Support Team
on 12 May 2023
The exit code suggests that MATLAB did not run successfully. This error might be because of a potential MATLAB licensing error. To run MATLAB code or Simulink models, Jenkins needs access to a valid MATLAB or Simulink license.
When you install Jenkins using either 'installer.exe' or 'jenkins.msi', it becomes a Windows service. As a Windows service application, Jenkins can be accessed using Windows system credentials. If your Windows system credentials are different from your MATLAB license credentials, Jenkins cannot access MATLAB and fails the build.
To enable the Jenkins service application to access MATLAB, follow these steps:
For more information about running MATLAB with Jenkins, please refer to this page.
0 Comments
More Answers (0)
See Also
Categories
Find more on Startup and Shutdown in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!