Object discovery is a fundamental service and a critical issue in peer-to-peer (P2P) networks, which has a great impact on the performance and scalability of P2P networks. Many search methods have been proposed for unstructured peer-to-peer networks during the past few years, but complicated organization, high search cost and maintenance overhead make them less practicable. To avoid these weaknesses, the authors propose an adaptive and efficient method for search in unstructured P2P networks, the Bayesian network-based search method (BNS), which retains the simplicity, robustness and fully decentralized nature like Gnutella. This approach assumes that if a peer has a particular resource and this resource has some relation to a resource that one is interested in, it is very likely that this peer has the resource that one is interested in as well. This scheme utilizes feedback from previous searches, including not only the feedback of an interested object itself but also those objects which have some semantic relations to the interested object. It applies Bayesian network to establish an inference model, infers probabilities based on this model, and probabilistically directs future searches. Experimental results show that the BNS method is effective, achieving high success rate and more discovered objects, low bandwidth consumption and less maintenance, and a good adaptation to changing network topologies.