Micro Focus ALM Tips And Tricks

Micro Focus ALM/Quality Center is an application lifecycle management tool for software quality assurance and test management to deliver apps quickly with confidence.

This post will have the monthly Micro Focus ALM/Quality Center Tips and Tricks which will be a consolidation of various common issues in Micro Focus ALM/Quality Center. Do check out this article for troubleshooting tips and tricks for other tools.

1. ALM/Quality Center – Tips And Tricks – Dec 2020

1. Instructions to initiate JVM Garbage Collection logs in ALM

It is very crucial to keep notice of the JVM heap consumption over a period of time. As whenever there is an imbalance then the user can take a stance to fix it. It is also necessary to know the levels of heap consumption along with the knowledge regarding garbage collection will take place.

  • You need to select the wrapper.conf file and open it for editing, you can find it in the location given below:

In Windows Operating System: <drive>\ProgramData\Micro Focus\ALM\wrapper

In Linux Operating System: /var/opt/ALM/wrapper

  • Then you need to add a JVM option,

2. Application Lifecycle Management (ALM) accession problem 

ALM can be accessed with some basic steps. The best way is to reach out to ALM from the Edge Browser along with Internet Explorer mode activated. 

3. Issues in the 15.0.1 version of ALM the date format (d/m/yy) regarding the enable/disable problem

At the very end of the former comments, header date format can be enabled and disabled in the 15.0.1 version of ALM. This problem can be solved by following the steps below:

  • You need to get a brand new site parameter. It is necessary because it will successfully navigate the behaviour of the changing date format.
  • The fix version is: QC/ALM v15.0.1
  • Then you need to enable the site configuration parameter.

Name of the Parameter: SHOW_DATE_FORMAT_IN_COMMENT

Values of the Parameter: N or Y 

Y value remains as a default.

4. Problems regarding the authentication of the SSO configuration

It often happens that users are not able to finish the specific request. There are error messages regarding the OSP configuration service and its malfunction. You can solve this problem on your own, but if you need professional assistance, then you need to seek help from your system administrator. Majorly this error occurs when the ‘local’ user is used in the ‘My Profile’ tab. Yet sometimes in the ‘Properties’ tab ‘Enable Local Authentication” this message keeps showing with no value. After the authentication is passed, you can follow the steps given below to solve your issue:

  • You need to find My Profile tab, and then select and set the following items:

IdP: alm

The Identity Key: User Name

  • Now you need to use the base 64 base format: https: //www.base64encode.org/ to encrypt the xml metadata file.

5. Queries regarding the initial ALM page and that if it is possible to take a detour from it

It seems that way because the initial ALM page simply asks for the user name and nothing else. After that, you are directed to the federation URL. Then the username and password are demanded from the user. When the user is done typing the details and submits them, the page takes off to another ALM page with login credentials asked again. Once this procedure is done, it views all the available projects.

It becomes quite bothersome and lengthy. At that moment only the default IDP called ALM is authenticated. This issue happens because the Enable Local Authentication is set to ‘Yes’ value. It results in the activation of the Discovery page, which isn’t the one needed at the moment. Finding an easy solution to take a detour from the first ALM screen is possible; you just need to follow the steps given below:

  • You need to go to the SSO configuration tool, and then you find Enable Local Authentication.
  • Click on Enable Local Authentication and then set the value as No.
  • Now, as per your requirement, you need to install all the SSO components.

6. Restriction of an outdated release of Cycle in Defect Target Release

Sometimes it is quite necessary to ward off selecting any expired or outdated Release, or Cycle in Defect Target Release. This is possible through the manipulation of the workflow in ALM. You can use the solution below to overcome this hurdle:

Function Bug_FieldCanChange(FieldName, NewValue)
  If FieldName = "BG_DETECTED_IN_REL" Then
  If RetrieveTR(NewValue) = True Then  'pass the name of the release
     Bug_FieldCanChange = DefaultRes
     msgbox "Release End Date has passed" & vbcrlf & vbcrlf & "Select a valid Release"
     Bug_FieldCanChange = False
  End If
  ElseIf FieldName = "BG_DETECTED_IN_RCYC" Then
  If RetrieveTC(NewValue) = True Then  'pass the name of the release
     Bug_FieldCanChange = DefaultRes
     msgbox "ReleaseCycle End Date has passed" & vbcrlf & vbcrlf & "Select a valid ReleaseCycle"
     Bug_FieldCanChange = False
  End If
  Bug_FieldCanChange = DefaultRes
  End If
