Leakage in oil, gas, or water pipeline networks is a global concern; its impact has serious consequences on the ecosystem. Several solutions have been either proposed or in service for monitoring the pipeline networks. These proposals, however, are expensive, time-consuming, and most are intrusive which necessitate interrupting ongoing operations. The advances in sensing technologies made it possible to build affordable non-intrusive solutions. However, building a sensor network that is able to continuously monitor the pipeline, detect, and report any anomaly poses a number of challenges: node placement, energy saving, data flow, throughput, and just to mention a few. This paper presents an adaptive clustering algorithm for grouping and deploying multiple sensors along the whole pipeline. By using this algorithm, each group of sensors selects adaptively a cluster head, which aggregates the incoming traffic from its members and then delivers it to the next cluster head and so on until it reaches the base station. The simulation and prototypebased experiments' results have shown significant energy saving compared to contemporary approaches.INDEX TERMS Wireless sensor networks, pipeline monitoring, linear topology, optimal node placement.