Category Archives: ALM

HP Application Lifecycle Managemenet

“Too many open files” error in ALM wrapper log

When ALM is deployed on Linux and the error “Too many open files” exists in the wrapper logs, this is an indicator the “open file” limit on the Unix file system has been exceeded.

This can cause issues where attachments can’t be opened, tests executed, inability to open scripts or save scripts.

By default the “open file” limit on Linux is set to 1024; the number of concurrently open files.

To determine the “open file” value type the following in the Unix shell…

utlimit -a

Many results will be returned. Examine the value of the “open files” parameter.

To correct do the following…

1) Using vi or similar method, open the file /etc/security/limits.conf

2) Add the following lines to the file…

root soft  nofile <value>
root hard  nofile <value>

For example…

root soft  nofile 2048
root hard  nofile 2048

The value should be increased until the “Too many open files” error goes away. Start by doubling the current value.

3) Save the file
4) Restart Linux

Suggest checking to make sure the changes were implemented by issuing: ulimit -a
Then check the “open files” limit to make the changes took place.

Advertisements

Cannot add HTTPS Performance Center URL in Application Lifecycle Management LAB Management

ALM and PCS were configured to work with HTTPS, when adding the HTTPS PCS URL, the lab management shows an error message that it could not connect to the PCS through HTTPS .

ALM and PCS certificates are installed in the correct keystone, and both URLS work.

Please review with the customer Information Technology (IT) team if there are any IT policy that automatically disable TLS 1.0 after a Server reboot.

If there is a policy on disabling  the TLS 1.0 in the PCS machine, it can result in the PC machine rejecting the ALM communication.

Once TLS 1.0 was enabled, PCS servers with HTTPS URL can be added to the ALM LAB management.

How to switch between “HTML” and “Run Results Viewer” format in UFT 12.5X

In UFT 12.5X Run Results are created, by default, in HTML. Although this is preferred as it offers a multi-platform, browser independent format for Run Results, it be desirable to switch to the legacy format where the Run Results Viewer format is used.

To change the desired format, do the following steps:
1)      Open UFT 12.5X
2)      Click Tools>Options
3)      Select the General item at the top of the window
4)      In the body, under “Report Format” select the desired format “HTML” or “Run Results Viewer Report
Mind that selecting the Run Results Viewer Report option will require a Windows OS with the Run Results Viewer installed in order to view the report.
Also know the HTML format option consumes less disk space; the results files are approximately 50% smaller than Run Results Viewer format.

Note: When running tests from ALM, you can view the HTML report only if you are using one of the following ALM versions:
– ALM 11.52 Patch 5 or higher,
– ALM 12.21 and higher.

Project statuses in ALM/QC

Project status is determined by PR_IS_ACTIVE field in PROJECTS table, in QC SITEADMIN schema.

Project statuses:

• ACTIVE_STATUS = “Y”;
• INACTIVE_STATUS = “N”;
• TARGET_BORROW_STATUS = “B”;
• SOURCE_BORROW_STATUS = “S”;
• CONTINUE_BORROW_STATUS = “C”;
• EXPORT_PROJECT_STATUS = “E”;
• IMPORT_PROJECT_STATUS = “I”;
• MAINTENANCE_STATUS = “M”;
• MAINTENANCE_RESUME_STATUS = “R”;

TIP:
When you are doing operations ( like copy or import project operation), Some times browser seems to be hanged, to confirm whether operation going on or not, check the project status(PR_IS_ACTIVE) in PROJECTS table.
Wait until the operation on the project is completed(i.e change in the status)

Cannot create a new database connection to SQL server named Instance

Can’t create a new database connection for url ‘jdbc:mercury:sqlserver://SQLServerName\Instance:1433’ on setting catalog to ‘default_lab_project_db1’
java.sql.SQLException
ALM does not support  database server alias with “\”, ALM supports database parameters for establishing connections to MS SQL server named Instances, which involves “\”.
Remove “\” or “/” from ALM database server alias name:

Already created database servers in ALM

DBServerAlias

When creating a database server in ALM

CreatingDbServerAlias

Failed to fetch data from ANALYSIS_ITEM_FOLDERS

When accessing to the Releases inner tab of the Management module, an error is displayed

image text

Error in ALM logs:

Messages:
Failed to fetch data from ANALYSIS_ITEM_FOLDERS; [Mercury][SQLServer JDBC Driver][SQLServer]Invalid object name ‘ANALYSIS_ITEM_FOLDERS’. Failed SQL: /* ~~QC */ SELECT AIF_OWNER,AIF_NAME,AIF_PARENT_ID,AIF_PATH,AIF_VER_STAMP,AIF_ID,AIF_SEGMENT_ID,AIF_PUBLIC,AIF_LOGICAL_NAME,AIF_DESCRIPTION FROM ANALYSIS_ITEM_FOLDERS LEFT OUTER JOIN VF_ANALYSIS_ITEM_FOLDERS ON AIF_ID = VF_ANALYSIS_ITEM_FOLDERS.VF_AIF_ID WHERE ((AIF_ID IN (/*P*/1004)) AND (EXISTS (SELECT 1 FROM ANALYSIS_SEGMENTS WHERE AS_ID = AIF_SEGMENT_ID AND (AS_IS_PUBLIC = /*P*/’Y’ OR AIF_OWNER IN (/*P*/’USER_NAME’,/*P*/’__default__’))))) ORDER BY AIF_ID ASC;

