Some content libraries backed by invalid SMB shares may consume storage space on vCenter server
search cancel

Some content libraries backed by invalid SMB shares may consume storage space on vCenter server


Article ID: 338056


Updated On:


VMware vSphere ESXi


Some content libraries backed by invalid SMB shares may consume root partition space on vCenter server, and vCenter server performance could be affected because of the reduced available storage space due to uploaded content in such libraries.


VMware vSphere ESXi 6.5
VMware vSphere ESXi 6.7


Content Library doesn't detect SMB mount error when creating libraries backed by invalid SMB shares in vSphere 6.5, therefore such libraries can be created without any error and uploading content to such libraries will be actually stored on the file system of the vCenter server.


The issue is resolved in vCenter Server 6.7 Update 1 and vCenter Server 6.5 Update 2d available at VMware Downloads.

Perform these steps to fix such affected SMB libraries if you do not want to upgrade to vSphere 6.7 U1 or vSphere 6.5 P03.

1. Run this SQL query against VCDB of vCenter server to find out libraries backed by SMB shares:

select,, storage.storageuri from cl_library lib, cl_library_storage lib_storage, cl_storage storage where = lib_storage.library_id and lib_storage.storage_id = and storage.storageuri like 'file:///etc/vmware-content-library/winmounts/library-win-mount%';

sample result:

                  id                  |  name  |                                                                                       storageuri                                                                    
d822d849-6a01-4461-8249-98aa8f7e8d88 | smblib | file:///etc/vmware-content-library/winmounts/library-win-mount-d822d849-6a01-4461-8249-98aa8f7e8d88-ClsPathSeparator-smb://

2. For each library from the list returned by the SQL query, run the following command on vCenter server to find out if the smb mount is actually on local file system and add the affected libraries to a SMB library list:

# get the mount path on file system from the storage URI, sample command:
echo "file:///etc/vmware-content-library/winmounts/library-win-mount-d822d849-6a01-4461-8249-98aa8f7e8d88-ClsPathSeparator-smb://" | sed 's/file:\/\/\(.*\)-ClsPathSeparator-smb:.*/\1/'

# check if the mount path is actually mounted on the server, sample command:
mount | grep "/etc/vmware-content-library/winmounts/library-win-mount-d822d849-6a01-4461-8249-98aa8f7e8d88"

If this command returns no entry (null), it means the library is consuming storage space from the vCenter server, and then add it to the SMB library list.

3. For each SMB library in the SMB library list, perform the following actions to migrate the content to new library:
   a. Create a new library with storage on datastore or NFS share as desired;
   b. Copy all items from the SMB library to the new library;
   c. Delete the SMB library;