This paper proposes a new generation algorithm for Peer-to-Peer(P2P) network topology with controllable clustering according to the analysis of P2P network connect behaviors.It analyses the generation and development of directed weighted network.The algorithm can effectively control the clustering coefficient by regulating the connection area.Experimental results indicate that the algorithm can model the P2P network with power law distributions of node degree and strength.