Secure multicast is an effective group communication technology for information sharing and message exchange in emerging grids. As the group scale in grids may be very large and group members can be very unstable (a member can join or quit the group dynamically), it is hard for conventional group key management schemes to satisfy the efficiency of group key distribution very well because of the complexity of O(c.logn)( n is the group size, and c is the total additions/evictions). This paper gives a minimum exact cover problem of leaf set and discusses its solution based on an a-ary tree model. The correctness of the solution is proven theoretically. Furthermore, the implementation and application of it is illustrated. Both complexity analysis and simulation demonstrate the efficiency and effectiveness of the achievement of group key distribution based on minimum exact cover.