The invention relates to the field of distributed storage, in particular to a
metadata expansion method and device under a
distributed file system, equipment and a storage medium. The method comprises the following steps: receiving a capacity expansion cluster request sent by a
client; according to the capacity expansion cluster request, a to-be-migrated target process is determined, the target process is used for managing
metadata, and an identifier of a file or
directory where the
metadata is located and the target process have a Hash mapping relation; metadata of the target process is copied from the first
metadata server to a second
metadata server, the Hash mapping relation is adjusted, and the second
metadata server is different from the first metadata
server. According to the embodiment of the invention, dynamic scheduling and load balancing are carried out on the metadata
server cluster through hash based on the
directory or the file, and the influence on services is remarkably reduced by minimizing the
data migration cost. Compared with a traditional method, the load balancing capacity is better, the
data migration cost is lower, and the expansibility is higher.