Problem is caused by the view ownership at the SQL database, the database project Views ownership is not compatible with the either SQL or Windows database authentication. This is detected after upgrading/restoring an Application Lifecycle Management (ALM) project with a Microsoft SQL database server as backend,  when moving/restoring a project that was using in ALM – SQL windows authentication environment to an ALM – SQL Authentication environment, and viceversa.
For a project using MS SQL – changing views ownership to SQL authentication run :

Exec sp_changeobjectowner ‘[dbo].[V_LINK_CYCLE]’,‘td’Exec sp_changeobjectowner ‘[dbo].[V_LINK_REQ_VIA_TEST]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[V_LINK_RUN]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[V_LINK_REQ]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[V_LINK_TEST]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[V_LINK_TESTCYCL]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[VF_ANALYSIS_ITEMS]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[VF_ANALYSIS_ITEM_FOLDERS]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[VF_DASHBOARD_PAGES]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[VF_FAVORITE_HAS_SHARES]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[V_LINK_REQ_VIA_TESTCYCL]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[V_LINK_STEP]’, ‘td’

Exec sp_changeobjectowner ‘[dbo].[VF_DASHBOARD_FOLDERS]’, ‘td’

For a project MS SQL – changing views ownership to Windows authentcation :

Exec sp_changeobjectowner ‘[td].[V_LINK_CYCLE]’,‘dbo’

Exec sp_changeobjectowner ‘[td].[V_LINK_REQ_VIA_TEST]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[V_LINK_RUN]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[V_LINK_REQ]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[V_LINK_TEST]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[V_LINK_TESTCYCL]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[VF_ANALYSIS_ITEMS]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[VF_ANALYSIS_ITEM_FOLDERS]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[VF_DASHBOARD_PAGES]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[VF_FAVORITE_HAS_SHARES]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[V_LINK_REQ_VIA_TESTCYCL]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[V_LINK_STEP]’, ‘dbo’

Exec sp_changeobjectowner ‘[td].[VF_DASHBOARD_FOLDERS]’, ‘dbo’

Duplicate Favorites Issue when upgrading a project from QC 10.00 or earlier to ALM 11.XX

In Application Lifecycle Management (ALM) 11 or 11.5X the below error can be seen during project upgrade:

[SQLServer JDBC Driver][SQLServer]The CREATE UNIQUE INDEX statement terminated because a duplicate key was found for the object name ‘td.FAVORITES’ and the index name ‘FAVORITES_NAME_LWR_UK’. The duplicate key value …

or

Error: Failed SQL: /* ~~QC */ INSERT INTO FAVORITES

(FAV_ID,FAV_PARENT_ID,FAV_NAME,FAV_FILTER_DATA,FAV_LAYOUT_DATA,FAV_IS_PUBLIC,FAV_OWNER,FAV_MODULE,FAV_VER_STAMP) VALUES (, , , , , , , , …) [Mercury][SQLServer JDBC Driver][SQLServer]Cannot insert duplicate key row in object ‘td.FAVORITES’ with unique index ‘FAVORITES_NAME_LWR_UK’.

In Quaility Center (QC) 10.00 and earlier versions of QC it was possible to have different kind of favorite filters (for Grid and Tree views) with the same name.

In ALM 11.00 and above the favorites were consolidated to the ‘Favorites’ menu in both of the views (Tree and Grid Views). Therefore favorites with the same name cannot be moved to the new structure as they became duplicates and this is causing the upgrade the upgrade of the project to fail.

To resolve the problem and eliminate the duplicates the below solution could be used. Note that the ALM project has to be backed up prior any modification.

  1. Run the following query from a database management tool:

SELECT DISTINCT a.CSET_NAME, a.CSET_OWNER FROM td.COMMON_SETTINGS a, td.COMMON_SETTINGS b

WHERE a.CSET_CATEGORY in (‘PLANN_GRID_VIEWS’,’PLANN_VIEWS’)

and b.CSET_CATEGORY in (‘PLANN_GRID_VIEWS’,’PLANN_VIEWS’)

and a.CSET_NAME <> ‘__default__’

and b.CSET_NAME <> ‘__default__’

and a.CSET_OWNER <> ‘__default__’

and b.CSET_OWNER <> ‘__default__’

and a.CSET_OWNER = b.CSET_OWNER

and a.CSET_NAME = b.CSET_NAME

and a.CSET_CATEGORY <> b.CSET_CATEGORY

order by a.CSET_NAME

  1. For each row (CSET_NAME, CSET_OWNER) pair in the result run the following query:

UPDATE td.COMMON_SETTINGS

SET CSET_NAME = CSET_NAME + ‘_tree’

Where CSET_NAME = ‘<CSET_NAME>’ and CSET_OWNER = ‘<CSET_OWNER>’ and CSET_CATEGORY =’PLANN_VIEWS’

Replace the <CSET_NAME> with the row CSET_NAME value from the result of query 1, and <CSET_OWNER> with the row CSET_OWNER value from the result of query 1.