Most likely a stale entry in VCDB .
To resolve this issue delete stale entry from VCDB after backing up VCDB.
- Take a backup of the VCDB from vCenter Appliance or vCenter server and snapshot of vCenter VM.
- Log in to the vCenter server database and execute the following queries to capture the details for the content library.
- VCDB=# select id,name from cl_library;
id | name
--------------------------------------+-------
8bc3326e-3a0b-49e6-9be0-acb18b91d4b2 | Test
3b4280d3-b878-4428-85d0-867cb8252e66 | Stale
- VCDB=# select * from cl_library_storage;
library_id | storage_id
--------------------------------------+--------------------------------------
8bc3326e-3a0b-49e6-9be0-acb18b91d4b2 | ff3f7160-0731-4d01-9cc0-a2cce03ab3ce
3b4280d3-b878-4428-85d0-867cb8252e66 | 1325cd29-0b3e-4be4-8445-625da0dce452
(2 rows)
- VCDB=# select * from cl_storage;
id | storageuri | type
--------------------------------------+-------------------------------------------------------------+-----------
ff3f7160-0731-4d01-9cc0-a2cce03ab3ce | Datastore:datastore-11:f271f3f1-a924-4519-a3f5-e9a75d962888 | Datastore
1325cd29-0b3e-4be4-8445-625da0dce452 | Datastore:datastore-11:f271f3f1-a924-4519-a3f5-e9a75d962888 | Datastore
(2 rows)
- VCDB=# select id,name from vpx_datastore where id=11;
id | name
----+------
11 | DS1
(1 row)
Note: As per the snippets above, we see the id for the library is "3b4280d3-b878-4428-85d0-867cb8252e66". The storage id for the same library is "1325cd29-0b3e-4be4-8445-625da0dce452". When we check the location, we see that the library is saved in the datastore with id "11" (Datastore:datastore-11:f271f3f1-a924-4519-a3f5-e9a75d962888) We can get the datastore name from the datastore table, which is "DS1" here.
To remove stale entry follow below order.
VCDB=# delete from cl_library_storage where library_id='3b4280d3-b878-4428-85d0-867cb8252e66';
VCDB=# delete from cl_storage where id='1325cd29-0b3e-4be4-8445-625da0dce452';
VCDB=# delete from cl_library where id='3b4280d3-b878-4428-85d0-867cb8252e66';
The output for each of the above command would return "DELETE 1",Once deleted, we can log in to the web client.