Loading

×Sorry to interrupt
Uncaught ReferenceError: addCTracking is not defined
throws at https://kb.vmware.com/resource/KM_TealiumTrackingJS?v=0.5:100:1

Refresh

Cookie Preference Center

General Information on cookies

When you visit our website, we use cookies to ensure that we give you the best experience. This information does not usually directly identify you, but it can give you a more personalized web experience. Because we respect your right to privacy, you can choose not to allow some types of cookies by clicking on the different category headings to find out more and change your settings. However, blocking some types of cookies may impact your experience on the site and the services we are able to offer. Further information can be found in our

Cookie Policy.

Strictly Necessary

Strictly Necessary

Always Active

Strictly Necessary

Strictly necessary cookies are always enabled since they are essential for our website to function. They enable core functionality such as security, network management, and website accessibility. You can set your browser to block or alert you about these cookies, but this may affect how the website functions. For more information please visit www.aboutcookies.org or www.allaboutcookies.org.

Cookie Details‎

Performance

Performance

Performance

Performance cookies are used to analyze the user experience to improve our website by collecting and reporting information on how you use it. They allow us to know which pages are the most and least popular, see how visitors move around the site, optimize our website and make it easier to navigate.

Cookie Details‎

Please confirm your settings by refreshing the page.

Functional

Functional

Functional

Functional cookies help us keep track of your past browsing choices so we can improve usability and customize your experience. These cookies enable the website to remember your preferred settings, language preferences, location and other customizable elements such as font or text size. If you do not allow these cookies, then some or all of these services may not function properly.

Cookie Details‎

Advertising

Advertising

Advertising

Advertising cookies are used to send you relevant advertising and promotional information. They may be set through our site by third parties to build a profile of your interests and show you relevant advertisements on other sites. These cookies do not directly store personal information, but their function is based on uniquely identifying your browser and internet device.

Cookie Details‎

Advertising Cookies

Consent Leg.Interest

Select All Vendors

Select All Vendors

Select All Hosts

Select All

Clear Filters

Information storage and access

Apply

Confirm My Choices Reject All Allow All

My Subscriptions

Loading

Knowledge Base

Unable to access catalog items or Post upgrade failures after vRealize Automation upgrade (58002)

Last Updated: 12/6/2019Categories: TroubleshootingTotal Views: 16854Language:
English

Subscribe to get an email
newsletter with new updates

Please provide article feedback:

Symptoms

Post upgrade task fails during upgrade attempt with:

2018-10-31T19:49:44.400742+00:00 FQDNofAppliance vcac-config: ERROR liquibase.severe:89 - liquibase/catalog-service-master.xml: liquibase/catalog-service-BUG2067627.xml::1::BUG2067627: Change Set liquibase/catalog-service-BUG2067627.xml::1::BUG2067627 failed.  Error: Error executing SQL ALTER TABLE public.cat_tenant ALTER COLUMN id TYPE CITEXT: ERROR: could not create unique index "cat_tenant_pkey"
Detail: Key (id)=(DEV) is duplicated.

You are unable to access catalog items

In /var/log/vmware/vcac/catalina.out you see entries similar to:

[UTC:2018-09-07 11:05:49,831 Local:2018-09-07 11:05:49,831] vcac: [component="cafe:catalog" priority="ERROR" thread="tomcat-http--49" tenant="tenant-name" context="mwMhych9" parent="" token="mwMhych9"] com.vmware.vcac.platform.service.rest.resolver.ApplicationExceptionHandler.handleUnexpectedException:874 - result returns more than one elements; nested exception is javax.persistence.NonUniqueResultException: result returns more than one elements
org.springframework.dao.IncorrectResultSizeDataAccessException: result returns more than one elements; nested exception is javax.persistence.NonUniqueResultException: result returns more than one elements

In postgres database cat_tenant table you see duplicate entry for tenant:

# select * from public.cat_tenant;
id | lastsync | name
---------------+-------------------------+---------------
TENANT | 2017-11-22 17:00:04.934 | TENANT
tenant | 2018-09-06 19:05:14.954 | TENANT
vsphere.local | 2018-09-06 20:27:57.591 | vsphere.local
(3 rows)

Impact / Risks

As with any manual edits to a live database, ensure there is a full backup before making any modifications

Resolution

To work around the issue, remove the dependency and delete the old tenant.

Caution: The following steps involve deletion of data. Ensure you have taken valid snapshots of the appliance(s).

Open SSH session to vRA

Connect to the database:

su - postgres

psql vcac

Identify the old tenant:

# select * from public.cat_tenant;
id | lastsync | name
---------------+-------------------------+---------------
TENANT | 2017-11-22 17:00:04.934 | TENANT
tenant | 2018-09-06 19:05:14.954 | TENANT
vsphere.local | 2018-09-06 20:27:57.591 | vsphere.local
(3 rows)

Attempt to delete the tenant:

BEGIN;
# delete from cat_tenant where id='TENANT';

If DELETE was successful, commit the transaction:

COMMIT;

Else, ROLLBACK;

In the event you get an error similar to:

ERROR: update or delete on table "cat_tenant" violates foreign key constraint "cat_icon__tenant_id__cat_tenant__id__fkey" on table "cat_icon"
DETAIL: Key (id)=(TENANT) is still referenced from table "cat_icon".

Inspect table cat_icon:

select * from public.cat_icon;

You may see entries like:

id | contenttype | filename | image | subtenant_id | tenant_id
------------------------------------------------------------+-------------+------------------------------------------------------------+-------+--------------+----------
cafe_default_icon_genericCatalogItem | image/png | genericCatalogItem.png | 26344 | |
cafe_default_icon_genericService | image/png | genericService.png | 26345 | |
cafe_default_icon_genericResourceOperation | image/png | genericResourceOperation.png | 26346 | |
cafe_default_icon_genericAllServices | image/png | genericAllServices.png | 26347 | |
software_catalog_item_icon | image/png | software_catalog_item_icon | 26348 | |
ServiceIcon-1495091052664 | image/png | Linux.png | 26629 | | tenant
ServiceIcon-1495091070014 | image/png | Windows (1).png | 26630 | | tenant
ServiceIcon-1495091098833 | image/png | VCO.png | 26631 | | TENANT

Update the table to remove the dependency on cat_tenant table:

BEGIN;
UPDATE cat_icon SET tenant_id = 'tenant' WHERE tenant_id = 'TENANT';

Execute DELETE query again:

delete from cat_tenant where id='TENANT';

If delete is successful, commit the transaction:

COMMIT;

Else, ROLLBACK;

Related Information

NOTE! If the cat_subtenant table is impacted, please open a new problem report for guidance. Do not run any scripts associated with cleaning up this content.  This issue can be environment specific.  Do not deviate from these instructions unless instructed to do so by VMware development engineering teams.

Detectable by VMware SkylineTM

Actions

Copy

link to clipboard
copied!

Print

Language:
English

Attachments

Additional Resources

No results for undefined

Ask The Community

Get answers quickly from VMware experts in the community

Post Subject

CONTINUE IN COMMUNITIES

Related Products:

VMware Aria Automation

Related Versions:

VMware vRealize Automation 7.x

Take Our Survey

Support Assistant