A computer program product embodied on a non-transitory computer-usable medium, the non-transitory computer-usable medium having stored thereon a sequence of instructions which, when executed by a processor causes the processor to execute a method for managing a virtual storage system, the method comprising:
- receiving information regarding metadata maintained by a plurality of nodes in the virtual storage system, wherein the plurality of nodes comprise respective distributed maintenance components;
- using the distributed maintenance components to manage the metadata for the virtual storage system, in which the metadata relate to storage of data within the virtual storage system;
- checking a state of the virtual storage system to identify inconsistencies within the metadata, wherein the checking is performed in parallel by the distributed maintenance components to scan the metadata;
- and
- maintaining the state of the virtual storage system based at least in part in results of checking the state of the virtual storage system, wherein maintaining the state of the virtual storage system is performed in parallel by the distributed maintenance components to fix the inconsistencies within the metadata distributed in the plurality of nodes.