End Function
Function RetrieveTR(RelName)
  Set relFactory = TDConnection.ReleaseFactory
  set RelFilter=   relFactory.filter
  RelFilter.filter("REL_NAME")="""" & RelName & """"
  Set listOfReleases = RelFilter.NewList
  Set ReleaseItem= listOfReleases.item(1)
  If ReleaseItem.DaysLeft > 0 Then
     bolAllowed = True
     bolAllowed = False
  End If
End Function
Function RetrieveTC(CycleName)
   Set cycFactory =TDConnection.CycleFactory
   Set cycFilter = cycFactory.Filter
   CycFilter.Filter("RCYC_NAME" ) = """" & CycleName & """"
   Set listOfCycles = CycFilter.NewList
   Set CycleItem= listOfCycles.item(1)
   If CycleItem.DaysLeft > 0 Then
     bolAllowed = True
     bolAllowed = False
  End If
End Function

7. Substituting the database utilized by ALM quickly

It is quite possible to replace or change the database that is being utilized by ALM rapidly. It is different for different Operating Systems. Also, the database or schema password should not change from the previous ones. The old and new database should be of Oracle or MSSQL for the following solutions to work.

You need to login to the ALM site admin:

  1. Find the Database Servers tab and click on it.
  2. You need to make sure that all the previous databases server and the details are listed there.
  3. Now you add a new Database Server.
  4. Then select Ping to confirm your connection.
  5. Now you need to try out the new database. For that, create a new empty project. Even after you are done testing do not delete this project. 
  6. Now you have to keep in mind the value of the database name that shows in the left side of the GUI. Then copy it and post it to a notepad.
  7. Do the same with the Connection String value. You need it for later. So copy this as well and paste on the Notepad.
  8. Now you have to end/stop ALM service completely.
  9. Then you can take help of the DBA to backup all of the ALM related databases or schemas. It can be done on the source database instance and then restored to the original form on the target database instance.
  10.  Now find the siteadmin.xml file and open it.

In Windows, you can find it through: 

<drive>\ProgramData\Micro Focus\ALM\webapps\qcbin\WEB-INF\siteadmin.xml

In Linux, you can find it through: /var/opt/ALM/webapps/qcbin/WEB-INF/siteadmin.xml

  1. Once you have located the file, you need to back up the file.
  2. Then simply find the element: DbUrl
  3. You need to change the connection string element value by particularly entering the new value that you made just now. 

For example:

The previous value: <DbUrl>jdbc:sqlserver://tm-sql2014:1433</DbUrl>

The recent new value: <DbUrl>jdbc:sqlserver:// tm-sql2017:1433</DbUrl>

Then make sure to save all the changes. After that, before you end the siteadmin.xml file, you need to note down the ‘DbName’ value because you will need it. It could be something like: 


From this example, we will take out the element value that is qcsiteadmin_db

It is actually the Site Admin database/schema name.

  1. Now you take help of DBA again as done before to create a backup of the site admin database/schema.
  2. Then use a query tool for the database that you have chosen.

For the MSSQL version using SQL Server Management Studio (SSMS) would be appropriate. And for Oracle using Oracle SQL Developer, TOAD, or something akin to that would suffice well.

  1. Now connect to the new database just made
  2. Then update all the table Projects that are visible in the site admin database. You need to utilise a correlated subquery that has all the data from the new project.

Oracle (here you need to mention the specific site admin schema name)

UPDATE <site_admin_schema_name>.PROJECTS SET DB_CONNSTR_FORMAT = (SELECT DB_CONNSTR_FORMAT FROM <site_admin_schema_name>.PROJECTS WHERE project_id = (select max(PROJECT_ID) from <site_admin_schema_name>.PROJECTS));
UPDATE <site_admin_schema_name>.PROJECTS SET DBSERVER_NAME = (SELECT DBSERVER_NAME FROM <site_admin_schema_name>.PROJECTS WHERE project_id = (select max(PROJECT_ID) from <site_admin_schema_name>.PROJECTS));




MSSQL w/WinAuth…

  1. Now you need to start the ALM service again.
  2. Then you need the dbid.xml files for all the projects. It has the old DB_USER_PASS value instead of the new one just made.

