The victims have been identified as Pradeep Kumar Yadav (22) and Niraj Kumar Yadav (14), police said.
The incident took place at Jogiya village late last night as the assailants raided a house and fired indiscriminately upon members of two families in which two persons were killed and seven others sustained injuries, Brahmpur police station in-charge Sarvesh Kumar Singh said.
The incident was a "fallout" of enmity between rival group of villagers, Singh said.
The bodies were handed over to their families for last rites after autopsy.
A named FIR has been lodged against 24 people of whom eight have been arrested and charged with the murder of the two villagers, he said.