fix a bug of cluster and add some code in clusterCommand