1. A computer program product comprising one or more computer readable storage media storing instructions translatable by one or more processors to perform: accessing network file systems at one or more physical locations; collecting file system metadata from the network file systems, wherein the file system metadata comprises one or more pieces of metadata of interest; applying one or more user-defined heuristics to the one or more pieces of metadata of interest to generate one or more file system statistics of interest; storing the one or more pieces of metadata of interest and the one or more file system statistics of interest in a metadata repository; enabling a user to define a rule via a user interface, wherein the rule comprises a pattern and an action and wherein the pattern comprise at least one of the one or more pieces of metadata of interest or at least one of the one or more file system statistics of interest; searching metadata records in the metadata repository that match the pattern; and applying the action on one or more managed objects in the network file systems that are associated with the metadata records, thereby changing a state of the network file systems.