Jenkins: "License Not Found" Issue

Applies to ReadyAPI 3.57, last modified on December 20, 2024
Important Notice for ReadyAPI Customers

ReadyAPI has moved to SmartBear License Management and from October 2023, file-based licensing will be retired. As of September 2023, all licenses issued for your subscription term will be ID-based licenses by default. If you are not currently on ID-based licensing, it's time to migrate immediately. File-based licensing will no longer be supported as of October 2023. This means that technical support requests related to file-based licensing will not be accommodated. If you encounter technical issues that you're unable to resolve, it could lead to service interruption. For customers still in the process of migration, we recommend reaching out to your Account Manager to discuss your migration plan. Alternatively, you can log a support request with our Customer Care Team for assistance.

For more details regarding licensing support, please refer to this link.

When you run the test runner from Jenkins, you may encounter the "License not found" error.

Jenkins Error

Click the image to enlarge it.

A common cause of this is that you are not running Jenkins under the same user account you used to activate the ReadyAPI Test license.

Whether you are running Jenkins independently as a service or on your application server, you need to ensure it is running under the same user account you used to activate the ReadyAPI Test license. This topic describes how to fix the issue.

For Windows users

The following scenario describes how to configure licensing on the Jenkins master machine. On agent machines, you need to repeat this scenario using the same user account you used to activate the license.

  1. Make sure you have a valid license activated. If you do not have a valid license, activate a ReadyAPI Test license (see License Activation).

  2. Open the Control Panel.

  3. Select System and Security and then Administrative Tools.

  4. Run the Services utility.

  5. Search for the Jenkins service.

  6. Right-click the service and select Properties.

  7. On the Log On tab, select This account and enter the credentials of the Windows user account you will use to run ReadyAPI Test.

  8. Note: This is the account that you used when activating the ReadyAPI Test license.

    Dialog

    Click the image to enlarge it.

  9. Restart the service to apply the changes.

For Linux/MacOS users

To fix this issue on Linux or MacOS machines, run the corresponding job on the node that is run via SSH. It allows you to select the user under which Jenkins runs the job. To create a node, perform the following steps:

  1. In Jenkins, go to Manage Jenkins > Manage Nodes > New Node.

  2. Specify the name of the node and select the Permanent Agent mode. Click OK.

  3. To run a particular job on this node, specify a unique label for the node.

  4. In the Launch method drop-down list, select Launch slave agents via SSH.

  5. Specify localhost as a Host.

    Create a node

    Click the image to enlarge it.

  6. In the Credentials field, click Add and select the Jenkins provider.

    Add credentials

    Click the image to enlarge it.

  7. Specify the login and password of the user under which you want to run a job and click Add.

    Add credentials

    Click the image to enlarge it.

  8. Select the created credentials from the drop-down list.

    Select credentials

    Click the image to enlarge it.

  9. Click Save to create the node.

To run the job on the created node:

  • Open the job’s configuration.

  • Enable the Restrict where this project can be run option.

  • Specify the needed label in the Label Expression field.

Job configuration

Click the image to enlarge it.

Use the command line

You can use the command line to run Jenkins under the user account you used to activate the license. To do that, log in to the operating system using this account, and then run the following command:

java -jar jenkins.war

This will force Jenkins to run under the needed user account, so the License Not Found error will not occur.

Note: This workaround does not work on Linux/OS X agent machines properly. In this case, you need to use the approach described above.

Contact Support

If you fail to resolve the issue, please contact SmartBear Support.

See Also

Troubleshooting

Watch the video
 
Highlight search results