The previous contribution uses the k-means procedure to create clusters. It converts into a chain route when the threshold content goes beyond the energy of the devices in the system. The information transmitter fuel includes the power of the machine circuitry and the magnitude of facts communication and blowout. The vibrancy helps in communication circuitry. The knowledge packages ship to the destination. The architecture has two stages. The groups form during the clustering stage. The Optimal CBR method uses the k-means procedure to construct groups. It selects the cluster head based on the Euclidean length and device fuel. The verge posted by the group head to the individual set associates is the characteristic weight above which the machine transmits the data to the head. When two-thirds of the devices are lifeless, the instruments use the greedy procedure to construct a chain-like multiple-hop methodology to reach the base station. A beacon transmission is sent by the base station to the active devices in the chaining stage (when the energy of the nodes is lower). The base station creates the path using multiple-hop chain routing and the greedy technique. The devices send the notification to the base station using the chain track. The proposed work increases security by 9.67% when transmitting data and by 11.38% (device getting compromised).