8. Failure in SSO configuration on ALM 15.0.1 version

It often happens that while adding the Keystore from the SSO configuration, sometimes it gets updated with the different and wrong Keystore encrypted password. The run_osp_deploy.sh cannot run properly if the file gets updated with the wrong password. This results in the replacement of the basic.pfx file and nothing, the file remains empty. 

The wrapper log on the screen views:

INFO  | jvm 1   | 2020/10/15 17:09:14.014 |      Load failed.: java.io.IOException: exception unwrapping private key - java.security.InvalidKeyException: Missing password
INFO  | jvm 1   | 2020/10/15 17:09:14.014 |            com.mercury.oracleutil.DDPKCS12KeyStoreProvider: null: unwrapKey: -1
INFO  | jvm 1   | 2020/10/15 17:09:14.014 |            com.mercury.oracleutil.DDPKCS12KeyStoreProvider: null: engineLoad: -1

You can fix this error by following the steps given below:

  1. You need to create a JKS Keystore file.
  2. Then you need to upload the file in the SSO Configuration tool.
  3. Even though the basic.pfx in the repository folder is vacant, make sure the password is correct.
  4. Now you need to remove the basic.pfx and then copy the JKS Keystore just made in the folder.
  5. You need to update these elements and change three of them:
  • From: oauth-keystore.file={repository folder /sa/DomsInfo/osp/basic.pfx

             To: oauth-keystore.file={repository folder}/sa/DomsInfo/osp/basic.jks

  • From: oauth-keystore.type=PKCS12

             To: oauth-keystore.type=JKS

  •  From oauth-key-alias=osp

                     To oauth-key-alias=<alias_from_keystore>

  1. Now all you have to do is run the OSP script on all the ALM nodes.

9. Failure in the upgradation of the registry keys

It often happens that due to the absence of permission of admin or business-related restrictions and after careful editing of the group policies, registry keys don’t get modified at all. Even internet Explorer mode does not help. You can always run Windows update to make it simple. Before solving the issue on your own, you need to make sure that your operating system is meeting all the minimum prerequisites to all the links that are provided below. 

  1. For investigating the presence of registry keys in Windows 10, you need to use the following commands from CMD along with the admin rights:
REG QUERY HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge\ /v InternetExplorerIntegrationLevel
REG QUERY HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge\ /v InternetExplorerIntegrationSiteList

If you are unable to find the keys or an error message pops up on the screen or any other value related issue, you need to use the next step:

  1. Here to create or update the keys closely follow the commands given below using an elevated CMD session properly:
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge\ /v InternetExplorerIntegrationLevel /t REG_DWORD /d 1 /f
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge\ /v InternetExplorerIntegrationSiteList /t REG_SZ /d file:///”C:/temp/site.xml” /f

You need to make sure that you carefully put it on the right path, same as the location of the .XML file.

Now for the procedure of activating internet Explorer mode in MS Edge is given access ALM from the Edge Browser with IE mode enabled:

IE mode compatibility: Link

IE mode troubleshooting: Link

10. Navigating the registry settings to find ALM Explorer td links 

Usually, the ‘td’ files can be found in the emails from ALM. It generally enables the user to visit the inside the ALM application. Follow the instructions that are given below to open the ‘td’ links on the Internet Explorer browser or the ALM Explorer.

You need to find the settings that are saved decline machines registry: HKEY_CURRENT_USER\Software\HPE\ALM Explorer\RunALMExplorer

You need to look closely at the corresponding values on the registry. Then for all of the options that are selected in Tools> TD Links setup under the ALM Explorer:

  1. Click on the TD links and open all of them in internet explorer

0 shall be the value, it is a default reaction.

  1. Now open all of the TD links in the ALM Explorer:

1 shall be the value, and it determines the default ALM Explorer instance, and all the various Explorer installations that react to various editions of the ALM.

  1. Now open all the TD links only for a particular list (ALM version)

2 shall be the value, you need to justify the various reactions to the ALM Explorer instances that react to all the different editions of the ALM servers. 

The command below can be utilised to find out the current value of the setting right from the registry:

REG QUERY “HKEY_CURRENT_USER\Software\HPE\ALM Explorer” /v RunALMExplorer

Though manual modification of this key may not prove as effective, it could be a better option when you need to change or edit some policies for many machines and users at one time.