We receive a lot of questions on QTP blog and forums regarding UFT(QTP) licensing and related issues. This post will serve as a guide to know all about UFT(QTP) license.
Types of UFT(QTP) license
There are two main types of UFT licenses –
- Seat License: This license is tied to the computer on which it is installed. The trial or a demo license of UFT is a seat license which has a validity of 30 days. You don’t require any keys for the trial license.
- Concurrent License: This is also known as floating license. This license type requires a concurrent license server to be installed in your office/local network. With concurrent license, a pool of licenses are assigned to the concurrent license server. Anybody in a local network can connect to this pool as long as at least a single license is available. For example – Let’s say your company has purchased 50 concurrent licenses of UFT. All these 50 licenses would be assigned to the license server. Now at any point of time, maximum 50 people in the local network of your company can work on UFT.
- Commuter License: This can be said as a special type of concurrent license which can be used when you don’t have access to the license server. In this case, you checkout a license from the concurrent license server for ‘n’ days where n <= 180. A use case for concurrent license can be – say you need to travel on work where you can’t connect to your company’s concurrent license server. In that case, you can check out a license from the server before you leave, go about your work and check-in back the license to the pool. The duration during which the licensed is checked out, it will behave like a seat license on your machine and the number of licenses on the license server will be reduced by one.
- Remote Commuter License: This is used when you want a license for a particular machine (say John’s machine) but John’s machine is not able to connect to the license server for checkout purposes. In that case, you would take help of a machine(say Mike’s machine) which IS able to connect to the license server and checkout a license for John’s machine. A detailed illustration is given later in this article.
This is a unique identification code for the machine on which UFT is installed. It is required when you want to install a seat license on your machine. Locking code can be obtained by running the UFT license installation wizard > Selecting ‘Seat license’ > Locking code. Once you get the Locking code, your company rep. should contact HP at this link and request for license keys for your machine.
Check the illustration below to get your machine’s Locking Code.
LSHOST and LSFORCEHOST variables
While the concurrent license installation wizard in UFT can be used to specify the license server, you can also make use of Windows environment variables to search and connect your UFT windows client with concurrent license servers.
Windows environment variables are available under System properties dialog box > Advanced tab > Environment variables button. The shortcut to access System properties is Windows key + Pause/Break key.
LSHOST can be used to set a preferred concurrent license server (so you can set multiple license servers separated with a semicolon in the User Variables list), while LSFORCEHOST can be used to force or restrict your UFT client to a particular license server. The Variable value box can take IP address or the host name. Please note that the environment variable values are restricted to 64 characters.
How to check-out and check-in a commuter license?
You can checkout a commuter license for your offline use from the concurrent license server, using a utility called WCommute.exe located under C:\Program Files\HP\Unified Functional Testing\bin. A license can be checked-out for a max duration of 180 days, post which it will automatically be returned to the license pool. If you wish to check-in the license during 180 days, you can make use of the same utility WCommute.exe.
How to check-out and check-in a remote commuter license?
There are a few steps you need to follow to check out a remote commuter license.
Going by the example of John and Mike mentioned above, where John is at a machine which can’t interact with server whereas Mike at a machine which can interact with a server here are the steps with an illustration.
- John will use WRCommute.exe utility present under C:\Program Files\HP\Unified Functional Testing\bin to send his machine’s locking code to Mike.
- Mike will use WCommute.exe and John’s locking code to generate a remote commuter authorization which is saved to a file and is sent to John.
- John again uses WRCommute.exe and the file sent by Mike to install the remote commuter license on his machine.
Please make sure that WCommute.exe and WRCommute.exe used in the process above are of same version.
How to manage concurrent license servers?
A utility known as WLMAdmin.exe can be used to add, manage or monitor concurrent licenses in a concurrent license server. This utility can be found in your UFT installation disk or a UFT dump file downloaded from HP, under the folder LicenseServer\utils.
Note: Unlike WCommute.exe and WRCommute.exe, WLAdmin.exe is not copied to your installation directory during installation.
How to restrict concurrent license usage among various groups in an organization?
Ok, this is something advanced and should be used by someone who is in-charge of managing the license server.
You may have several groups in an organization using the same concurrent license server. You want that licenses should be fairly divided amongst those groups and restrict a particular group from consuming all licenses. This can be achieved using a utility called WlsGrmgr.exe, present under the folder LicenseServer\utils. (as mentioned above)
What type of license should be used for virtual machines?
Virtualization software like Citrix, VM Ware may generate a different locking code for each of the sessions, so you can’t use seat license on such machines. You should use commuter license if you’re using virtual machines.
UFT(QTP) license cost
Last we checked, seat license were available for $8000 – $12000, for US region. There can be a lot of variance in license cost depending upon your region, organization etc so it is advisable to get in touch with your HP sales rep. If you’re aware of the cost of QTP license that is used in your org, please mention in the comments section below.
UFT(QTP) license key and license file location
UFT license keys are stored in LSERVRC file. This file can be located under –
- C:\Documents and Settings\All Users\Application Data\HP\Functional testing\License for Win XP and
- under %programdata%\HP\Functional testing\License\lservrc for Win Vista, Win 7 and Win 8.
LSERVRC file can be opened in a simple editor like notepad. The path to LSERVRC file is added under Windows Environment variables discussed above during installation.
You can check our step-by-step instructions to download & install QTP on your machine.
I hope this article would help you with all your questions pertaining to QTP licenses. In case we have left something, please feel free to ask/contribute in the comments section below.